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

Mask Passwords doen't mask Credentials Parameter

    XMLWordPrintable

Details

    • New Feature
    • Status: Resolved (View Workflow)
    • Minor
    • Resolution: Fixed
    • mask-passwords-plugin
    • None

    Description

      After installing Mask Passwords Plugin 2.7.2, it allows the system configuration to set the passwords to be masked. One of which is Credentials Parameter.

      However, in a project, if mask passwords is selected and an existing credential is used in the build step, the information is still displayed plaintext within the console output.

      Steps To Reproduce:

      1. Configure System
        • Mask Passwords - Parameters to automatically mask
          [x] Non-Stored Password Parameter
          [x] Credentials Parameter
          [x] Password Parameter
        • Mask Passwords - Global name/password pairs
          None added.
          I already have several "Username with password" Global credentials
      2. Create freestyle project
        • [x] Mask passwords (and enable global passwords)
          Responce: Password Parameters, or any other type of build parameters selected for masking in Hudson's/Jenkins' main configuration screen (Manage Hudson > Configure System), will be automatically masked.
        • [x] Use secret text(s) or file(s)
          Add: Username and password
          Variable: oracleCredential
          Credentials
          (*) Specific credentials
          my_oracle_username/***** (Oracle remote login)
          parameter expression: ${oracleCredential}
        • Add build step: Execute Windows batch command
          Command: @echo %oracleCredential%
        • [Save]
      3. Build Now, and examine Console Output
        Expected: ********** is displayed in place of %oracleCredential%
        Actual: Actual username:password value of %oracleCredential% is displayed.

      Attachments

        Issue Links

          Activity

            Code changed in jenkins
            User: Oleg Nenashev
            Path:
            src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsConfig.java
            src/test/java/com/michelin/cio/hudson/plugins/integrations/CorePasswordParameterTest.java
            src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordConfigTests.java
            src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsURLEncodingTest.java
            src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsWorkflowTest.java
            src/test/java/com/michelin/cio/hudson/plugins/passwordparam/PasswordParameterTest.java
            http://jenkins-ci.org/commit/mask-passwords-plugin/3d57fab2af5d3016e9bfd19eacca60095f744811
            Log:
            JENKINS-25735 JENKINS-41995 - Create more tests

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsConfig.java src/test/java/com/michelin/cio/hudson/plugins/integrations/CorePasswordParameterTest.java src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordConfigTests.java src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsURLEncodingTest.java src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsWorkflowTest.java src/test/java/com/michelin/cio/hudson/plugins/passwordparam/PasswordParameterTest.java http://jenkins-ci.org/commit/mask-passwords-plugin/3d57fab2af5d3016e9bfd19eacca60095f744811 Log: JENKINS-25735 JENKINS-41995 - Create more tests

            Code changed in jenkins
            User: Oleg Nenashev
            Path:
            src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsConfig.java
            src/test/java/com/michelin/cio/hudson/plugins/integrations/CorePasswordParameterTest.java
            http://jenkins-ci.org/commit/mask-passwords-plugin/0a73ebe8af0602cacdfa277df66f2685879a08a0
            Log:
            JENKINS-25735 - Always allow hudson.model.Passwordparameter and its children

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsConfig.java src/test/java/com/michelin/cio/hudson/plugins/integrations/CorePasswordParameterTest.java http://jenkins-ci.org/commit/mask-passwords-plugin/0a73ebe8af0602cacdfa277df66f2685879a08a0 Log: JENKINS-25735 - Always allow hudson.model.Passwordparameter and its children

            Code changed in jenkins
            User: Oleg Nenashev
            Path:
            src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsConfig.java
            http://jenkins-ci.org/commit/mask-passwords-plugin/590e5df2b5ddae474d191079e40ae127f3cb984b
            Log:
            JENKINS-25735 - Make FindBugs happy & improve diagnostics

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsConfig.java http://jenkins-ci.org/commit/mask-passwords-plugin/590e5df2b5ddae474d191079e40ae127f3cb984b Log: JENKINS-25735 - Make FindBugs happy & improve diagnostics

            Code changed in jenkins
            User: Oleg Nenashev
            Path:
            src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsBuildWrapper.java
            src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsConfig.java
            src/main/java/com/michelin/cio/hudson/plugins/passwordparam/PasswordParameterDefinition.java
            src/test/java/com/michelin/cio/hudson/plugins/integrations/CorePasswordParameterTest.java
            src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordConfigTests.java
            src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsURLEncodingTest.java
            src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsWorkflowTest.java
            src/test/java/com/michelin/cio/hudson/plugins/passwordparam/PasswordParameterTest.java
            http://jenkins-ci.org/commit/mask-passwords-plugin/bd5f530db9c5275313de247dfd3c8957a88222a6
            Log:
            Merge pull request #12 from oleg-nenashev/JENKINS-25735-41955-mask-passwords

            [JENKINS-25735, JENKINS-41955, etc.] Improve masking of passwords in the plugin

            Compare: https://github.com/jenkinsci/mask-passwords-plugin/compare/93abe61816c3...bd5f530db9c5

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsBuildWrapper.java src/main/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsConfig.java src/main/java/com/michelin/cio/hudson/plugins/passwordparam/PasswordParameterDefinition.java src/test/java/com/michelin/cio/hudson/plugins/integrations/CorePasswordParameterTest.java src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordConfigTests.java src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsURLEncodingTest.java src/test/java/com/michelin/cio/hudson/plugins/maskpasswords/MaskPasswordsWorkflowTest.java src/test/java/com/michelin/cio/hudson/plugins/passwordparam/PasswordParameterTest.java http://jenkins-ci.org/commit/mask-passwords-plugin/bd5f530db9c5275313de247dfd3c8957a88222a6 Log: Merge pull request #12 from oleg-nenashev/ JENKINS-25735 -41955-mask-passwords [JENKINS-25735, JENKINS-41955, etc.] Improve masking of passwords in the plugin Compare: https://github.com/jenkinsci/mask-passwords-plugin/compare/93abe61816c3...bd5f530db9c5
            oleg_nenashev Oleg Nenashev added a comment -

            I suppose it's fixed now. If no, please reopen

            oleg_nenashev Oleg Nenashev added a comment - I suppose it's fixed now. If no, please reopen

            People

              oleg_nenashev Oleg Nenashev
              marshall Marshall GSEIT
              Votes:
              7 Vote for this issue
              Watchers:
              11 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: