Skip to content

Implement default Content Type Options header in Apache #277

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

Merged
merged 1 commit into from
Jul 2, 2025

Conversation

jonasbardino
Copy link
Contributor

Add X-Content-Type-Options 'nosniff'` header in apache to harden against XSS attacks sneaking in scripts or stylesheets from arbitrary files.

@jonasbardino jonasbardino self-assigned this Jul 2, 2025
@jonasbardino jonasbardino added the enhancement New feature or request label Jul 2, 2025
@jonasbardino jonasbardino requested a review from a team July 2, 2025 08:08
@jonasbardino
Copy link
Contributor Author

I've done brief testing on ui erda and found no web regressions, but it could use more thorough testing.

One can check served headers with Mozilla Observatory:
https://developer.mozilla.org/en-US/observatory/analyze?host=FQDN

Background info about the option at
https://developer.mozilla.org/en-US/docs/Web/Security/Practical_implementation_guides/MIME_types

Copy link
Contributor

@rasmunk rasmunk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved

…ainst XSS

attacks sneaking in scripts or stylesheets from arbitrary files.
@jonasbardino jonasbardino force-pushed the add/apache-x-content-type-options-nosniff branch from 73ff763 to 2430caa Compare July 2, 2025 10:54
@jonasbardino jonasbardino merged commit d99fb1d into next Jul 2, 2025
7 checks passed
@jonasbardino jonasbardino deleted the add/apache-x-content-type-options-nosniff branch July 2, 2025 10:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants