Reputation: 8849
I am confused how OAuth2 takes you through an entire flow and redirects you back to the page.
For example, I have an auth endpoint: /auth/authorize
, callback endpoint /auth/callback
,
and token endpoint: /auth/token
/auth/authorize
gives back the authorize code
, redirects to the /auth/callback?code=mycode
, but how does this smoothly grab the access_token
and redirect the user to the original page?
Should my /auth/callback
redirect to my /auth/token
or something? And then /auth/token
redirects back to the page?
Upvotes: 13
Views: 37479
Reputation: 489
This might will help you in understanding the flow:
Reference: https://techannotation.wordpress.com/2015/06/17/spring-oauth2-with-authorization-code/
Upvotes: 14