Authentication samples for ASP.NET Core
The ASP.NET Core repository contains the following authentication samples (main branch):
- Claims transformation
- Cookie authentication
- Custom authorization failure response
- Custom policy provider - IAuthorizationPolicyProvider
- Dynamic authentication schemes and options
- External claims
- Selecting between cookie and another authentication scheme based on the request
- Restricts access to static files
Obtain and run the samples
The sample links provided in this article provide samples for the upcoming release of ASP.NET Core. To obtain a sample for the current release or a prior release, perform the following steps:
- Select the release branch of the ASP.NET Core repository. For example, the
release/5.0branch contains the samples for the ASP.NET Core 5.0 release. - Clone or download the ASP.NET Core repository.
- On your local system, verify installation of the .NET Core SDK version matching the clone of the ASP.NET Core repository.
- Navigate to a sample in
aspnetcore/src/Security/samplesfolder and run the sample with thedotnet runcommand.
Maklum balas
Kirim dan lihat maklum balas untuk