Using Encrypted Property Placeholders for ActiveMQ SSL passwords in "etc/activemq.xml" file

Solution Verified - Updated -

Issue

When activating ActiveMQ features in JBoss Fuse, the default etc/activemq.xml file is used as configuration.

In order to activate SSL, some configuration needs to be applied on the file, mainly to define the keystore and truststore ActiveMQ will use.

Here is an example of the configuration:

<broker xmlns="http://activemq.apache.org/schema/core" brokerName="${broker-name}" dataDirectory="${data}" start="false" useJmx="true">
...
<sslContext>
    <sslContext keyStore="wherever.jks" keyStorePassword="changeit" trustStore="wherever.jks" trustStorePassword="changeit" />
</sslContext>
...
</broker>

As you can see, the password to the keystore and truststore have to be written in clear in the file.

Is there a way to encrypt these passwords so they do not appear in clear text in the file? Something like in etc/users.properties maybe?

Environment

  • Fuse ESB Enterprise 7.1
  • Fuse MQ Enterprise 7.1
  • Red Hat JBoss A-MQ 6.0
  • Red Hat JBoss Fuse 6.0
  • Red Hat JBoss A-MQ 6.1
  • Red Hat JBoss Fuse 6.1

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.