users@glassfish.java.net

JMS Authentification Problem

From: <glassfish_at_javadesktop.org>
Date: Tue, 08 Jan 2008 08:57:42 PST

Hi there,

I got a problem using Sun App Server 9.1 along with embedded with IMQ. I configured a ConnectionFactory:

<connector-connection-pool associate-with-thread="false"
 connection-creation-retry-attempts="0"
 connection-creation-retry-interval-in-seconds="10"
 connection-definition-name="javax.jms.ConnectionFactory"
 connection-leak-reclaim="false" connection-leak-timeout-in-seconds="0"
 fail-all-connections="false" idle-timeout-in-seconds="300"
 is-connection-validation-required="true" lazy-connection-association="false"
 lazy-connection-enlistment="false" match-connections="true"
 max-connection-usage-count="0" max-pool-size="32" max-wait-time-in-millis="60000"
 name="jms/CoreConnectionFactory" pool-resize-quantity="2"
 resource-adapter-name="jmsra" steady-pool-size="8"
 validate-atmost-once-period-in-seconds="0">
      <property name="Password" value="cps"/>
      <property name="UserName" value="cps"/>
</connector-connection-pool>

and also created the user cps with password cps (with imqusermgr). If I try the use the CF or deploy a MDB using it, I get the following exception:

[#|2008-01-08T17:20:47.296+0100|SEVERE|sun-appserver9.1|javax.enterprise.system.core.classloading|_ThreadID=10;_ThreadName=main;_RequestID=e9e5b3e4-145d-45e7-8a37-27d0032a6eaf;|LDR5004: UnExpected error occured while creating ejb container
java.lang.Exception
        at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:261)
        at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:209)
        at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:524)
        at com.sun.enterprise.server.AbstractLoader.loadEjbs(AbstractLoader.java:536)
        at com.sun.enterprise.server.ApplicationLoader.doLoad(ApplicationLoader.java:188)
        at com.sun.enterprise.server.TomcatApplicationLoader.doLoad(TomcatApplicationLoader.java:126)
        at com.sun.enterprise.server.AbstractLoader.load(AbstractLoader.java:244)
        at com.sun.enterprise.server.AbstractManager.load(AbstractManager.java:225)
        at com.sun.enterprise.server.ApplicationLifecycle.onStartup(ApplicationLifecycle.java:217)
        at com.sun.enterprise.server.ApplicationServer.onStartup(ApplicationServer.java:442)
        at com.sun.enterprise.server.ondemand.OnDemandServer.onStartup(OnDemandServer.java:120)
        at com.sun.enterprise.server.PEMain.run(PEMain.java:411)
        at com.sun.enterprise.server.PEMain.main(PEMain.java:338)
        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.sun.enterprise.server.PELaunch.main(PELaunch.java:412)
        at scireum.tools.ASLauncher.main(ASLauncher.java:12)
Caused by: java.lang.SecurityException: Authentication failed for username guest in service jmsdirect: com.sun.messaging.jmq.auth.api.FailedLoginException: [B4051]: Forbidden guest
        at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.createDirectConnection(IMQDirectService.java:344)
        at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.createConnection(IMQDirectService.java:419)
        at com.sun.messaging.jms.ra.DirectConnectionFactory._createConnectionId(DirectConnectionFactory.java:424)
        at com.sun.messaging.jms.ra.DirectConnectionFactory._createConnection(DirectConnectionFactory.java:547)
        at com.sun.messaging.jms.ra.EndpointConsumer.createDirectMessageConsumer(EndpointConsumer.java:935)
        at com.sun.messaging.jms.ra.EndpointConsumer._init(EndpointConsumer.java:305)
        at com.sun.messaging.jms.ra.EndpointConsumer.<init>(EndpointConsumer.java:215)
        at com.sun.messaging.jms.ra.ResourceAdapter.endpointActivation(ResourceAdapter.java:604)
        at com.sun.enterprise.connectors.inflow.ConnectorMessageBeanClient.setup(ConnectorMessageBeanClient.java:252)
        ... 18 more
|#]

Note: seems like somehow still guest is used as user (I deleted this account from imq). Can anybody help, and tell me why my supplied username and password is ignored?

(I always use createConnection() w/o parameters and use no deplyment descriptor (-> CF res-auth=CONTAINER))

thanx
Andy
[Message sent by forum member 'ahaufler' (ahaufler)]

http://forums.java.net/jive/thread.jspa?messageID=252756