Cookie Authentication and [Authorize]
Turn on cookie authentication in Program.cs, sign users in with claims and SignInAsync, protect actions with [Authorize] and roles, and show who's signed in with User.
Updated
![Cheat sheet: Cookie Authentication and [Authorize]](https://fsdtrainingmedia.blob.core.windows.net/public/images/2026/11/a27eb158c93c47d6b1f93c00d1f59822.webp)
- Category
- ASP.NET Core
- Level
- Journeyman
- Tags
- [Authorize], aspnet-core, Authentication Middleware, Claims and ClaimsPrincipal, Cookie Authentication, c-sharp