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

Groovy-Scripts with CLI are not working with Crowd 2 Plugin

      Hello,

      I'm using a groovy-script to look for public-projects, executing this with the jenkins-cli:
      java -jar jenkins-cli.jar -s http://<url>:8080/ groovy displayJobWithAnonymousAccess.groovy
      (using this script: http://scriptlerweb.appspot.com/script/show/74001)

      With LDAP-authentification everything is working fine (using a ssh-key in the personal configuration - me/configure).
      But changing the authentication-type to crowd2 it is not working anymore.

      Before:
      + java -jar jenkins-cli.jar -s http://<url>:8080/ groovy displayJobWithAnonymousAccess.groovy
      + [ -s ./result ]
      + cat ./result
      Anonymous-User has Access to BusyWaiting - Permission[class hudson.scm.SCM,Tag]:[anonymous]
      + exit 1
      Build step 'Execute shell' marked build as failure

      After:
      + java -jar jenkins-cli.jar -s http://<url>:8080/ groovy displayJobWithAnonymousAccess.groovy
      Exception in thread "main" java.io.EOFException
      at java.io.DataInputStream.readBoolean(Unknown Source)
      at hudson.cli.Connection.readBoolean(Connection.java:90)
      at hudson.cli.CLI.authenticate(CLI.java:560)
      at hudson.cli.CLI._main(CLI.java:400)
      at hudson.cli.CLI.main(CLI.java:330)
      Build step 'Execute shell' marked build as failure

      I don't know where to search for this failure. Any idea?

      Thomas

          [JENKINS-15784] Groovy-Scripts with CLI are not working with Crowd 2 Plugin

          Thomas S. created issue -
          Thomas S. made changes -
          Description Original: Hello,

          I'm using a groovy-script to look for public-projects, executing this with the jenkins-cli:
          java -jar jenkins-cli.jar -s http://&lt;url&gt;:8080/ groovy displayJobWithAnonymousAccess.groovy
          (using this script: http://scriptlerweb.appspot.com/script/show/74001)

          With LDAP-authentification everything is working fine (using a ssh-key in the personal configuration - me/configure).
          But changing the authentication-type to crowd2 it is not working anymore.

          Before:
          + java -jar jenkins-cli.jar -s http://&lt;url&gt;:8080/ groovy displayJobWithAnonymousAccess.groovy
          + [ -s ./result ]
          + cat ./result
          Anonymous-User has Access to BusyWaiting - Permission[class hudson.scm.SCM,Tag]:[anonymous]
          + exit 1
          Build step 'Execute shell' marked build as failure


          After:
          + java -jar jenkins-cli.jar -s http://ete5.e-konzern.de:8080/ groovy displayJobWithAnonymousAccess.groovy
          Exception in thread "main" java.io.EOFException
          at java.io.DataInputStream.readBoolean(Unknown Source)
          at hudson.cli.Connection.readBoolean(Connection.java:90)
          at hudson.cli.CLI.authenticate(CLI.java:560)
          at hudson.cli.CLI._main(CLI.java:400)
          at hudson.cli.CLI.main(CLI.java:330)
          Build step 'Execute shell' marked build as failure



          I don't know where to search for this failure. Any idea?

          Thomas
          New: Hello,

          I'm using a groovy-script to look for public-projects, executing this with the jenkins-cli:
          java -jar jenkins-cli.jar -s http://&lt;url&gt;:8080/ groovy displayJobWithAnonymousAccess.groovy
          (using this script: http://scriptlerweb.appspot.com/script/show/74001)

          With LDAP-authentification everything is working fine (using a ssh-key in the personal configuration - me/configure).
          But changing the authentication-type to crowd2 it is not working anymore.

          Before:
          + java -jar jenkins-cli.jar -s http://&lt;url&gt;:8080/ groovy displayJobWithAnonymousAccess.groovy
          + [ -s ./result ]
          + cat ./result
          Anonymous-User has Access to BusyWaiting - Permission[class hudson.scm.SCM,Tag]:[anonymous]
          + exit 1
          Build step 'Execute shell' marked build as failure


          After:
          + java -jar jenkins-cli.jar -s http://&lt;url&gt;:8080/ groovy displayJobWithAnonymousAccess.groovy
          Exception in thread "main" java.io.EOFException
          at java.io.DataInputStream.readBoolean(Unknown Source)
          at hudson.cli.Connection.readBoolean(Connection.java:90)
          at hudson.cli.CLI.authenticate(CLI.java:560)
          at hudson.cli.CLI._main(CLI.java:400)
          at hudson.cli.CLI.main(CLI.java:330)
          Build step 'Execute shell' marked build as failure



          I don't know where to search for this failure. Any idea?

          Thomas
          Thomas S. made changes -
          Component/s New: crowd [ 15601 ]
          Priority Original: Critical [ 2 ] New: Blocker [ 1 ]
          Thomas S. made changes -
          Labels New: cli crowd crowd2 jenkins login username
          Thomas S. made changes -
          Resolution New: Cannot Reproduce [ 5 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 146585 ] New: JNJira + In-Review [ 191987 ]
          Martin Spielmann made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]

            t_heit Thorsten Heit
            thosor Thomas S.
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: