aspnetcorehero / Boilerplate

Clean Architecture Solution Template for ASP.NET Core 5.0. Built with Onion/Hexagonal Architecture and incorporates the most essential Packages your projects will ever need. Includes both WebApi and Web(MVC) Projects.
https://codewithmukesh.com/project/aspnet-core-hero-boilerplate/
MIT License
582 stars 148 forks source link

Update PermissionAuthorizationHandler.cs #12

Closed davidsanchez1 closed 3 years ago

davidsanchez1 commented 3 years ago

Use ClaimsPrincipal to validate permission to avoid query to the IdentityContext ( DB ) everytime the AuthorizationService.AuthorizeAsync(User, Permissions) is used.