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

new Properties() requires approval also of Properties.<init>(Properties) overload

    • script-security 1.43

      What is the business impact?

      The plugin cannot approve new java.util.Properties() - it asks you again and over again to approve the plugin.

      What is the incorrect behaviour?

      You are asked more than once to approve the same script.

      What is the expected behaviour?

      You should be asked only once to approve and then just work.

      Step by step to reproduce

      Create a pipeline job with the following code.

      import java.util.Properties;
      Properties properties = new java.util.Properties();
      
      node {
          
         echo 'Hello World'
      }
      

      try to build the job
      Go to manage jenkins -> script approval and approve
      try to build again the pipeline and you will see that it still fails

      Workaround

      In my case, approving twice makes the work - but on a real environment, it seems the workaround might not work.

      Regression

      Not sure

      If so, what versions did this previously work in?

      Environment

      Jenkins 2.32.3.2
      script-security-plugin 1.33 and 1.31

          [JENKINS-46757] new Properties() requires approval also of Properties.<init>(Properties) overload

          Félix Belzunce Arcos created issue -
          Jesse Glick made changes -
          Assignee New: Jesse Glick [ jglick ]
          Jesse Glick made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]
          Jesse Glick made changes -
          Remote Link New: This issue links to "PR 149 (Web Link)" [ 17650 ]
          Jesse Glick made changes -
          Link New: This issue blocks SECURITY-580 [ SECURITY-580 ]
          Jesse Glick made changes -
          Labels New: regression
          Jesse Glick made changes -
          Status Original: In Progress [ 3 ] New: Open [ 1 ]
          Jesse Glick made changes -
          Assignee Original: Jesse Glick [ jglick ]
          Jesse Glick made changes -
          Summary Original: new java.util.Properties() cannot be approved New: new Properties() requires approval also of Properties.<init>(Properties) overload
          Jesse Glick made changes -
          Priority Original: Major [ 3 ] New: Minor [ 4 ]
          Andrew Bayer made changes -
          Assignee New: Andrew Bayer [ abayer ]

            abayer Andrew Bayer
            fbelzunc Félix Belzunce Arcos
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: