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

Group AttributeStatement is incorrectly handled if multiple groups are sent. #41

Open
gautamrege opened this issue May 22, 2018 · 0 comments

Comments

@gautamrege
Copy link

I have a Okta Application that has some people configured as part of multiple groups. In the SAMLResponse I do see the data: (Groups field has "QA", "Dev" and "Everyone".

Groups: {XMLName:{Space:urn:oasis:names:tc:SAML:2.0:assertion Local:Attribute} FriendlyName: Name:Groups NameFormat:urn:oasis:names:tc:SAML:2.0:attrname-format:basic Values:[{XMLName:{Space:urn:oasis:names:tc:SAML:2.0:assertion Local:AttributeValue} Type: Value:QA} {XMLName:{Space:urn:oasis:names:tc:SAML:2.0:assertion Local:AttributeValue} Type: Value:Everyone} {XMLName:{Space:urn:oasis:names:tc:SAML:2.0:assertion Local:AttributeValue} Type: Value:Dev}]}

However, since the library is treating everything like a key / value strings, only the last group gets attached. i.e. attributeStatement["Groups"] is "QA" (one of them)

This is probably a generic problem for handling attribute Statements where we could expect a list and not just a string.

Solution: We need to support arrays if the attribute statement is a Array. I haven't thought the solution through yet but will give it shot and send a PR :)

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