1
votes

Currently I am developing an asp.net core web application with OpenID connect and Azure. I found that Web API project template uses JWT authentication. Can I use JWT authentication for both web application, API project (with Azure)? I can see a lot of sample Web API projects with JWT but I hardly find any sample or tutorials of asp.net (core) MVC web applications with JWT authentication. Is it possible web applicatin can be authenticated with JWT? For example, login page can issue a jwt token and the site can be authenticated after that?

Thanks

1
you don't need JWT for web application, you can just use cookie.Alexan
for web application, where can I get a jwt token and how to put it into a cookie? Is there any link of samples? thanksAussie

1 Answers

1
votes

JWT is used to secure the web api (https://goblincoding.com/2016/07/03/issuing-and-authenticating-jwt-tokens-in-asp-net-core-webapi-part-i/), while cookies are usually used to secure the web application.