-
-
Notifications
You must be signed in to change notification settings - Fork 217
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
Bug: OAuth2 and authenticated-user-account api #2813
Comments
Looks strange. How do you get to test it from swagger? |
I'm working on adding springdoc + oauth2 (new PR coming soon) and I tested this API. |
I really thin this is related to swagger + oauth integration. I didn't remove any scheme support here (just a dedicated exception). What scheme are you using? |
(I bet on an
In OAuth2AuthenticationReader.readAttributes |
Exact! The fix I just applied is: if (authentication instanceof OAuth2AuthenticationToken oauthToken) {
return oauthToken.getPrincipal().getAttributes();
} else if (authentication instanceof JwtAuthenticationToken jwtToken) {
return jwtToken.getTokenAttributes();
} |
No else needed here :). And if it's the case we need to add a fixture with this kind of authentication (and the dedicated tests in |
I'm taking it and will submit the fix soon |
When generating OAuth2 with account, the API doesn't work:
Here the stacktrace:
The text was updated successfully, but these errors were encountered: