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

Credentials became unusable after it's update.

      Found issue on credentials plugin side. Credentials became unusable after updating it's value. 
      Steps to reproduce
      1. Create new credentials, for gitlab access token (just an example). Use it in a pipeline, Should work. 
      2. Generate a new token on gitlab side.
      3. Update existing credentials with new token and try to use it in pipeline. Will not work and return "Unauthorized" from gitlab side.

      Gitlab here is just an example, the same behavior we can see with any credentials.  

      Jenkins version: 2.452.1
      Credentials plugin version: 1371.vfee6b_095f0a_3

      Is it a known bug?

          [JENKINS-73665] Credentials became unusable after it's update.

          Mark Waite added a comment -

          I'm unable to duplicate the bug. I installed Jenkins 2.452.1 and credentials plugin 1371.x, configured a GitLab organization folder and a GitLab muultibranch Pipeline with working credentials, scanned the organization folder and the multibranch Pipeline, then created a new GitLab access token, updated the values in the Jenkins credentials, and confirmed that the new credentials worked as expected in both cases.

          Can you provide more details so that others can duplicate the issue?

          Mark Waite added a comment - I'm unable to duplicate the bug. I installed Jenkins 2.452.1 and credentials plugin 1371.x, configured a GitLab organization folder and a GitLab muultibranch Pipeline with working credentials, scanned the organization folder and the multibranch Pipeline, then created a new GitLab access token, updated the values in the Jenkins credentials, and confirmed that the new credentials worked as expected in both cases. Can you provide more details so that others can duplicate the issue?

          Hi markewaite ,

          even i have similar issue in using jenkins token in my pipeline.after few hours token is unusable

          401 issue while trying to download artifact from JMaas in Jenkins

          Problem Statement: Jenkins API Status Code is 401 while trying to download artifact from JMaas URL in Jenkins

          The same issue is not persisting if we try to open same url in jenkins machine and after 3 hours automatically pipeline is failing while trying to access JMaas and download artifact.

          SHIVAKUMAR B M added a comment - Hi markewaite , even i have similar issue in using jenkins token in my pipeline.after few hours token is unusable 401 issue while trying to download artifact from JMaas in Jenkins Problem Statement: Jenkins API Status Code is 401 while trying to download artifact from JMaas URL in Jenkins The same issue is not persisting if we try to open same url in jenkins machine and after 3 hours automatically pipeline is failing while trying to access JMaas and download artifact.

          Mark Waite added a comment -

          shivuboschbm my tests were focused on the GitLab access token. I don't know what JMaas is, but I assume that it is not GitLab. I doubt that this issue is the same as the issue you are encountering.

          Mark Waite added a comment - shivuboschbm my tests were focused on the GitLab access token. I don't know what JMaas is, but I assume that it is not GitLab. I doubt that this issue is the same as the issue you are encountering.

          Hi markewaite,

          The same issue is in jenkins.

          when we use jenkns token to download artifacts from other job after 2 hours we are getting 401 issue 

          SHIVAKUMAR B M added a comment - Hi markewaite , The same issue is in jenkins. when we use jenkns token to download artifacts from other job after 2 hours we are getting 401 issue 

          Mark Waite added a comment -

          shivuboschbm you'll need to provide many, many more details before I'll be persuaded that the issue you are seeing is the same as this issue.

          Mark Waite added a comment - shivuboschbm you'll need to provide many, many more details before I'll be persuaded that the issue you are seeing is the same as this issue.

          Hi markewaite ,

          Can we have short screen sharing sesssion today so that we can show the exact issue 

          SHIVAKUMAR B M added a comment - Hi markewaite , Can we have short screen sharing sesssion today so that we can show the exact issue 

          Mark Waite added a comment -

          Can we have short screen sharing session today so that we can show the exact issue

          No. I'm sorry, but I don't do screen sharing sessions to diagnose issues.

          Mark Waite added a comment - Can we have short screen sharing session today so that we can show the exact issue No. I'm sorry, but I don't do screen sharing sessions to diagnose issues.

          Hi markewaite ,

          please find below steps to reproduce the token issue 

          Steps to re-produce the issue:

          1. Create new API credentials in Jenkins and pass that token as Environment Variable in Jenkins Script.
          2. In Jenkins upstream pipeline, add stage to download artifact from downstream pipeline by accessing Jenkins URL using the API credentials which is mentioned in Environment Variable.
          3. The pipeline will fail due to 401 Access Issue while trying to access URL to download artifact.
          4. The same pipeline will work for minimum 2 hours once we open the Jenkins URL in Jenkins Windows machine manually and tried to run the pipeline from Jenkins Website locally without any issue.
          5. After 2 hours, if we try to re-trigger the pipeline again its failing due to 401 access issue while trying to access URL to download artifact.

           

          SHIVAKUMAR B M added a comment - Hi markewaite , please find below steps to reproduce the token issue  Steps to re-produce the issue: Create new API credentials in Jenkins and pass that token as Environment Variable in Jenkins Script. In Jenkins upstream pipeline, add stage to download artifact from downstream pipeline by accessing Jenkins URL using the API credentials which is mentioned in Environment Variable. The pipeline will fail due to 401 Access Issue while trying to access URL to download artifact. The same pipeline will work for minimum 2 hours once we open the Jenkins URL in Jenkins Windows machine manually and tried to run the pipeline from Jenkins Website locally without any issue. After 2 hours, if we try to re-trigger the pipeline again its failing due to 401 access issue while trying to access URL to download artifact.  

          Mark Waite added a comment -

          shivuboschbm your description seem to me that it has nothing to do with this issue. This issue is focused on a GitLab access token and an update to the GitLab access token that is not applied to Jenkins operations after the GitLab access token is updated in Jenkins.

          Please open a new issue and include more detailed steps (Pipeline definition, etc.) so that others can duplicate the problem.

          Mark Waite added a comment - shivuboschbm your description seem to me that it has nothing to do with this issue. This issue is focused on a GitLab access token and an update to the GitLab access token that is not applied to Jenkins operations after the GitLab access token is updated in Jenkins. Please open a new issue and include more detailed steps (Pipeline definition, etc.) so that others can duplicate the problem.

            Unassigned Unassigned
            ezhuravlev Evgeny
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: