Uploaded image for project: 'JBoss A-MQ'
  1. JBoss A-MQ
  2. ENTMQ-134

mq-create commands are not working with security introduced

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 7.1.0.fuse-046
    • 7.1.0.fuse-046
    • None
    • None

      We need to get mq-create command aligned with new security mechanism introduced. Currently, executing| mq-create --create-container broker1 broker1|

      gives the follwogin exception| apache.karaf.shell.console - 2.3.0.fuse-71-036 | Exception caught while executing command|

      org.fusesource.fabric.api.FabricException: java.lang.SecurityException: Authentication failed
      at org.fusesource.fabric.service.FabricServiceImpl.createContainers(FabricServiceImpl.java:310)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at org.apache.aries.proxy.impl.ProxyHandler$1.invoke(ProxyHandler.java:54)
      at org.apache.aries.proxy.impl.ProxyHandler.invoke(ProxyHandler.java:119)
      at $Proxy32.createContainers(Unknown Source)
      at org.fusesource.fabric.commands.MQCreate.doExecute(MQCreate.java:141)
      at org.apache.karaf.shell.console.OsgiCommandSupport.execute(OsgiCommandSupport.java:38)
      at org.apache.felix.gogo.commands.basic.AbstractCommand.execute(AbstractCommand.java:35)
      at org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:78)
      at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:474)
      at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:400)
      at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)
      at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:183)
      at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:120)
      at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:89)
      at org.apache.karaf.shell.console.jline.Console.run(Console.java:171)
      at org.apache.karaf.shell.console.jline.DelayedStarted.run(DelayedStarted.java:61)
      Caused by: java.lang.SecurityException: Authentication failed
      at org.apache.karaf.management.JaasAuthenticator.authenticate(JaasAuthenticator.java:101)
      at javax.management.remote.rmi.RMIServerImpl.doNewClient(RMIServerImpl.java:213)
      at javax.management.remote.rmi.RMIServerImpl.newClient(RMIServerImpl.java:180)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:303)
      at sun.rmi.transport.Transport$1.run(Transport.java:159)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.rmi.transport.Transport.serviceCall(Transport.java:155)
      at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      at java.lang.Thread.run(Thread.java:680)
      at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:255)
      at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:233)
      at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:142)
      at javax.management.remote.rmi.RMIServerImpl_Stub.newClient(Unknown Source)
      at javax.management.remote.rmi.RMIConnector.getConnection(RMIConnector.java:2327)
      at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:277)
      at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:248)
      at org.fusesource.fabric.service.ContainerTemplate.createConnector(ContainerTemplate.java:164)
      at org.fusesource.fabric.service.ContainerTemplate$1.createConnector(ContainerTemplate.java:55)
      at org.fusesource.fabric.service.NonCachingJmxTemplate.execute(NonCachingJmxTemplate.java:36)
      at org.fusesource.fabric.service.ContainerTemplate.execute(ContainerTemplate.java:96)
      at org.fusesource.fabric.service.ChildContainerProvider.create(ChildContainerProvider.java:70)
      at org.fusesource.fabric.service.ChildContainerProvider.create(ChildContainerProvider.java:44)
      at org.fusesource.fabric.service.FabricServiceImpl.createContainers(FabricServiceImpl.java:262)
      ... 19 more
      Caused by: javax.security.auth.login.LoginException: java.lang.NullPointerException
      at org.apache.karaf.management.JaasAuthenticator$1.handle(JaasAuthenticator.java:71)
      at javax.security.auth.login.LoginContext$SecureCallbackHandler$1.run(LoginContext.java:955)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.login.LoginContext$SecureCallbackHandler.handle(LoginContext.java:951)
      at org.fusesource.fabric.jaas.ZookeeperLoginModule.login(ZookeeperLoginModule.java:98)
      at org.apache.karaf.jaas.boot.ProxyLoginModule.login(ProxyLoginModule.java:83)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at javax.security.auth.login.LoginContext.invoke(LoginContext.java:769)
      at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
      at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
      at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
      at org.apache.karaf.management.JaasAuthenticator.authenticate(JaasAuthenticator.java:78)
      at javax.management.remote.rmi.RMIServerImpl.doNewClient(RMIServerImpl.java:213)
      at javax.management.remote.rmi.RMIServerImpl.newClient(RMIServerImpl.java:180)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:303)
      at sun.rmi.transport.Transport$1.run(Transport.java:159)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.rmi.transport.Transport.serviceCall(Transport.java:155)
      at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      at java.lang.Thread.run(Thread.java:680)
       
      at javax.security.auth.login.LoginContext.invoke(LoginContext.java:872)
      at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
      at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
      at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
      at org.apache.karaf.management.JaasAuthenticator.authenticate(JaasAuthenticator.java:78)
      at javax.management.remote.rmi.RMIServerImpl.doNewClient(RMIServerImpl.java:213)
      at javax.management.remote.rmi.RMIServerImpl.newClient(RMIServerImpl.java:180)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:303)
      at sun.rmi.transport.Transport$1.run(Transport.java:159)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.rmi.transport.Transport.serviceCall(Transport.java:155)
      at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      at java.lang.Thread.run(Thread.java:680)

              dejanbosanac Dejan Bosanac
              dejanbosanac Dejan Bosanac
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: