Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-74281

[matrix-reloaded] Extract inline script block and event handlers in WEB-INF/classes/net/praqma/jenkins/plugin/reloaded/MatrixReloadedAction/index.jelly

XMLWordPrintable

      Problems

      == Inline Script Block
      Line: 37
      ----
      <script><![CDATA[
      function click2Change( status, last )
      {
      	var i;
      	for( i = 0, len = document.matrixreloaded.elements.length ; i < len ; i++ )
      	{
      		var element = document.matrixreloaded.elements[i];
      		if( element.type == 'checkbox' )
      		{
      			element.checked = (element.value in status) || ((parseInt(element.value) + 10) in status && !last);
      		}
      	}
      	return false;
      }
      
      
      	]]></script>
      ----
      
      == Inline Event Handler
      Line: 153
      ----
      <a href="#" onclick="click2Change({0:true}, 0);">
      ----
      
      == Inline Event Handler
      Line: 154
      ----
      <a href="#" onclick="click2Change({1:true}, 0);">
      ----
      
      == Inline Event Handler
      Line: 155
      ----
      <a href="#" onclick="click2Change({2:true}, 0);">
      ----
      
      == Inline Event Handler
      Line: 156
      ----
      <a href="#" onclick="click2Change({4:true}, 0);">
      ----
      
      == Inline Event Handler
      Line: 157
      ----
      <a href="#" onclick="click2Change({3:true}, 0);">
      ----
      
      == Inline Event Handler
      Line: 158
      ----
      <a href="#" onclick="click2Change({0:true,1:true,2:true,4:true}, 0);">
      ----
      
      == Inline Event Handler
      Line: 159
      ----
      <a href="#" onclick="click2Change({0:true,1:true,2:true,4:true}, 1);">
      ----
      
      == Inline Event Handler
      Line: 160
      ----
      <a href="#" onclick="click2Change({0:true,1:true,2:true,3:true,4:true}, 0);">
      ----
      
      == Inline Event Handler
      Line: 161
      ----
      <a href="#" onclick="click2Change({}, 0);">
      ----
      

      Solutions

      https://www.jenkins.io/doc/developer/security/csp/#inline-javascript-blocks
      https://www.jenkins.io/doc/developer/security/csp/#inline-event-handlers

            Unassigned Unassigned
            basil Basil Crow
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: