ASP.NET Core 2.1 Identity: Role-based authorization -> Access Denied
问题 I'm using ASP.NET Core 2.1 with the new Identity framwork from .NET. The regular Authorization attribute works as long as no role specific role is requested. Do I need some extending / customized policies to use roles? Below is a minimized sample of my code: Startup.cs public void ConfigureServices(IServiceCollection services) { services.Configure<CookiePolicyOptions>(options => { // This lambda determines whether user consent for non-essential cookies is needed for a given request. options