-
Notifications
You must be signed in to change notification settings - Fork 150
How can handle Authorize attribute on ASOS #536
Comments
ASOS doesn't validate tokens, it only issues them. Instead, you'll want to use the OAuth validation handler and register it using Cheers. |
Thanks a lot |
No, you just need the |
Thanks a lot again
but when validate access_token and get claims from
why my custom claims not generated on access_token at first? |
|
God bless you 👍 |
Hi
I use ROPC flow on my project, also i use .Net Core v2.1
so i added this codes to ConfigureService on Startup.cs
then implement OpenIdConnectServerProvider class like this:
and can get access_token
then for test it i create a controller like this :
but how can handle authorize attribute because after call this action i received under error:
i search this error and find some result like this:
https://stackoverflow.com/questions/52287542/invalidoperationexception-no-authenticationscheme-was-specified-and-there-was
https://stackoverflow.com/questions/47324129/no-authenticationscheme-was-specified-and-there-was-no-defaultchallengescheme-f/47622172
but none of them is not compatible with ASOS :(
also i checked HttpContext.User.Identity.IsAuthenticated that is always false(even when i send Authorization on header request)
how can handle Authorize Attribute for ASOS?
The text was updated successfully, but these errors were encountered: