Enable SSL in JBOSS
1) Create a keystore using keytool utility
#keytool can be found from Java runtime - /opt/jre1.6.0_18/bin/keytool
# Enter values as required
mkdir $JBOSS_HOME/ssl
cd $JBOSS_HOME/ssl
$ keytool -genkey -alias jboss -keyalg RSA -keystore jboss.keystore -validity 3650
Enter keystore password:
Re-enter new password:
What is your first and last name?
[Unknown]:
What is the name of your organizational unit?
[Unknown]:
What is the name of your organization?
[Unknown]:
What is the name of your City or Locality?
[Unknown]:
What is the name of your State or Province?
[Unknown]:
What is the two-letter country code for this unit?
[Unknown]: US
Is valuescorrect?
[no]: yes
Enter key password for
(RETURN if same as keystore password):
Re-enter new password:
A .keystore file will be created in the current directory.
2) Update /opt/jboss-eap-5.0/jboss-as/server/default/deploy/jbossweb.sar/server.xml with correct keystore values.
<Connector protocol="HTTP/1.1" SSLEnabled="true"
port="8443" address="${jboss.bind.address}"
scheme="https" secure="true" clientAuth="false"
keystoreFile="${jboss.server.home.dir}/conf/jboss.keystore"
keystorePass="{your-password}" sslProtocol = "TLS" />
3) Restart the server. Test using https://{ip_address}:8443/context-root/filename.jsp
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home