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 HSTS middleware #905

Draft
wants to merge 1 commit into
base: develop
Choose a base branch
from
Draft

Conversation

ekohl
Copy link
Member

@ekohl ekohl commented Sep 9, 2024

This header is entirely useless for us because the header is aimed at browsers, but some scanners still think this is needed.

This PR is not intended to be merged, but only serve as an example for how it could be implemented.

Link: https://www.tenable.com/plugins/nessus/142960

This header is entirely useless for us because the header is aimed at
browsers, but some scanners still think this is needed.

Link: https://www.tenable.com/plugins/nessus/142960
@evgeni
Copy link
Member

evgeni commented Sep 9, 2024

Why not merging this? If it will make people shut up, I'm all for it.

@ehelms
Copy link
Member

ehelms commented Sep 9, 2024

Why not merging this? If it will make people shut up, I'm all for it.

I am, sadly, in the same boat as this. While I detest that scanners force us into these situations, I also feel for our users and a small change that improves their experience gets my vote.

@willdarton
Copy link

I appreciate you taking the time to create a PR as a potential solution. As others have mentioned it seems like a simple fix to make the customer experience better.

@ekohl
Copy link
Member Author

ekohl commented Sep 9, 2024

I'm still tempted to detect the Nessus user agent and simply reject them to silence it. Another option is to only send it to Nessus, just to shut it up.

If we want merge this, we need to be compliant with the RFC and only send it when the connection is over TLS (RFC 6797 section 5.1). It's also good to add some tests to this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants