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

P4 trigger checked permission (only build) is not enough to actually run the jobs

    Details

    • Similar Issues:

      Description

      Hello,

      We were struggling with a real p4 trigger not probing the jobs (while manual one worked perfectly fine).

      It came out, that a job's build permission on anonymous user is not enough, as it's handler, P4Hook.doChange, when calls getJobs(), actually returns 0 jobs (tested with custom build of p4.hpi and additional logging). That was weird... but hinted me that maybe context of anonymous user have something to do with it, as manual trigger is able to successfully call getJobs() when user is fully authenticated. Adding Job Read permission on anonymous user at Matrix-based security fixed our issue.

      I would like to ask adding additional permission check of type read around here:
      https://github.com/jenkinsci/p4-plugin/blob/c421b5497182e11343f26abccdb69948c52e7305/src/main/java/org/jenkinsci/plugins/p4/trigger/P4Hook.java#L79

      ... unless it should work as it is and issue is somewhere else.

      Thanks,

      Maciej

        Attachments

          Activity

          Hide
          p4karl Karl Wirth added a comment -

          Thanks Maciej Matczak - Thanks. I have discussed this with the developers and we will look into it.

          Show
          p4karl Karl Wirth added a comment - Thanks Maciej Matczak - Thanks. I have discussed this with the developers and we will look into it.

            People

            • Assignee:
              Unassigned
              Reporter:
              mmatczak Maciej Matczak
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: