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

unclassified method java.lang.String replaceAll java.lang.String

      This simple pipeline script:

      def rev="v3.1.7"
      echo "2"
      rev.replaceAll(/v([0-9])\../)

      will result in this exception after printing "2":

      org.jenkinsci.plugins.scriptsecurity.sandbox.RejectedAccessException: unclassified method java.lang.String replaceAll java.lang.String
      at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SandboxInterceptor.onMethodCall(SandboxInterceptor.java:113)
      at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:149)

      However the sandbox administration area doesn't offer to add this violation to the whitebox.

          [JENKINS-42399] unclassified method java.lang.String replaceAll java.lang.String

          Wilfried Goesgens created issue -
          Jesse Glick made changes -
          Summary Original: sandbox doesn't offer to allow prohibited access in admin interface New: unclassified method java.lang.String replaceAll java.lang.String
          Jesse Glick made changes -
          Link New: This issue duplicates JENKINS-37129 [ JENKINS-37129 ]
          Jesse Glick made changes -
          Resolution New: Duplicate [ 3 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]

            Unassigned Unassigned
            dothebart Wilfried Goesgens
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: