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

Force https for /admin #1

Open
rgeoghegan opened this issue May 2, 2014 · 4 comments
Open

Force https for /admin #1

rgeoghegan opened this issue May 2, 2014 · 4 comments
Labels

Comments

@rgeoghegan
Copy link
Contributor

The /admin site only works under http (https://mtlpy.org leads nowhere). Despite Heartbleed, it would be handy to not send our passwords out on cleartext. Do the following:

  1. Generate a self-signed certificate and dump it in the mtlpy keepass. No need to buy one since we can share it with the admins.
  2. Hack the nginx config so that any requests to /admin require https
  3. Of course, set up https in nginx with the self-signed certificate
@rgeoghegan rgeoghegan self-assigned this May 2, 2014
@mlhamel
Copy link
Member

mlhamel commented May 2, 2014

We should take a certificate for free from there:
https://www.startssl.com

BUT, we should fix hearthbleed on our server cause no-one did any updates on it since a long time !

@pior
Copy link
Member

pior commented Apr 13, 2017

We now have a certificate.
What is the proper way to enforce HTTPS on /admin ?

@merwok
Copy link
Member

merwok commented Apr 13, 2017

Django settings to prevent being logged over http:

CSRF_COOKIE_HTTPONLY = True
CRSF_COOKIE_SECURE = True
SESSION_COOKIE_SECURE = True

(I have all three on my sites, your mileage may vary.)

Then I have an nginx config to redirect http to https with the HSTS header, I’m not sure what can be done on Heroku.

@merwok
Copy link
Member

merwok commented Sep 15, 2017

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

5 participants