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

Authorization header for uaa needs oauth2 encoding now #1002

Open
strehle opened this issue Aug 22, 2019 · 2 comments
Open

Authorization header for uaa needs oauth2 encoding now #1002

strehle opened this issue Aug 22, 2019 · 2 comments
Labels
enhancement Improvement or new functionality triaged Initial triage of issue has been performed

Comments

@strehle
Copy link
Member

strehle commented Aug 22, 2019

UAA changes now to standard oauth encoding:
The RFC for OAuth requires an URL encode in authorization header, see
https://tools.ietf.org/html/rfc6749#section-2.3

The authorization header needs to be
Authorization: Basic base64Encode(urlencode(client_id):urlencode(client_secret))

UAAC does not encode the authorization header. (client)
UAA does not decode the authorization header (server)
Thus this issue does popup in uaac before, however uaac should behave standard conform.

see
https://github.com/cloudfoundry/cf-java-client/blob/master/cloudfoundry-client-reactor/src/main/java/org/cloudfoundry/reactor/tokenprovider/AbstractUaaTokenProvider.java#L185-L187

This will come with UAA-RELEASE 74.0.0, see
https://www.pivotaltracker.com/n/projects/997278/stories/166970393

UAA clients need to be adapted, therefore this issue

Another example:
cloudfoundry/cf-uaac#50

@dmikusa dmikusa added enhancement Improvement or new functionality triaged Initial triage of issue has been performed labels Jan 18, 2022
@dmikusa
Copy link
Contributor

dmikusa commented Jan 18, 2022

Acknowledged.

We haven't seen any other issues reported from this or failures in CI, but I suspect that would only happen if there were characters in the username/password that require being urlencoded. Until this is fixed, if someone hits an issue you should be able to workaround by using a user/pass that does not change when being urlencoded (i.e. no characters need to be encoded).

@strehle
Copy link
Member Author

strehle commented Jan 18, 2022

ok almost done in UAA , and even in spring 5.6 this now is default spring-projects/spring-security#9791
so you should also change the default

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improvement or new functionality triaged Initial triage of issue has been performed
Projects
None yet
Development

No branches or pull requests

2 participants