[ 
https://issues.apache.org/jira/browse/ARTEMIS-984?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15878861#comment-15878861
 ] 

Justin Bertram commented on ARTEMIS-984:
----------------------------------------

Can you attach your full broker.xml and client code?

> i don't succeed in connecting with a new user to my broker 
> -----------------------------------------------------------
>
>                 Key: ARTEMIS-984
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-984
>             Project: ActiveMQ Artemis
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 1.5.2
>            Reporter: REGINA Patrick
>            Priority: Trivial
>
> i'm using the {{org.fusesource.mqtt.client}} and i try to connect to my 
> broker with the user i just created. But it doesn't work.
> i used the  command below to create a user with the role Commerce :
> {noformat}
> ./artemis user add
> {noformat}
> Then in my broker file i have :
> {code:xml}
>          <security-setting match="digital.paas.expertise.data">
>             <permission type="createNonDurableQueue" roles="Commerce"/>
>             <permission type="deleteNonDurableQueue" roles="Commerce"/>
>             <permission type="createDurableQueue" roles="Commerce"/>
>             <permission type="deleteDurableQueue" roles="Commerce"/>
>             <permission type="consume" roles="Commerce"/>
>             <permission type="browse" roles="Commerce"/>
>             <permission type="send" roles="Commerce"/>
>             <!-- we need this otherwise ./artemis data imp wouldn't work -->
>             <permission type="manage" roles="Commerce"/>
>          </security-setting>
> {code}
> Then i tried to connect :
> {code:java}
>       System.out.println("Connecting to Artemis using MQTT");
>       MQTT mqtt = new MQTT();
>       
>        mqtt.setUserName("CommerceUser");
>       mqtt.setPassword("password");
>       
>       
>       mqtt.setHost("ssl://myServer:1883");
>     
>       BlockingConnection connection = mqtt.blockingConnection();
>       connection.connect();      
>       System.out.println("Connected to Artemis");
> {code}
> but the code is block to  connection.connect();     .
> if i change the user wiht the original user created with the broker it works 
> fine.
> Ca you help me  ?
> in my artemis-user.properties :
> {noformat}
> Administrator = 
> ENC(1024:02D41AC74166D1184F86ECD12EDA1AD999D6EDC46C4EE18D424C9C825F23777F:F4A471DCA21FE41E52BC48EC28235E2BF3BAA645757061B440C272426E8A34C57366837441FBF93D419BF343F055944DBA613580BFF7AEBC7A237A1D95933291)
> CommerceDN = 
> ENC(1024:7DB89C83F5E1A21E0461C8F9A46FF4619F72F3DF526EE4D0B3BBD53594F7AEC8:29D876E9BA466BBFA26D8CFC25E4AF06E4D1F5B31D16C59A8A176F594D7A9E3FE3D9BC022BA1DA9F248CC30FC9D58E16A17BDC7B46B9969FD77E05290BA1F4F7)
> {noformat}
> in my artemis-roles.properties:
> {noformat}
> digital = Administrator
> Commerce = CommerceDN
> {noformat}
> in my login.config :
> {noformat}
> activemq {
>    org.apache.activemq.artemis.spi.core.security.jaas.PropertiesLoginModule 
> required
>        debug=false
>        org.apache.activemq.jaas.properties.user="artemis-users.properties"
>        org.apache.activemq.jaas.properties.role="artemis-roles.properties";
> };
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to