How to configure security of ActiveMQ ?



{activemq.home}: The ActiveMQ installation folder.

How to configure ActiveMQ to use JAAS Authentication?

Enable Jaas Authentication Plugin

Add below configuration into {activemq.home}\conf\activemq.xml, under /beans/broker node.

Please ignore this step, if already there.

			 <jaasAuthenticationPlugin xmlns="" configuration="activemq-domain"/>


Configure activemq-domin

Configure the login required in {activemq.home}\conf\login.config file, please pay attention the domain name should match with the name in the activemq.xml file.

activemq-domain {
    org.apache.activemq.jaas.PropertiesLoginModule required"""";


Add user

Configure the user and password in {activemq.home}\conf\



Add user group

Configure the user group in {activemq.home}\conf\


Reboot ActiveMQ

Reboot the ActiveMQ server.


How to change the default port of ActiveMQ?

Configure the ActiveMQ ports

Go to the element of /beans/broker/transportConnectors, update the ports of below.

	<!-- DOS protection, limit concurrent connections to 1000 and frame size to 100MB -->
	<transportConnector name="openwire" uri="tcp://;wireFormat.maxFrameSize=104857600"/>
	<transportConnector name="amqp" uri="amqp://;wireFormat.maxFrameSize=104857600"/>
	<transportConnector name="stomp" uri="stomp://;wireFormat.maxFrameSize=104857600"/>
	<transportConnector name="mqtt" uri="mqtt://;wireFormat.maxFrameSize=104857600"/>
	<transportConnector name="ws" uri="ws://;wireFormat.maxFrameSize=104857600"/>


How to change the username / password of ActiveMQ Admin Console?

Configure the user name and password

Update the user name , password and roles information in {activemq.home}\conf\ By the format, username: password [,rolename ...]

mqadmin: xckj_mqadmin, admin
mquser: xckj_mquser, user
posted @ 2016-05-28 13:01  bruceHuang  阅读(273)  评论(0编辑  收藏  举报