BlazorAuth
BlazorAuth copied to clipboard
A sample showing how to add ASP.NET Core Identity auth options to the basic Blazor app.
BlazorAuth
A sample showing how to add ASP.NET Core Identity auth options to the basic Blazor app.
Features
- Adds ASP.NET Core Identity with Default UI for login, etc.
- Demonstrates use of
AuthorizeView - Demonstrates use of
CascadingAuthenticationStateinApp.razor - Demonstrates adding role support to app in
Startup.cs - Demonstrates use of Claims
- Demonstrates using Claims to drive Policies
- Use of [Authorize] attribute in Razor Server pages
Related Docs
- ASP.NET Core Blazor authentication and authorization
- Role-based authorization in ASP.NET Core
- Claims-based authorization in ASP.NET Core
Related Stack Overflow Questions
- Why is ASP.NET Core Identity User.IsInRole always returns false
- Persisting Claims across requests
- How can I get a list of policies from asp.net core auth
Other Resources
- Stream of work on this repo // coming soon
- Accessing and Extending Authorization Claims in ASP.NET Core and Blazor
- Custom authorisation policies and requirements in ASP.NET Core