Chapter 5. Basic Configuration Changes
5.1. Security Configuration リンクのコピーリンクがクリップボードにコピーされました!
Important
Important
5.1.1. Security Configuration: JMX Console, Admin Console, HttpInvoker リンクのコピーリンクがクリップボードにコピーされました!
Procedure 5.1. Create jmx-console, admin-console, and http invoker user account
Create a user in the default JAAS security domain
- Edit the file
$JBOSS_HOME/server/$PROFILE/conf/props/jmx-console-users.properties. - Create a username = password pair.
Important
The commentedadmin=adminusername and password pair is an example of the username/password definition syntax. Do not use this for your user account.
Grant permissions to user
- Edit the file
$JBOSS_HOME/server/$PROFILE/conf/props/jmx-console-roles.properties. - Create an entry for the user of the form:
username=JBossAdmin,HttpInvoker
username=JBossAdmin,HttpInvokerCopy to Clipboard Copied! Toggle word wrap Toggle overflow - JBossAdmin
- Grant the user permission to access the JMX Console and Admin Console.
- HttpInvoker
- Grant the user permission to access the httpinvoker
5.1.2. Securing the HTTPInvoker リンクのコピーリンクがクリップボードにコピーされました!
Procedure 5.2. Secure the HTTP Invoker
- Edit the
<JBOSS_HOME>/server/<PROFILE>/conf/bindingservice.beans/META-INF/bindings-jboss-beans.xmlfile. - Add the
hostNameandfixedHostNameproperties to the deploy/legacy-invokers-service.xml section:Copy to Clipboard Copied! Toggle word wrap Toggle overflow
5.1.3. Security Configuration: Web Console リンクのコピーリンクがクリップボードにコピーされました!
Procedure 5.3. Creating Web Console User Account
Create a user in the web-console JAAS security domain.
- Edit the file
web-console-users.propertiesinjboss-as/server/$PROFILE/deploy/management/console-mgr.sar/web-console.war/WEB-INF/classes/. - Create a username = password pair.
Important
The commentedadmin=adminusername and password is an example of the username/password definition syntax. Do not use this for your user account.
Grant permissions to the user.
- Edit the file
web-console-roles.propertiesinjboss-as/server/$PROFILE/deploy/management/console-mgr.sar/web-console.war/WEB-INF/classes/. - Create an entry for the user of the form:
username=JBossAdmin,HttpInvoker
username=JBossAdmin,HttpInvokerCopy to Clipboard Copied! Toggle word wrap Toggle overflow - JBossAdmin
- Grant the user permission to access the Web-Console
- HttpInvoker
- Grant the user permission to access the HTTP Invoker
5.1.4. Security Configuration of JBoss Messaging リンクのコピーリンクがクリップボードにコピーされました!
suckerPassword in the messaging and server configuration files.
jboss-as/server/$PROFILE/deploy/messaging/messaging-jboss-beans.xml file and the messaging-service.xml file. These files contain directives that specify the encrypted suckerPassword.
Changing the Password in messaging-jboss-beans.xml
messaging-jboss-beans.xml.
Procedure 5.4. Setting suckerPassword for JBoss Messaging
- Navigate to the
<JBOSS_HOME>/server/<PROFILE>/deploy/messaging/directory. - Open the
messaging-jboss-beans.xmlfile in your preferred text editor. - Change the
suckerPasswordplaceholder value from"CHANGE ME!!"to a plain text password:<property name="suckerPassword">CHANGE ME!!</property>
<property name="suckerPassword">CHANGE ME!!</property>Copy to Clipboard Copied! Toggle word wrap Toggle overflow Make note of the new password; it will be used in the next task. - Save the file.
Creating the encrypted JBoss Messaging suckerPassword
- In a terminal, change to
<JBOSS_HOME>/server/<PROFILE>/deploy/messaging/. - Run the following command:
/path/to/java/executable -cp JBOSS_HOME/client/jboss-messaging-client.jar org.jboss.messaging.util.SecurityUtil PLAIN_TEXT_PASSWORD
/path/to/java/executable -cp JBOSS_HOME/client/jboss-messaging-client.jar org.jboss.messaging.util.SecurityUtil PLAIN_TEXT_PASSWORDCopy to Clipboard Copied! Toggle word wrap Toggle overflow - PLAIN_TEXT_PASSWORD is the password you set in
messaging-jboss-beans.xmlin the previous task.As an example:Example 5.1. Test Encrypted Password
Running the following command (from theJBOSS_HOME/jboss-as/server/$PROFILE/deploy/messaging/directory) .../usr/bin/java -cp ../../../../client/jboss-messaging-client.jar org.jboss.messaging.util.SecurityUtil test
/usr/bin/java -cp ../../../../client/jboss-messaging-client.jar org.jboss.messaging.util.SecurityUtil testCopy to Clipboard Copied! Toggle word wrap Toggle overflow ...produced the following encrypted password:key len: 14 length max: 2147483647 Encoded password: 5e2c1ae5a618317
key len: 14 length max: 2147483647 Encoded password: 5e2c1ae5a618317Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Make note of the encrypted password output; it will be used in the next task.
Specifying an encrypted suckerPassword for JBoss Messaging
Prerequisites
- You have a terminal open at the
<JBOSS_HOME>/server/<PROFILE>/deploy/messaging/directory.
- In a text editor, open the
messaging-service.xmlfile. - Paste the encrypted password from the previous procedure into the
SuckerPasswordattribute:<attribute name="SuckerPassword">ENCRYPTED_PASSWORD</attribute>
<attribute name="SuckerPassword">ENCRYPTED_PASSWORD</attribute>Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Save the
messaging-service.xmlfile.