Skip to content
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

Customising Spring OAuth to only perform code exchange for JWT token #9

Closed
HuncholiniTheFirst opened this issue Mar 22, 2021 · 1 comment

Comments

@HuncholiniTheFirst
Copy link

Hi Wojciech.

Firstly, thanks for the great course on PluralSight, your clear and concise teaching style helped me learn a lot in a short time.

I have a question which I don't think was covered in your course. If this isn't the place for questions, please let me know, I'll delete this.

I have a front end SPA that performs half of the OAuth authorisation flow, i.e. it gets the authorization code from Google's OAuth endpoint.

I want to pass this to my spring boot back end and have my back end exchange the code for a token and then establish a user session. Now I can of course do this manually and use the Google API library in Java, but there are a multitude of benefits I can derive by getting spring to do the work for me.

In your course section 'Server-side Applications: Single Sign-in with Oauth2', you show how we can add configuration to our applications, based on which Spring automatically performs the whole authorisation flow for an identity provider like Google. Is there however a well established way that I can customise spring so that it only performs the 'code for token exchange' part of the authorisation flow?

@HuncholiniTheFirst
Copy link
Author

Closing this issue, I've decided to follow your latest video on Plural sight and perform all auth on my backend and send a session cookie to my react front end. Thank you for providing this brilliant resource.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant