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

CSF script-src problem #298

Closed
razzeee opened this issue May 25, 2022 · 1 comment · Fixed by #299
Closed

CSF script-src problem #298

razzeee opened this issue May 25, 2022 · 1 comment · Fixed by #299

Comments

@razzeee
Copy link
Member

razzeee commented May 25, 2022

The website currently reports (in chromium for e.g.)

Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'self' https://webstats.gnome.org". Either the 'unsafe-inline' keyword, a hash ('sha256-fDVtD703YIdPFRhb6ZJE/SvcwyA7gZRWfRRM6K6r9EA='), or a nonce ('nonce-...') is required to enable inline execution.

I don't think removing the check would be helpful, so we probably need to hash it.

@razzeee
Copy link
Member Author

razzeee commented May 25, 2022

https://github.com/nibtime/next-safe-middleware could be an option

sorin-davidoi added a commit to sorin-davidoi/flathub-website that referenced this issue May 26, 2022
Apply the suggested fix from pacocoursey/next-themes#106 (comment). The only downside is that if the script changes when the dependency is upgraded, the hash would need to be updated accordingly.

Closes flathub-infra#298.
razzeee pushed a commit that referenced this issue May 26, 2022
Apply the suggested fix from pacocoursey/next-themes#106 (comment). The only downside is that if the script changes when the dependency is upgraded, the hash would need to be updated accordingly.

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

Successfully merging a pull request may close this issue.

1 participant