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

SAML: support HTTP redirect binding #1042

Open
easeway opened this issue Aug 22, 2017 · 8 comments
Open

SAML: support HTTP redirect binding #1042

easeway opened this issue Aug 22, 2017 · 8 comments

Comments

@easeway
Copy link

easeway commented Aug 22, 2017

Some identity provider requires SAMLRequest to be compressed and then base64 encoded. There's no configuration option to compress SAMLRequest and dex won't work with these identity providers.

@ericchiang
Copy link
Contributor

ericchiang commented Aug 22, 2017

Dex supports the SAML POST binding, which doesn't use compression

Messages are encoded for use with this binding by encoding the XML into an HTML form control and are
transmitted using the HTTP POST method. A SAML protocol message is form-encoded by applying the
base-64 encoding rules to the XML representation of the message and placing the result in a hidden form
control within a form as defined by [HTML401] Section 17. The HTML document MUST adhere to the
XHTML specification, [XHTML]. The base64-encoded value MAY be line-wrapped at a reasonable length
in accordance with common practice.

3.5.4 Message Encoding - https://docs.oasis-open.org/security/saml/v2.0/saml-bindings-2.0-os.pdf

The HTTP redirect binding does use encryption (section 3.4.4), but that binding isn't used by dex.

This behavior was actually addressed in #785

From my reading, compliant providers shouldn't enforce compression (or even support compression) of the SAMLRequest on the HTTP POST binding. Though they may for the HTTP redirect binding.

Which provider are you using?

@easeway
Copy link
Author

easeway commented Aug 22, 2017

vSphere SSO. It offers HTTP redirect binding. However it also accepts POST but requires compression on SAMLRequest.

@easeway
Copy link
Author

easeway commented Aug 22, 2017

I have PR proposed: #1044

Without the change, dex won't work with vSphere SSO using SAML2.0.

@easeway
Copy link
Author

easeway commented Aug 22, 2017

According to SAML standard, how can we use HTTP redirect binding with dex? It seems HTTP redirect binding is the only option in vSphere SSO.

@ericchiang
Copy link
Contributor

We would have to add the HTTP redirect binding, though that's not unreasonable.

@easeway
Copy link
Author

easeway commented Aug 22, 2017

I can help on that. I have a PR working in progress to support HTTP redirect binding.

@ericchiang
Copy link
Contributor

@easeway perfect, please feel free to send the PR and tag me for review.

I can also do this if that's easier.

@ericchiang ericchiang changed the title SAML: no configuration option to compress SAMLRequest SAML: support HTTP redirect binding Aug 22, 2017
@srenatus
Copy link
Contributor

I wasn't aware of this issue, but there's another recent attempt to fix this here: #1175

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

3 participants