Hi Brice,

try this 
https://wiki.jenkins-ci.org/display/JENKINS/Configuring+Content+Security+Policy

Cheers
  Steffen

From: [email protected] 
[mailto:[email protected]] On Behalf Of Brice Parmentier
Sent: Tuesday, March 15, 2016 9:14 AM
To: Jenkins Users
Subject: Jenkins Content Security Policy and jQuery for HTML reports

Hi,
I'm using Jenkins to launch a build and test sequence.
For my tests I use the FitNesse tool (at http://www.fitnesse.org), which can 
generate HTML reports.

Those HTML reports have links to local scripts like the jQuery library (it does 
not go online to load the library, it is embedded on the tool).
Since recent version of Jenkins I noticed that I had to set the value of 
"hudson.model.DirectoryBrowserSupport.CSP" to something containing "script-src 
'unsafe-inline';".
But this, in my case, only allow embedded scripts to execute, it does not allow 
to load external Javascript files like this jQuery library for example. So that 
all buttons actions, hide/show divs actions, does not work at all. Si if I want 
to see my HTML reports, I can't do it from the Jenkins web interface, I have to 
download my artifacts locally and open the HTML page on my pc.
I tried lots of combinations for the CSP parameter, but nothing works.
As an example, the screenshot attached shows the console output when I open the 
HTML report from the web interface.
Does anybody have an explanation of this behaviour, and eventually a fix ?
Thanks !
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
[email protected]<mailto:[email protected]>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/13027f3e-3cb1-4f86-b5b3-be2526ec3d84%40googlegroups.com<https://groups.google.com/d/msgid/jenkinsci-users/13027f3e-3cb1-4f86-b5b3-be2526ec3d84%40googlegroups.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/4ba0538797f047faaf8d1e492e45b93b%40KAPPEX001-MBX.webde.local.
For more options, visit https://groups.google.com/d/optout.

Reply via email to