Hi All
I am new to working with ActiveMQ and I have a requirement to connect
ActiveMQ (version 5.9.0) with OpenLDAP for authentication and authorization.
I have started doing this and currently stuck with an issue for few days.
Given below is the error I see when running my Java Client.
javax.jms.JMSSecurityException: *User amqadmin is not authorized to write
to: queue://TEST.FOO*
at
org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:52)
at
org.apache.activemq.ActiveMQConnection.syncSendPacket(ActiveMQConnection.java:1405)
at
org.apache.activemq.ActiveMQSession.syncSendPacket(ActiveMQSession.java:1925)
at
org.apache.activemq.ActiveMQMessageProducer.<init>(ActiveMQMessageProducer.java:125)
at
org.apache.activemq.ActiveMQSession.createProducer(ActiveMQSession.java:969)
at
org.gvr.keystore.client.BrokerUserMgtClient.brokerProducer(BrokerUserMgtClient.java:102)
at
org.gvr.keystore.client.BrokerUserMgtClient.main(BrokerUserMgtClient.java:24)
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 com.intellij.rt.execution.application.AppMain.main(AppMain.java:120)
Caused by: java.lang.SecurityException: User amqadmin is not authorized to
write to: queue://TEST.FOO
at
org.apache.activemq.security.AuthorizationBroker.addProducer(AuthorizationBroker.java:179)
at
org.apache.activemq.broker.MutableBrokerFilter.addProducer(MutableBrokerFilter.java:107)
at
org.apache.activemq.broker.TransportConnection.processAddProducer(TransportConnection.java:534)
at org.apache.activemq.command.ProducerInfo.visit(ProducerInfo.java:105)
at
org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:292)
at
org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:149)
at
org.apache.activemq.transport.MutexTransport.onCommand(MutexTransport.java:50)
at
org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:113)
at
org.apache.activemq.transport.AbstractInactivityMonitor.onCommand(AbstractInactivityMonitor.java:270)
at
org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:83)
at
org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:214)
at
org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:196)
at java.lang.Thread.run(Thread.java:662)
At the beginning I got this issue for ActiveMQ Advisory topics but then I
turned them off.
Without Authorization I noticed that the Authentication part does work
properly when I removed the authorization config from the activemq.xml.
Given below are my configurations for Authentication and Authorization.
Authentication config at [ACTIVEMQ_HOME]/conf/login.config
I am new to working with ActiveMQ and I have a requirement to connect
ActiveMQ (version 5.9.0) with OpenLDAP for authentication and authorization.
I have started doing this and currently stuck with an issue for few days.
Given below is the error I see when running my Java Client.
javax.jms.JMSSecurityException: *User amqadmin is not authorized to write
to: queue://TEST.FOO*
at
org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:52)
at
org.apache.activemq.ActiveMQConnection.syncSendPacket(ActiveMQConnection.java:1405)
at
org.apache.activemq.ActiveMQSession.syncSendPacket(ActiveMQSession.java:1925)
at
org.apache.activemq.ActiveMQMessageProducer.<init>(ActiveMQMessageProducer.java:125)
at
org.apache.activemq.ActiveMQSession.createProducer(ActiveMQSession.java:969)
at
org.gvr.keystore.client.BrokerUserMgtClient.brokerProducer(BrokerUserMgtClient.java:102)
at
org.gvr.keystore.client.BrokerUserMgtClient.main(BrokerUserMgtClient.java:24)
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 com.intellij.rt.execution.application.AppMain.main(AppMain.java:120)
Caused by: java.lang.SecurityException: User amqadmin is not authorized to
write to: queue://TEST.FOO
at
org.apache.activemq.security.AuthorizationBroker.addProducer(AuthorizationBroker.java:179)
at
org.apache.activemq.broker.MutableBrokerFilter.addProducer(MutableBrokerFilter.java:107)
at
org.apache.activemq.broker.TransportConnection.processAddProducer(TransportConnection.java:534)
at org.apache.activemq.command.ProducerInfo.visit(ProducerInfo.java:105)
at
org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:292)
at
org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:149)
at
org.apache.activemq.transport.MutexTransport.onCommand(MutexTransport.java:50)
at
org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:113)
at
org.apache.activemq.transport.AbstractInactivityMonitor.onCommand(AbstractInactivityMonitor.java:270)
at
org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:83)
at
org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:214)
at
org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:196)
at java.lang.Thread.run(Thread.java:662)
At the beginning I got this issue for ActiveMQ Advisory topics but then I
turned them off.
Without Authorization I noticed that the Authentication part does work
properly when I removed the authorization config from the activemq.xml.
Given below are my configurations for Authentication and Authorization.
Authentication config at [ACTIVEMQ_HOME]/conf/login.config