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

Look at implementing HTTP Strict Transport Security #199

Closed
thekaveman opened this issue Nov 18, 2021 · 3 comments
Closed

Look at implementing HTTP Strict Transport Security #199

thekaveman opened this issue Nov 18, 2021 · 3 comments
Labels
ON HOLD Work is paused while awaiting feedback from Product security Changes to improve or maintain the availability and resilience of the app

Comments

@thekaveman
Copy link
Member

thekaveman commented Nov 18, 2021

HTTP Strict Transport Security or HSTS:

For sites that should only be accessed over HTTPS, you can instruct modern browsers to refuse to connect to your domain name via an insecure connection (for a given period of time) by setting the “Strict-Transport-Security” header. This reduces your exposure to some SSL-stripping man-in-the-middle (MITM) attacks.

From https://docs.djangoproject.com/en/3.2/ref/middleware/#http-strict-transport-security. We may want/need to do this at the Nginx level instead, see https://www.nginx.com/blog/http-strict-transport-security-hsts-and-nginx/

Crucial to this decision is the understanding that the AWS Load Balancer Azure App Service handles SSL connections for this app, and not the Django/Nginx system; the domain's certs and HTTP -> HTTPS redirection is all managed at the AWS Load Balancer App Service level.

See for example this app's nginx.conf in which the Nginx server is listening on port 8000 for connections - this is because the Load Balancer sits between the user and Nginx, handling the SSL and translation into the app container. In which case, trying to set this from within the app container may cause more problems than it solves.

@thekaveman thekaveman changed the title Implement HTTP Strict Transport Security Look at implementing HTTP Strict Transport Security Nov 18, 2021
@thekaveman thekaveman added the security Changes to improve or maintain the availability and resilience of the app label Apr 12, 2022
@thekaveman thekaveman added the ON HOLD Work is paused while awaiting feedback from Product label May 3, 2022
@afeld
Copy link
Contributor

afeld commented Jul 8, 2022

@thekaveman
Copy link
Member Author

Needs more investigation into how to do this outside of the app / within Azure's infrastructure.

@thekaveman
Copy link
Member Author

This is not a priority for now, Azure handles SSL termination.

@thekaveman thekaveman closed this as not planned Won't fix, can't repro, duplicate, stale Nov 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ON HOLD Work is paused while awaiting feedback from Product security Changes to improve or maintain the availability and resilience of the app
Projects
Archived in project
Development

No branches or pull requests

2 participants