Return-Path: Delivered-To: apmail-activemq-users-archive@www.apache.org Received: (qmail 33853 invoked from network); 25 Mar 2008 00:02:59 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 25 Mar 2008 00:02:59 -0000 Received: (qmail 11518 invoked by uid 500); 25 Mar 2008 00:02:56 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 11493 invoked by uid 500); 25 Mar 2008 00:02:56 -0000 Mailing-List: contact users-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@activemq.apache.org Delivered-To: mailing list users@activemq.apache.org Received: (qmail 11483 invoked by uid 99); 25 Mar 2008 00:02:56 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 24 Mar 2008 17:02:56 -0700 X-ASF-Spam-Status: No, hits=2.6 required=10.0 tests=DNS_FROM_OPENWHOIS,SPF_HELO_PASS,SPF_PASS,WHOIS_MYPRIVREG X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of lists@nabble.com designates 216.139.236.158 as permitted sender) Received: from [216.139.236.158] (HELO kuber.nabble.com) (216.139.236.158) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 25 Mar 2008 00:02:15 +0000 Received: from isper.nabble.com ([192.168.236.156]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1JdwcU-0000jz-AV for users@activemq.apache.org; Mon, 24 Mar 2008 17:02:26 -0700 Message-ID: <16265456.post@talk.nabble.com> Date: Mon, 24 Mar 2008 17:02:26 -0700 (PDT) From: navnetkachroo To: users@activemq.apache.org Subject: Re: ActiveMQ 5.0 & JAAS: SecurityException: User name or password is invalid on Startup In-Reply-To: <16263455.post@talk.nabble.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Nabble-From: navnetkachroo@gmail.com References: <16261835.post@talk.nabble.com> <16262352.post@talk.nabble.com> <16262771.post@talk.nabble.com> <16263455.post@talk.nabble.com> X-Virus-Checked: Checked by ClamAV on apache.org The users.properties, login.config, and groups.properties files are in $ACTIVEMQ_HOME/conf/org/apache/activemq/security ... I give this path as an argument while (java.security.auth.login.config) starting ActiveMQ. I tried commenting the simple plugin => It passed through the previous block... But now i'm getting another exception (User system is not authorized to read from... stack trace in the end), even after having this in the xml: Thanks! StackTrace: WARN DiscoveryNetworkConnector - Could not start network bridge between: vm://test-msg-poc-1 and: tcp://test-msg-poc-2:61616 due to: java.net.ConnectException: Connection refused INFO DemandForwardingBridge - test-msg-poc-1 bridge to Unknown stopped ERROR TransportConnector - Could not accept connection : Peer (vm://test-msg-poc-1#4) disposed. ERROR Service - Async error occurred: java.lang.SecurityException: User system is not authorized to read from: ActiveMQ.Advisory.Consumer.>,topic://ActiveMQ.Advisory.TempQueue,topic://ActiveMQ.Advisory.TempTopic java.lang.SecurityException: User system is not authorized to read from: ActiveMQ.Advisory.Consumer.>,topic://ActiveMQ.Advisory.TempQueue,topic://ActiveMQ.Advisory.TempTopic at org.apache.activemq.security.AuthorizationBroker.addConsumer(AuthorizationBroker.java:107) ttmdev wrote: > > Are the files users.properties, login.config, and groups.properties in > $ACTIVEMQ_HOME/conf? > > I noticed that you have both the jaas and simple authentication plugins > enabled in your broker's xml cfg file. Try commenting out the simple > plugin. > > Can you clients connect to the broker? > > Joe > > > navnetkachroo wrote: >> >> Thanks for your reply. >> >> I tried giving the username & pwd... But even that did'nt work :(. I'm >> getting the same exception. >> >> > uri="static://(tcp://test-msg-poc-1:61616)" userName="system" >> password="manager"/> >> >> >> >> ttmdev wrote: >>> >>> Couple of things to keep in mind. >>> >>> a. Any broker wishing to connect to this broker (i.e., the one you've >>> enabled security for) will need to provide the proper credentials via >>> the networkConnector element's userName and password attributes. >>> >>> b. Any networkConnector elements given to this broker must be given the >>> proper credentials even if the corresponding remote broker does not have >>> security enabled. >>> >>> Joe >>> Goto www.ttmsolutions.com for a free ActiveMQ user guide >>> >>> >>> >>> >>> >>> >>> >>> navnetkachroo wrote: >>>> >>>> Hi, >>>> >>>> I configured JAAS & ActiveMQ 5.0. >>>> >>>> On ActiveMQ startup, I get the User name or password is invalid >>>> exception. (stacktrace mentioned in the end of this post). >>>> >>>> I've been through all the related posts & have tried the suggestions, >>>> even then this doesn't work ! >>>> >>>> Attached are the configuration files that I'm using: >>>> * users.properties >>>> * login.config >>>> * groups.properties >>>> * activemq.xml.entitle >>>> >>>> I've also tried removing camelContext, commandAgent & jetty from the >>>> activemq.xml. >>>> >>>> >>>> Stacktrace: >>>> >>>> ACTIVEMQ_HOME: /tech/poc/activemq >>>> ACTIVEMQ_BASE: /tech/poc/activemq >>>> Loading message broker from: xbean:activemq.xml >>>> INFO BrokerService - Using Persistence Adapter: >>>> AMQPersistenceAdapter(${activemq.base}/data/test-msg-poc-2) >>>> INFO BrokerService - ActiveMQ 5.1-SNAPSHOT JMS >>>> Message Broker (test-msg-poc-2) is starting >>>> INFO BrokerService - For help or more information >>>> please see: http://activemq.apache.org/ >>>> INFO AMQPersistenceAdapter - AMQStore starting using >>>> directory: ${activemq.base}/data/test-msg-poc-2 >>>> INFO KahaStore - Kaha Store using data directory >>>> ${activemq.base}/data/test-msg-poc-2/kr-store/state >>>> INFO ManagementContext - JMX consoles can connect to >>>> service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi >>>> INFO AMQPersistenceAdapter - Active data files: [] >>>> WARN AMQPersistenceAdapter - The ReferenceStore is not valid >>>> - recovering ... >>>> INFO KahaStore - Kaha Store successfully deleted >>>> data directory ${activemq.base}/data/test-msg-poc-2/kr-store/data >>>> INFO AMQPersistenceAdapter - Journal Recovery Started from: >>>> DataManager:(data-) >>>> INFO AMQPersistenceAdapter - Recovered 0 operations from redo >>>> log in 0.018 seconds. >>>> INFO AMQPersistenceAdapter - Finished recovering the >>>> ReferenceStore >>>> INFO KahaStore - Kaha Store using data directory >>>> ${activemq.base}/data/test-msg-poc-2/kr-store/data >>>> INFO TransportServerThreadSupport - Listening for connections at: >>>> tcp://test-msg-poc-2:61616 >>>> INFO TransportConnector - Connector openwire Started >>>> INFO DiscoveryNetworkConnector - Establishing network connection >>>> between from vm://test-msg-poc-2 to tcp://test-msg-poc-1:61616 >>>> INFO TransportConnector - Connector vm://test-msg-poc-2 >>>> Started >>>> INFO NetworkConnector - Network Connector >>>> org.apache.activemq.transport.discovery.simple.SimpleDiscoveryAgent@c44b88 >>>> Started >>>> INFO BrokerService - ActiveMQ JMS Message Broker >>>> (test-msg-poc-2, ID:test-msg-poc-2-41438-1206391453635-0:0) started >>>> INFO DemandForwardingBridge - Network connection between >>>> vm://test-msg-poc-2#0 and >>>> tcp://test-msg-poc-1/134.42.19.30:61616(test-msg-poc-1) has been >>>> established. >>>> WARN TransportConnection - Failed to add Connection >>>> java.lang.SecurityException: User name or password is invalid. >>>> at >>>> org.apache.activemq.security.SimpleAuthenticationBroker.addConnection(SimpleAuthenticationBroker.java:52) >>>> at >>>> org.apache.activemq.broker.BrokerFilter.addConnection(BrokerFilter.java:81) >>>> at >>>> org.apache.activemq.broker.MutableBrokerFilter.addConnection(MutableBrokerFilter.java:91) >>>> at >>>> org.apache.activemq.broker.TransportConnection.processAddConnection(TransportConnection.java:658) >>>> at >>>> org.apache.activemq.command.ConnectionInfo.visit(ConnectionInfo.java:125) >>>> at >>>> org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:281) >>>> at >>>> org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:178) >>>> at >>>> org.apache.activemq.transport.ResponseCorrelator.onCommand(ResponseCorrelator.java:100) >>>> at >>>> org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:68) >>>> at >>>> org.apache.activemq.transport.vm.VMTransport.iterate(VMTransport.java:200) >>>> at >>>> org.apache.activemq.thread.DedicatedTaskRunner.runTask(DedicatedTaskRunner.java:98) >>>> at >>>> org.apache.activemq.thread.DedicatedTaskRunner$1.run(DedicatedTaskRunner.java:36) >>>> ERROR Service - Async error occurred: >>>> java.lang.SecurityException: User name or password is invalid. >>>> java.lang.SecurityException: User name or password is invalid. >>>> at >>>> org.apache.activemq.security.SimpleAuthenticationBroker.addConnection(SimpleAuthenticationBroker.java:52) >>>> at >>>> org.apache.activemq.broker.BrokerFilter.addConnection(BrokerFilter.java:81) >>>> at >>>> org.apache.activemq.broker.MutableBrokerFilter.addConnection(MutableBrokerFilter.java:91) >>>> at >>>> org.apache.activemq.broker.TransportConnection.processAddConnection(TransportConnection.java:658) >>>> at >>>> org.apache.activemq.command.ConnectionInfo.visit(ConnectionInfo.java:125) >>>> at >>>> org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:281) >>>> at >>>> org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:178) >>>> at >>>> org.apache.activemq.transport.ResponseCorrelator.onCommand(ResponseCorrelator.java:100) >>>> at >>>> org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:68) >>>> at >>>> org.apache.activemq.transport.vm.VMTransport.iterate(VMTransport.java:200) >>>> at >>>> org.apache.activemq.thread.DedicatedTaskRunner.runTask(DedicatedTaskRunner.java:98) >>>> at >>>> org.apache.activemq.thread.DedicatedTaskRunner$1.run(DedicatedTaskRunner.java:36) >>>> INFO DemandForwardingBridge - Network connection between >>>> vm://test-msg-poc-2#0 and tcp://test-msg-poc-1/134.42.19.30:61616 >>>> shutdown due to a local error: java.lang.SecurityException: User name >>>> or password is invalid. >>>> WARN TransportConnection - Failed to add Connection >>>> java.lang.SecurityException: User name or password is invalid. >>>> at >>>> org.apache.activemq.security.SimpleAuthenticationBroker.addConnection(SimpleAuthenticationBroker.java:52) >>>> at >>>> org.apache.activemq.broker.BrokerFilter.addConnection(BrokerFilter.java:81) >>>> at >>>> org.apache.activemq.broker.MutableBrokerFilter.addConnection(MutableBrokerFilter.java:91) >>>> at >>>> org.apache.activemq.broker.TransportConnection.processAddConnection(TransportConnection.java:658) >>>> at >>>> org.apache.activemq.broker.jmx.ManagedTransportConnection.processAddConnection(ManagedTransportConnection.java:86) >>>> at >>>> org.apache.activemq.command.ConnectionInfo.visit(ConnectionInfo.java:125) >>>> at >>>> org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:281) >>>> at >>>> org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:178) >>>> at >>>> org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:68) >>>> at >>>> org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:134) >>>> at >>>> org.apache.activemq.transport.InactivityMonitor.onCommand(InactivityMonitor.java:173) >>>> at >>>> org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:84) >>>> at >>>> org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:196) >>>> at >>>> org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:183) >>>> at java.lang.Thread.run(Thread.java:595) .... >>>> ...... >>>> http://www.nabble.com/file/p16261835/users.properties users.properties >>>> http://www.nabble.com/file/p16261835/login.config login.config >>>> http://www.nabble.com/file/p16261835/activemq.xml.entitle >>>> activemq.xml.entitle >>>> http://www.nabble.com/file/p16261835/groups.properties >>>> groups.properties http://www.nabble.com/file/p16261835/login.config >>>> login.config >>>> >>> >>> >> >> > > -- View this message in context: http://www.nabble.com/ActiveMQ-5.0---JAAS%3A-SecurityException%3A-User-name-or-password-is-invalid-on-Startup-tp16261835s2354p16265456.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.