Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-3634

jboss-cli.sh: --no-local-auth does not appear to work anymore

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • 7.0.0.ER6, 7.0.2.GA
    • 7.0.0.ER2 (Beta)
    • None
    • None
    • Hide

      First, run a command that succeeds because auth credentials are provided

      $ /opt/eap/bin/jboss-cli.sh -c --no-local-auth --command=version --user=admin2 --password=lollerskates11$
      Picked up JAVA_TOOL_OPTIONS: -Duser.home=/home/jboss -Duser.name=jboss
      JBoss Admin Command-line Interface
      JBOSS_HOME: /opt/eap
      JBoss AS release: 2.0.3.Final-redhat-1 "Kenny"
      JBoss AS product: EAP 7.0.0.Beta1
      JAVA_HOME: /usr/lib/jvm/java-1.8.0
      java.version: 1.8.0_71
      java.vm.vendor: Oracle Corporation
      java.vm.version: 25.71-b15
      os.name: Linux
      os.version: 3.10.0-229.4.2.el7.x86_64

      Then retry this time omitting the credentials

      $ /opt/eap/bin/jboss-cli.sh -c --no-local-auth --command=version
      Picked up JAVA_TOOL_OPTIONS: -Duser.home=/home/jboss -Duser.name=jboss
      JBoss Admin Command-line Interface
      JBOSS_HOME: /opt/eap
      JBoss AS release: 2.0.3.Final-redhat-1 "Kenny"
      JBoss AS product: EAP 7.0.0.Beta1
      JAVA_HOME: /usr/lib/jvm/java-1.8.0
      java.version: 1.8.0_71
      java.vm.vendor: Oracle Corporation
      java.vm.version: 25.71-b15
      os.name: Linux
      os.version: 3.10.0-229.4.2.el7.x86_64

      Behaviour with 6.4:

      $ /opt/eap/bin/jboss-cli.sh -c --no-local-auth --command=version </dev/null
      Picked up JAVA_TOOL_OPTIONS: -Duser.home=/home/jboss -Duser.name=jboss
      Authenticating against security realm: ManagementRealm
      Username: org.jboss.as.cli.CliInitializationException: Failed to connect to the controller
      ...

      Show
      First, run a command that succeeds because auth credentials are provided $ /opt/eap/bin/jboss-cli.sh -c --no-local-auth --command=version --user=admin2 --password=lollerskates11$ Picked up JAVA_TOOL_OPTIONS: -Duser.home=/home/jboss -Duser.name=jboss JBoss Admin Command-line Interface JBOSS_HOME: /opt/eap JBoss AS release: 2.0.3.Final-redhat-1 "Kenny" JBoss AS product: EAP 7.0.0.Beta1 JAVA_HOME: /usr/lib/jvm/java-1.8.0 java.version: 1.8.0_71 java.vm.vendor: Oracle Corporation java.vm.version: 25.71-b15 os.name: Linux os.version: 3.10.0-229.4.2.el7.x86_64 Then retry this time omitting the credentials $ /opt/eap/bin/jboss-cli.sh -c --no-local-auth --command=version Picked up JAVA_TOOL_OPTIONS: -Duser.home=/home/jboss -Duser.name=jboss JBoss Admin Command-line Interface JBOSS_HOME: /opt/eap JBoss AS release: 2.0.3.Final-redhat-1 "Kenny" JBoss AS product: EAP 7.0.0.Beta1 JAVA_HOME: /usr/lib/jvm/java-1.8.0 java.version: 1.8.0_71 java.vm.vendor: Oracle Corporation java.vm.version: 25.71-b15 os.name: Linux os.version: 3.10.0-229.4.2.el7.x86_64 Behaviour with 6.4: $ /opt/eap/bin/jboss-cli.sh -c --no-local-auth --command=version </dev/null Picked up JAVA_TOOL_OPTIONS: -Duser.home=/home/jboss -Duser.name=jboss Authenticating against security realm: ManagementRealm Username: org.jboss.as.cli.CliInitializationException: Failed to connect to the controller ...

      The CLI argument --no-local-auth does not appear to work anymore: when supplied, a command that should fail due to lacking authorization completes.

      (why would you want to do this? It's part of our regression-testing suite.)

              spyrkob Bartosz Spyrko-Smietanko
              jdowland@redhat.com Jonathan Dowland
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: