I got a Mvc and an a API project i want to use [Authorize] attribute in mvc is it possible?
How Could i do that i added the token validation parameters in the mvc project same as the api's i am using the api's login method it returns 200 but when i try to access to [Authorize] view it sends me 401 unauthorized i also set the access token to the httpcontext but i don't know how to make that authorized in the pages
9 Replies
Unknown User•4w ago
Message Not Public
Sign In & Join Server To View
what is the existing handler i am not aware of that
Unknown User•4w ago
Message Not Public
Sign In & Join Server To View
i am using jwtbearer
like this
Unknown User•4w ago
Message Not Public
Sign In & Join Server To View
this is my exception btw
Unknown User•4w ago
Message Not Public
Sign In & Join Server To View
you mean audience
it is not actually
okay bro i solved
you were right
i was thinking i am getting the data from appsettings but i forget the add configure jwt settings service
now it authorizes