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

Enforce HTTPS link in mail #53

Closed
kosli opened this issue Nov 18, 2016 · 2 comments
Closed

Enforce HTTPS link in mail #53

kosli opened this issue Nov 18, 2016 · 2 comments
Labels

Comments

@kosli
Copy link

kosli commented Nov 18, 2016

Hi

I have the self-service-password tool as a docker image which is automatically proxied thru a let's encrypt HTTPS proxy docker, which means that the tool itself is reached via a HTTP url. Still the users accesses it via HTTPS. The URL that is generated in the mail for a password reset, is still using HTTP (because the tool itself sees only the HTTP access). Would it be possible to add a config option to enforce HTTPS urls? or even provide the "base URL"?

Thanks for this great tool!

KoS

@plewin
Copy link
Member

plewin commented Nov 18, 2016

Hi Kosli,

The reset URL can be customized in the config file.

#$reset_url = $_SERVER['HTTP_X_FORWARDED_PROTO'] . "://" . $_SERVER['HTTP_X_FORWARDED_HOST'] . $_SERVER['SCRIPT_NAME'];

Which docker image are you using ? You may want to check if your docker image supports this feature.

# Reset URL (if behind a reverse proxy)
#$reset_url = $_SERVER['HTTP_X_FORWARDED_PROTO'] . "://" . $_SERVER['HTTP_X_FORWARDED_HOST'] . $_SERVER['SCRIPT_NAME'];

@kosli
Copy link
Author

kosli commented Nov 18, 2016

@plewin OMG, i have completely overseen that option, shame on me!
Just changed it, works like a charm.
I am using the Docker image here https://github.com/grams/docker-LTB-self-service-password which I have updated to v1.0 of the tool.

@kosli kosli closed this as completed Nov 18, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants