首页 技术 正文
技术 2022年11月15日
0 收藏 346 点赞 4,983 浏览 2087 个字

How to configure security of ActiveMQ ?

Terms

{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.

 <plugins>
<jaasAuthenticationPlugin xmlns="http://activemq.apache.org/schema/core" configuration="activemq-domain"/>
</plugins>

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
org.apache.activemq.jaas.properties.user="users.properties"
org.apache.activemq.jaas.properties.group="groups.properties";
};

Add user

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

mqadmin=password
mquser=password

Add user group

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

admins=mqadmin
users=mquser

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.

<transportConnectors>
<!-- DOS protection, limit concurrent connections to 1000 and frame size to 100MB -->
<transportConnector name="openwire" uri="tcp://0.0.0.0:61616?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/>
<transportConnector name="amqp" uri="amqp://0.0.0.0:5672?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/>
<transportConnector name="stomp" uri="stomp://0.0.0.0:61613?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/>
<transportConnector name="mqtt" uri="mqtt://0.0.0.0:1883?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/>
<transportConnector name="ws" uri="ws://0.0.0.0:61614?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/>
</transportConnectors>

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\jetty-ream.properties. By the format, username: password [,rolename …]

mqadmin: xckj_mqadmin, admin
mquser: xckj_mquser, user
相关推荐
python开发_常用的python模块及安装方法
adodb:我们领导推荐的数据库连接组件bsddb3:BerkeleyDB的连接组件Cheetah-1.0:我比较喜欢这个版本的cheeta…
日期:2022-11-24 点赞:878 阅读:8,997
Educational Codeforces Round 11 C. Hard Process 二分
C. Hard Process题目连接:http://www.codeforces.com/contest/660/problem/CDes…
日期:2022-11-24 点赞:807 阅读:5,511
下载Ubuntn 17.04 内核源代码
zengkefu@server1:/usr/src$ uname -aLinux server1 4.10.0-19-generic #21…
日期:2022-11-24 点赞:569 阅读:6,356
可用Active Desktop Calendar V7.86 注册码序列号
可用Active Desktop Calendar V7.86 注册码序列号Name: www.greendown.cn Code: &nb…
日期:2022-11-24 点赞:733 阅读:6,139
Android调用系统相机、自定义相机、处理大图片
Android调用系统相机和自定义相机实例本博文主要是介绍了android上使用相机进行拍照并显示的两种方式,并且由于涉及到要把拍到的照片显…
日期:2022-11-24 点赞:512 阅读:7,770
Struts的使用
一、Struts2的获取  Struts的官方网站为:http://struts.apache.org/  下载完Struts2的jar包,…
日期:2022-11-24 点赞:671 阅读:4,848