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 explicit Content Security Policy (CSP) for Dashboard #449

Merged
merged 1 commit into from
Nov 9, 2021
Merged

Conversation

bensheldon
Copy link
Owner

@bensheldon bensheldon commented Nov 5, 2021

Closes #420.

Allows each directive to be overridden. I'm imagining they would be overriden with more strict values, but I'll leave it for the future if it should be smarter about ensuring that it isn't overriden with less-strict values.

It does force the usage of a nonce for the Dashboard because the nonce value both defaults to nil and is disabled by setting to nil, so it's indeterminate as to what the application's intention is.

It does allow data: images because Chart.js embeds some SVGs.

@bensheldon bensheldon added the enhancement New feature or request label Nov 5, 2021
@bensheldon bensheldon temporarily deployed to goodjob-csp-23gr0thgswzqntb8ds November 5, 2021 14:38 Inactive
@bensheldon bensheldon merged commit f69ca33 into main Nov 9, 2021
@bensheldon bensheldon deleted the csp branch November 9, 2021 15:00
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.

Add a default Content-Security-Policy for the Dashboard
1 participant