netdragoon / aspnet-core-webapi-jwt-auth-example

An example of how you can issue JWT tokens with ASP.NET Core 1, authenticate a user with the tokens issued and restrict access to controller methods based on user claims using ASP.NET Core MVC's policy features in a Web API project.

Repository from Github https://github.comnetdragoon/aspnet-core-webapi-jwt-auth-exampleRepository from Github https://github.comnetdragoon/aspnet-core-webapi-jwt-auth-example

aspnet-core-webapi-jwt-auth-example

An example of how you can issue JWT tokens with ASP.NET Core 1, authenticate a user with the tokens issued and restrict access to controller methods based on user claims using ASP.NET Core MVC's policy features in a Web API project.

Discussion

The code in this example is discussed as a series of blog posts.

Part I addresses how JSON Web Token can be configured and issued. Part II covers the authorisation aspects focusing on user claims using ASP.NET Core MVC’s policy features.

About

An example of how you can issue JWT tokens with ASP.NET Core 1, authenticate a user with the tokens issued and restrict access to controller methods based on user claims using ASP.NET Core MVC's policy features in a Web API project.


Languages

Language:C# 100.0%