-
-
Notifications
You must be signed in to change notification settings - Fork 337
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why is 401 always returned in JwtBearerEvent OnChallenge? #17
Comments
@emilwkarlsson Make sure you are passing auth token with prefix like "Bearer {YOUR TOKEN HERE}". and it will resolve your issue |
hi, i sent expired token to api. what are you know this problem ? thanks |
Maaaan, so many thanks to you! |
When adding authentication in AddIdentityInfrastructure() in ServiceExtensions.cs, the code clearly states it should return 401 when OnChallenge event is invoked. Why is that? Nothing bad has really happened?
https://docs.microsoft.com/en-us/dotnet/api/microsoft.aspnetcore.authentication.jwtbearer.jwtbearerevents.onchallenge?view=aspnetcore-3.0
The text was updated successfully, but these errors were encountered: