To configure SSL on JBoss Application Server, you need an SSL credential for authentication. You can use the Java keytool to create a credential or request and import a credential from a certificate authority (CA). You must then enable SSL on JBoss.
You can run keytool by using a single command that includes all of the information needed to create the keystore.
In this procedure:
[appserver root]
is the home directory of the application server running AEM forms.[type]
is a folder name that varies, depending on the type of install you performed.In a command prompt, navigate to [JAVA HOME]/bin and type the following command to create the credential and keystore:
keytool -genkey -dname "CN=
Host Name , OU=
Group Name , O=
Company Name ,L=
City Name , S=
State , C=
Country Code" -alias "AEMForms Cert"
-keyalg RSA -keypass
key_password -keystore
keystorename .keystore
Replace [JAVA_HOME]
with the directory where the JDK is installed, and replace the text in italic with values that correspond with your environment. Host Name is the fully qualified domain name of the application server.
Enter the keystore_password
when prompted for a password. The password for the keystore and the key must be identical.
The keystore_password
ntered at this step may be the same password (key_password) that you entered in step 1, or it may be different.
Copy the keystorename.keystore to the [appserver root]/server/[type]/conf
directory by typing one of the following commands:
copy
keystorename.keystore[appserver root]\standalone\configuration
keystorename.keystore[appserver root]\domain\configuration
cp keystorename.keystore [appserver root]/standalone/configuration
cp <em>keystorename</em>.keystore<em>[appserver root]</em>/domain/configuration
Export the certificate file by typing the following command:
keytool -export -alias "AEMForms Cert" -file AEMForms_cert.cer -keystore [appserver root]/standalone/configuration/keystorename.keystore
keytool -export -alias "AEMForms Cert" -file AEMForms_cert.cer -keystore [appserver root]/domain/configuration/keystorename.keystore
Enter the keystore_password when prompted for a password.
Copy the AEMForms_cert.cer file to the [appserver root] \conf directory by typing the following command:
copy AEMForms_cert.cer [appserver root]\standalone\configuration
copy AEMForms_cert.cer [appserver root]\domain\configuration
cp AEMForms _cert.cer [appserver root]\standalone\configuration
cp AEMForms _cert.cer [appserver root]\domain\configuration
View the contents of the certificate by typing the following command:
keytool -printcert -v -file [appserver root]\standalone\configuration\AEMForms_cert.cer
keytool -printcert -v -file [appserver root]\domain\configuration\AEMForms_cert.cer
To provide write access to the cacerts file in [JAVA_HOME]\jre\lib\security
, if required, perform the following task:
chmod 777 cacerts
Import the certificate by typing the following command:
keytool -import -alias "AEMForms Cert" -file
AEMForms_cert .cer -keystore
JAVA_HOME \jre\lib\security\cacerts
Type changeit
as the password. This password is the default password for a Java installation and may have been changed by the system administrator.
When prompted for Trust this certificate? [no]
:, type yes
. The confirmation “Certificate was added to keystore” is displayed.
If you are connecting over SSL from Workbench, install the certificate on the Workbench computer.
In a text editor, open the following files for editing:
Single Server - [appserver root]
/standalone/configuration/lc_<dbname/turnkey>.xml
Server Cluster - [appserver root]
/domain/configuration/host.xml
Server Cluster - [appserver root]
/domain/configuration/domain_<dbname>.xml
<security-realm name="SSLRealm">
<server-identities>
<ssl>
<keystore path="C:/Adobe/Adobe_Experience_Manager_Forms/jboss/standalone/configuration/aemformses.keystore" keystore-password="changeit" alias="AEMformsCert" key-password="changeit"/>
</ssl>
</server-identities>
</security-realm>
Locate the <server>
section present after the following code:
<http-listener name="default" socket-binding="http" redirect-socket="https" max-post-size="104857600"/>
Add the following to the <server> section present after above code:
<https-listener name="default-secure" socket-binding="https" security-realm="SSLRealm"/>
<security-realm name="SSLRealm">
<server-identities>
<ssl>
<keystore path="C:/Adobe/Adobe_Experience_Manager_Forms/jboss/standalone/configuration/aemformses.keystore" keystore-password="changeit" alias="AEMForms Cert" key-password="changeit"/>
</ssl>
</server-identities>
</security-realm>
On the primary node of the Server Cluster, in the [appserver root]\domain\configuration\domain_<dbname>.xml, locate the <server> section present after the following code:
<http-listener name="default" socket-binding="http" redirect-socket="https" max-post-size="104857600"/>
Add the following to the <server> section present after above code:
<https-listener name="default-secure" socket-binding="https" security-realm="SSLRealm"/>
Change the value for the keystoreFile
attribute and the keystorePass
attribute to the keystore password that you specified when you created the keystore.
Restart the application server:
For turnkey installations:
For Adobe preconfigured or manually configured JBoss installations:
From a command prompt, navigate to [appserver root]
/bin.
Stop the server by entering the following command:
shutdown.bat -S
./shutdown.sh -S
Wait until the JBoss process has fully shut down (when the JBoss process returns control to the terminal it was started in).
Start the server by entering the following command:
run.bat -c <profile>
./run.sh -c <profile>
To access administration console using SSL, type https://[host name]:'port'/adminui
in a web browser:
The default SSL port for JBoss is 8443. From here on, specify this port when accessing AEM forms.
In a command prompt, navigate to [JAVA HOME]/bin and type the following command to create the keystore and the key:
keytool -genkey -dname "CN=
Host Name , OU=
Group Name , O=
Company Name , L=
City Name , S=
State , C=
Country Code" -alias "AEMForms Cert"
-keyalg RSA -keypass
-key_password -keystore
keystorename .keystore
Replace [JAVA_HOME]
with the directory where the JDK is installed, and replace the text in italic with values that correspond with your environment.
Type the following command to generate a certificate request to send to the certificate authority:
keytool -certreq -alias
“AEMForms Cert” -keystore
keystorename .keystore -file
AEMFormscertRequest.csr
When your request for a certificate file is fulfilled, complete the next procedure.
In a command prompt, navigate to [JAVA HOME]
/bin and type the following command to import the root certificate of the CA with which the CSR has been signed:
keytool -import -trustcacerts -file
rootcert.pem -keystore keystorename.keystore -alias root
If the root certificate is not in the browser, also import it there.
Replace [JAVA_HOME]
with the directory where the JDK is installed, and replace the text in italic with values that correspond with your environment.
In a command prompt, navigate to [JAVA HOME]
/bin and type the following command to import the credential into the keystore:
keytool -import -trustcacerts -file
CACertificateName .crt -keystore
keystorename .keystore
[JAVA_HOME]
with the directory where the JDK is installed, and replace the text in italic with values that correspond with your environment.Complete steps 13 - 18 of Create an SSL credential.