-
Notifications
You must be signed in to change notification settings - Fork 97
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
GET used instead of POST for token validation (405: Bad request) #500
Comments
Seems the problem was introduced in version Just tested successfully with version |
There are numerous tests that should cover this e.g. -> https://github.com/jenkinsci/oic-auth-plugin/blob/4.452.v2849b_d3945fa_/src/test/java/org/jenkinsci/plugins/oic/PluginTest.java#L148 |
FWIW we also have tests using keycloak |
Maybe some kind of regression, caused by some other dependencies? |
looking at https://bitbucket.org/connect2id/oauth-2.0-sdk-with-openid-connect-extensions/src/5822caae520661cdfe5bce79e57a33c70e4159ab/src/main/java/com/nimbusds/oauth2/sdk/TokenRequest.java#lines-933 the method is hardcoded to use post per the spec. you can try adding a logger for |
Thanks a lot for your hint regarding the log tracing. Seems the problem is caused by a 301 redirect. Now the question is whether the reaction to the 301 is correct? Log:
|
Jenkins and plugins versions report
Environment
What Operating System are you using (both controller, and any agents involved in the problem)?
Ubuntu 20.04 LTS
Reproduction steps
Post
Expected Results
Expected that plugin sends POST requests to token server URL (
<keycloak server>/protocol/openid-connect/token
)Actual Results
Instead a GET requests is received:
Keycloak logs
Jenkins exception:
Anything else?
No response
Are you interested in contributing a fix?
No response
The text was updated successfully, but these errors were encountered: