0 Replies Latest reply on Jun 6, 2012 6:11 AM by ashman

    HornetQ configuring with applicaiton server security model

    ashman Newbie

      Hi everyone,

       

      I was trying to integrate the HornetMQ client login  with the security model in JBoss AS7. Ihave seen several articles on this, most of which point to setting allowClientLogin to true. But I don't understand where I must do this. I can't find a /hornetq-jboss-beans.xml file anywhere (as suggested in some articles). I would have thought the setting would have to be made in standalone.xml, where I have defined the factory, queues and the security. I am currently connecting by using a username/password/role combination defined in application-roles.properties and application-users.properties files, but I would like to avoid having to use this.

       

      I currently have the following settings in the standalone.xml:

       

       

      <subsystem xmlns="urn:jboss:domain:messaging:1.1">

      <hornetq-server>

       

      <journal-file-size>102400</journal-file-size>

      <journal-min-files>2</journal-min-files>

       

       

      <connectors>

                          <netty-connector name="netty" socket-binding="messaging"/>

                          <netty-connector name="netty-throughput" socket-binding="messaging-throughput">

                              <param key="batch-delay" value="50"/>

                          </netty-connector>

                          <in-vm-connector name="in-vm" server-id="0"/>

      </connectors>

      <acceptors>

                          <netty-acceptor name="netty" socket-binding="messaging"/>

                          <netty-acceptor name="netty-throughput" socket-binding="messaging-throughput">

                              <param key="batch-delay" value="50"/>

                              <param key="direct-deliver" value="false"/>

                          </netty-acceptor>

                          <in-vm-acceptor name="in-vm" server-id="0"/>

      </acceptors>

      <security-settings>

                          <security-setting match="#">

                              <permission type="send" roles="guest"/>

                              <permission type="consume" roles="guest"/>

                              <permission type="createNonDurableQueue" roles="guest"/>

                              <permission type="deleteNonDurableQueue" roles="guest"/>

                          </security-setting>

      </security-settings>

      <address-settings>

                          <address-setting match="#">

                              <dead-letter-address>jms.queue.DLQ</dead-letter-address>

                              <expiry-address>jms.queue.ExpiryQueue</expiry-address>

                              <redelivery-delay>0</redelivery-delay>

                              <max-delivery-attempts>3</max-delivery-attempts>

                              <max-size-bytes>10485760</max-size-bytes>

                              <address-full-policy>BLOCK</address-full-policy>

                              <message-counter-history-day-limit>10</message-counter-history-day-limit>

                          </address-setting>

      </address-settings>

      <jms-connection-factories>

                          <connection-factory name="InVmConnectionFactory">

                              <connectors>

                                  <connector-ref connector-name="in-vm"/>

                              </connectors>

                              <entries>

                                  <entry name="java:/ConnectionFactory"/>

                              </entries>

                          </connection-factory>

                          <connection-factory name="RemoteConnectionFactory">

                              <connectors>

                                  <connector-ref connector-name="netty"/>

                              </connectors>

                              <entries>

                                  <entry name="RemoteConnectionFactory"/>

                                  <entry name="java:jboss/exported/jms/RemoteConnectionFactory"/>

                              </entries>

                          </connection-factory>

                          <pooled-connection-factory name="hornetq-ra">

                              <transaction mode="xa"/>

                              <connectors>

                                  <connector-ref connector-name="in-vm"/>

                              </connectors>

                              <entries>

                                  <entry name="java:/JmsXA"/>

                              </entries>

                          </pooled-connection-factory>

      </jms-connection-factories>

      <jms-destinations>

                          <jms-queue name="testQueue">

                              <entry name="queue/test"/>

                              <entry name="java:jboss/exported/jms/queue/test"/>

                          </jms-queue>

      </jms-destinations>

       

       

      </hornetq-server>

      </subsystem>

       

      Any help is appreciated!