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

Input submitter parameter should use the current IdStrategy to match against current user

XMLWordPrintable

    • pipeline-input-step 2.9

      Problem statement

      Depending on the current SecurityRealm, the input step will refuse or accept submitters depending on the case sensitivity settings.

      Despite there is probably some logic to be improved too on various SecurityRealm implementations, I think there is still an improvement to be done on the Pipeline-input side. Bonus point: it's also likely much simpler than addressing all SecurityRealms implems out there.

      Example:

      input message: "blah", submitter: "SomeUser"
      

      Even if the strategy is the default CASE_INSENSITIVE one, the configuration above will reject a user logged in as someuser.

      Expected behavior

      The SecurityRealm core class already defines the so-called IdStrategy which contain various methods for comparing and sorting user ids. I think the input step logic around validating the current user against the submitters list should be using this implementation.

      References:

            batmat Baptiste Mathus
            batmat Baptiste Mathus
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: