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

Add optional ASSERTION_URL setting #23

Merged
merged 3 commits into from
Jun 22, 2017
Merged

Add optional ASSERTION_URL setting #23

merged 3 commits into from
Jun 22, 2017

Conversation

tonymke
Copy link
Contributor

@tonymke tonymke commented Jun 17, 2017

We pass the result of get_current_domain to pysaml2 to validate
the source of the incoming StatusResponse (the scheme+host of the
request).

This is not viable in a reverse proxy scenario, in particular when the
host, port, and/or scheme of the django server changes with churn.

As a solution, alter get_current_domain to just use a setting
variable, ASSERTION_URL, instead of the scheme and host of the
incoming SAML request. If the setting is not present, use the
current behavior.

tonymke and others added 2 commits June 17, 2017 13:49
We pass the result of `get_current_domain` to pysaml2 to validate
the source of the incoming StatusResponse (the scheme+host of the
request).

This is not viable in a reverse proxy scenario, in particular when the
host, port, and/or scheme of the django server changes with churn.

As a solution, alter `get_current_domain` to just use a setting
variable, `ASSERTION_URL`, instead of the scheme and host of the
incoming SAML request. If the setting is not present, use the
current behavior.
@fangli
Copy link
Owner

fangli commented Jun 22, 2017

it would be great if you can fix the README and AUTHORS accordingly (since I'm not a native English speaker). 😄

@tonymke
Copy link
Contributor Author

tonymke commented Jun 22, 2017

Good call. Done.

@fangli
Copy link
Owner

fangli commented Jun 22, 2017

Good to go. will release a new pip version soon.

@fangli fangli merged commit f8066f2 into fangli:master Jun 22, 2017
@fangli
Copy link
Owner

fangli commented Jun 22, 2017

Hi @tonymke I have it released as 2.1.1 on pypi.
https://pypi.python.org/pypi/django_saml2_auth/
Thanks.

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 this pull request may close these issues.

3 participants