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

Handle malformed Kmsi form field in ADFS #847

Closed
dboitnot opened this issue Jul 9, 2022 · 2 comments · Fixed by #848
Closed

Handle malformed Kmsi form field in ADFS #847

dboitnot opened this issue Jul 9, 2022 · 2 comments · Fixed by #848

Comments

@dboitnot
Copy link
Contributor

dboitnot commented Jul 9, 2022

I've encountered a situation where the value for Kmsi is "true " (with trailing space). This leads to:

DEBU[0003] HTTP Req URL="https://<redacted>/adfs/ls/IdpInitiatedSignOn.aspx?loginToRp=urn%3Aamazon%3Awebservices&client-request-id=3b.." http=client method=POST
DEBU[0003] HTTP Res Status="500 Internal Server Error" http=client
unable to classify response from auth server

Apparently this value is being pulled directly from the server's response:

authForm := url.Values{}

@dboitnot
Copy link
Contributor Author

dboitnot commented Jul 9, 2022

It turns out that, at least in my case, it's not trailing white space but a second, empty value for Kmsi in the form:

len(authForm["Kmsi"]) // == 2

dboitnot added a commit to dboitnot/saml2aws that referenced this issue Jul 9, 2022
@dboitnot dboitnot changed the title Handle extra whitespace in ADFS Kmsi form field Handle malformed Kmsi form field in ADFS Jul 10, 2022
dboitnot added a commit to dboitnot/saml2aws that referenced this issue Jul 21, 2022
mapkon added a commit to dboitnot/saml2aws that referenced this issue Mar 9, 2023
@christianmeyer
Copy link
Contributor

Just out of curiosity, is that issue also persisting with the version out of #795 ? In that case I would adopt the referenced fix.

mapkon added a commit to dboitnot/saml2aws that referenced this issue Mar 23, 2023
@mapkon mapkon linked a pull request Mar 23, 2023 that will close this issue
mapkon added a commit to dboitnot/saml2aws that referenced this issue Mar 26, 2023
mapkon added a commit to dboitnot/saml2aws that referenced this issue Mar 27, 2023
mapkon added a commit that referenced this issue Mar 27, 2023
fix gh-847: Fixes malformed Kmsi value in form
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

Successfully merging a pull request may close this issue.

2 participants