Getting Authorization Right in .NET: Patterns, Pitfalls...
summary
Concrete .NET code demos show policy creation, custom IAuthorizationRequirement handlers with DI, and minimal APIs and authorization handlers wired into routes; a live Policy Server demo and JSON-backed external policy handler illustrate centralizing decisions (no token bloat), with examples of role explosion (hundreds of roles), caching/invalidation concerns, and step‑up auth via a recent‑login policy. Razor UI uses a tag helper that hides buttons by querying the policy, and feature‑area routing demonstrates per‑route permission evaluation—practical if you want implementation patterns not theory.
AI-written summary · about
chapters (12)
- 0:00Authorization challenges in .NET
- 5:28AuthN vs AuthZ separation
- 9:44Default ASP.NET Core policies
- 12:51Demo: Razor Pages security
- 19:12Demo: API security with minimal APIs
- 23:45Reusable authorization policies
- 31:17AuthZ requirements with DI
- 34:45Externalizing authZ policies
- 41:50Demo: JSON policy evaluation
- 45:24UI authZ and step-up authN
- 56:34Demo: UI feature authZ with tag helpers
- 1:03:21Enterprise-scale authZ design
related talks
58mImplementing Authorization in Web Applications and APIs
58mImplementing authorization in web applications and APIs
01h 02mImplementing authorization in web applications and APIs
54mAuthorization for modern Applications
56mImplementing authorization in web applications and APIs
36mFlexible Authorisation with ASP.NET Core 7.0
51mAuthentication and Authorization in ASP.NET Core 2
47mDeveloping Flexible Authorisation Capabilities in ASP.NET Core
