CSP is blocking voluntary scripts no matter what
-
Hi,
I had to turn this plugin off for the website I was testing it on until I can get some answers. The thing is that I have setup Scripts/Images/Frames domains that should be always allowed. That seems to be working fine.
Then I have filled in domains as google-analytics.com, googletagmanager.com etc. for Statistics and some other in Marketing but even if I accept the Cookies for Statistics/Marketing these get blocked in the Chromium based browsers because of CSP.
In Firefox it works just fine. The blocking happens only if I refuse the Cookies as it should be. Below you can see my settings:
I was experimenting with different setups but no luck – in Chromium browsers the Stats/Marketing scripts do always get blocked. Firefox is fine.
When I tried to put all the domains in “Always allow” it was fine.
The errors in Chrome look are below. For some reason it keeps mentioning the domains that should be always allowed.Refused to load the script '<URL>' because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline' 'unsafe-eval' <URL> <URL> <URL>". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback. (index):2 Refused to load the script 'https://www.google-analytics.com/analytics.js' because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline' 'unsafe-eval' https://*.googleapis.com/ https://*.gstatic.com/ https://*.bisnode.cz/". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback. (anonymous) @ (index):2 (anonymous) @ (index):3 www.awac.cz/:1 Refused to load the script 'https://www.googletagmanager.com/gtag/js?id=G-41W4G22JCH' because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline' 'unsafe-eval' https://*.googleapis.com/ https://*.gstatic.com/ https://*.bisnode.cz/". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback. (index):6 Refused to load the script 'https://www.googletagmanager.com/gtm.js?id=GTM-TB3BLMF' because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline' 'unsafe-eval' https://*.googleapis.com/ https://*.gstatic.com/ https://*.bisnode.cz/". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback. (anonymous) @ (index):6 (anonymous) @ (index):7 (index):30 Refused to load the script 'https://t.leady.com/sJ11WjoxozNPCbTv/L.js' because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline' 'unsafe-eval' https://*.googleapis.com/ https://*.gstatic.com/ https://*.bisnode.cz/". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback. (anonymous) @ (index):30 (anonymous) @ (index):30 (index):31 Refused to load the script 'https://ifirmy.cz/pxstats/piwik.js' because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline' 'unsafe-eval' https://*.googleapis.com/ https://*.gstatic.com/ https://*.bisnode.cz/". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback.
Any help would be greatly appreciated.
Thank you!
The page I need help with: [log in to see the link]
- The topic ‘CSP is blocking voluntary scripts no matter what’ is closed to new replies.