Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-2406

Credential store alias with upper-case letters can't be added when Java assertions are enabled

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • 3.0.0.Beta14
    • None
    • Security
    • None
    • Hide
      echo 'JAVA_OPTS="$JAVA_OPTS -ea"' >> $JBOSS_HOME/bin/standalone.conf
      $JBOSS_HOME/bin/standalone.sh
      $JBOSS_HOME/bin/jboss-cli.sh -c <<EOT
      /subsystem=elytron/credential-store=cred-store-default:add(uri="cr-store://cred-store-default/cred-store.jceks?keyStoreType=JCEKS;modifiable=true;create=true", relative-to=jboss.server.config.dir, credential-reference={clear-text=password})
      /subsystem=elytron/credential-store=cred-store-default/alias=Alias1:add(secret-value=password)
      EOT
      

      The CLI command fails with following entry in server log:

      11:24:57,220 ERROR [org.jboss.as.controller.management-operation] (management-handler-thread - 3) WFLYCTL0013: Operation ("add") failed - address: ([
          ("subsystem" => "elytron"),
          ("credential-store" => "cred-store-default"),
          ("alias" => "alias1")
      ]): java.lang.AssertionError
      	at org.jboss.as.controller.access.permission.ManagementPermissionAuthorizer.authorize(ManagementPermissionAuthorizer.java:87)
      	at org.jboss.as.controller.access.management.DelegatingConfigurableAuthorizer.authorize(DelegatingConfigurableAuthorizer.java:99)
      	at org.jboss.as.controller.OperationContextImpl.getBasicAuthorizationResponse(OperationContextImpl.java:1841)
      	at org.jboss.as.controller.OperationContextImpl.authorize(OperationContextImpl.java:1739)
      	at org.jboss.as.controller.OperationContextImpl.authorize(OperationContextImpl.java:1698)
      	at org.jboss.as.controller.OperationContextImpl.getResourceRegistration(OperationContextImpl.java:575)
      	at org.jboss.as.controller.AbstractAddStepHandler.recordCapabilitiesAndRequirements(AbstractAddStepHandler.java:270)
      	at org.jboss.as.controller.AbstractAddStepHandler.execute(AbstractAddStepHandler.java:146)
      	at org.wildfly.extension.elytron.CredentialStoreAliasDefinition$AddHandler.execute(CredentialStoreAliasDefinition.java:207)
      	at org.jboss.as.controller.AbstractOperationContext.executeStep(AbstractOperationContext.java:921)
      	at org.jboss.as.controller.AbstractOperationContext.processStages(AbstractOperationContext.java:664)
      	at org.jboss.as.controller.AbstractOperationContext.executeOperation(AbstractOperationContext.java:383)
      	at org.jboss.as.controller.OperationContextImpl.executeOperation(OperationContextImpl.java:1390)
      	at org.jboss.as.controller.ModelControllerImpl.internalExecute(ModelControllerImpl.java:419)
      	at org.jboss.as.controller.ModelControllerImpl.lambda$execute$1(ModelControllerImpl.java:240)
      	at org.wildfly.security.auth.server.SecurityIdentity.runAs(SecurityIdentity.java:258)
      	at org.jboss.as.controller.ModelControllerImpl.execute(ModelControllerImpl.java:240)
      	at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler.doExecute(ModelControllerClientOperationHandler.java:217)
      	at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler.access$400(ModelControllerClientOperationHandler.java:137)
      	at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler$1$1.run(ModelControllerClientOperationHandler.java:161)
      	at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler$1$1.run(ModelControllerClientOperationHandler.java:157)
      	at org.wildfly.security.auth.server.SecurityIdentity.runAs(SecurityIdentity.java:277)
      	at org.jboss.as.controller.AccessAuditContext.doAs(AccessAuditContext.java:254)
      	at org.jboss.as.controller.AccessAuditContext.doAs(AccessAuditContext.java:225)
      	at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler$1.execute(ModelControllerClientOperationHandler.java:157)
      	at org.jboss.as.protocol.mgmt.ManagementRequestContextImpl$1.doExecute(ManagementRequestContextImpl.java:70)
      	at org.jboss.as.protocol.mgmt.ManagementRequestContextImpl$AsyncTaskRunner.run(ManagementRequestContextImpl.java:160)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:745)
      	at org.jboss.threads.JBossThread.run(JBossThread.java:320)
      
      Show
      echo 'JAVA_OPTS= "$JAVA_OPTS -ea" ' >> $JBOSS_HOME/bin/standalone.conf $JBOSS_HOME/bin/standalone.sh $JBOSS_HOME/bin/jboss-cli.sh -c <<EOT /subsystem=elytron/credential-store=cred-store- default :add(uri= "cr-store: //cred-store- default /cred-store.jceks?keyStoreType=JCEKS;modifiable= true ;create= true " , relative-to=jboss.server.config.dir, credential-reference={clear-text=password}) /subsystem=elytron/credential-store=cred-store- default /alias=Alias1:add(secret-value=password) EOT The CLI command fails with following entry in server log: 11:24:57,220 ERROR [org.jboss.as.controller.management-operation] (management-handler-thread - 3) WFLYCTL0013: Operation ( "add" ) failed - address: ([ ( "subsystem" => "elytron" ), ( "credential-store" => "cred-store- default " ), ( "alias" => "alias1" ) ]): java.lang.AssertionError at org.jboss.as.controller.access.permission.ManagementPermissionAuthorizer.authorize(ManagementPermissionAuthorizer.java:87) at org.jboss.as.controller.access.management.DelegatingConfigurableAuthorizer.authorize(DelegatingConfigurableAuthorizer.java:99) at org.jboss.as.controller.OperationContextImpl.getBasicAuthorizationResponse(OperationContextImpl.java:1841) at org.jboss.as.controller.OperationContextImpl.authorize(OperationContextImpl.java:1739) at org.jboss.as.controller.OperationContextImpl.authorize(OperationContextImpl.java:1698) at org.jboss.as.controller.OperationContextImpl.getResourceRegistration(OperationContextImpl.java:575) at org.jboss.as.controller.AbstractAddStepHandler.recordCapabilitiesAndRequirements(AbstractAddStepHandler.java:270) at org.jboss.as.controller.AbstractAddStepHandler.execute(AbstractAddStepHandler.java:146) at org.wildfly.extension.elytron.CredentialStoreAliasDefinition$AddHandler.execute(CredentialStoreAliasDefinition.java:207) at org.jboss.as.controller.AbstractOperationContext.executeStep(AbstractOperationContext.java:921) at org.jboss.as.controller.AbstractOperationContext.processStages(AbstractOperationContext.java:664) at org.jboss.as.controller.AbstractOperationContext.executeOperation(AbstractOperationContext.java:383) at org.jboss.as.controller.OperationContextImpl.executeOperation(OperationContextImpl.java:1390) at org.jboss.as.controller.ModelControllerImpl.internalExecute(ModelControllerImpl.java:419) at org.jboss.as.controller.ModelControllerImpl.lambda$execute$1(ModelControllerImpl.java:240) at org.wildfly.security.auth.server.SecurityIdentity.runAs(SecurityIdentity.java:258) at org.jboss.as.controller.ModelControllerImpl.execute(ModelControllerImpl.java:240) at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler.doExecute(ModelControllerClientOperationHandler.java:217) at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler.access$400(ModelControllerClientOperationHandler.java:137) at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler$1$1.run(ModelControllerClientOperationHandler.java:161) at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler$1$1.run(ModelControllerClientOperationHandler.java:157) at org.wildfly.security.auth.server.SecurityIdentity.runAs(SecurityIdentity.java:277) at org.jboss.as.controller.AccessAuditContext.doAs(AccessAuditContext.java:254) at org.jboss.as.controller.AccessAuditContext.doAs(AccessAuditContext.java:225) at org.jboss.as.controller.remote.ModelControllerClientOperationHandler$ExecuteRequestHandler$1.execute(ModelControllerClientOperationHandler.java:157) at org.jboss.as.protocol.mgmt.ManagementRequestContextImpl$1.doExecute(ManagementRequestContextImpl.java:70) at org.jboss.as.protocol.mgmt.ManagementRequestContextImpl$AsyncTaskRunner.run(ManagementRequestContextImpl.java:160) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang. Thread .run( Thread .java:745) at org.jboss.threads.JBossThread.run(JBossThread.java:320)

      When Java assertions are enable then adding credential store entry (alias) with upper case letters fails with assertion error.

              ehugonne1@redhat.com Emmanuel Hugonnet
              josef.cacek@gmail.com Josef Cacek (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: