• Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None

      In the environment I am working, the current configuration and version messes with the output logs, and they contain extra asterisks around all the characters (screenshot attached). Though, the only character missing is e — this one is completely missing from logs.

      I have looked through Jenkins (and plugins) code and Jira, and have found few possible things:

      The thing is, it's only happening for Groovy defined DSL with Kubernetes (see screenshot, echo step before have normal logs; everything inside podTemplate has asterisks) and similar code:

          pipeline {
              agent {
                  kubernetes {
                      yaml '''
      apiVersion: v1
      kind: Pod
      metadata:
      '''
                      defaultContainer 'shell'
                  }
              }
              stages {
                  stage('CleanWorkspace') {
                      steps {
                          script {
                                  
                          }
                      }
                  }
      

      Because anything inside stages will have asterisk, I guess it's either credentials-binding-plugin or kubernetes-plugin.

      I would appreciate help to narrow down this error and fix it.

          [JENKINS-72763] Extra asterisks in the output logs

          Andrew added a comment - - edited

          I was trying to check log level ALL for the following classes:

          org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker
          hudson.plugins.gradle.injection.GradleEnterpriseExceptionTaskListenerDecoratorFactory
          hudson.util.StreamTaskListener
          org.jenkinsci.plugins.workflow.log.TaskListenerDecorator
          

          But, without any success and no idea where it's being replaced.

          I did saw these in SecretsMasker from Kubernetes plugin, but the 4th secret is JnlpMac in here.

          Mar 22, 2024 1:44:57 PM FINE org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker
          found value for SECRET1
          Mar 22, 2024 1:44:57 PM FINE org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker
          found value for SECRET2
          Mar 22, 2024 3:44:57 PM FINE org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker
          found value for SECRET3
          Mar 22, 2024 1:44:57 PM FINE org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker
          masking 4 values
          

          Those 3 secrets are not empty.

          Andrew added a comment - - edited I was trying to check log level ALL for the following classes: org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker hudson.plugins.gradle.injection.GradleEnterpriseExceptionTaskListenerDecoratorFactory hudson.util.StreamTaskListener org.jenkinsci.plugins.workflow.log.TaskListenerDecorator But, without any success and no idea where it's being replaced. I did saw these in SecretsMasker from Kubernetes plugin, but the 4th secret is JnlpMac in here . Mar 22, 2024 1:44:57 PM FINE org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker found value for SECRET1 Mar 22, 2024 1:44:57 PM FINE org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker found value for SECRET2 Mar 22, 2024 3:44:57 PM FINE org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker found value for SECRET3 Mar 22, 2024 1:44:57 PM FINE org.csanchez.jenkins.plugins.kubernetes.pipeline.SecretsMasker masking 4 values Those 3 secrets are not empty.

          Andrew added a comment -

          The issue was a newline in the environment variable that was updated from value to contain formatted JSON.

          Not sure why or how it's caused it though...

          Andrew added a comment - The issue was a newline in the environment variable that was updated from value to contain formatted JSON. Not sure why or how it's caused it though...

            Unassigned Unassigned
            andrewpro Andrew
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: