keytool utility will be used to list the TLS certificate, confirming that the private key and certificate were successfully imported into the keystore.
These steps ensure that Apache Tomcat is configured to use the HSM-backed server certificate for TLS, allowing clients to verify the server during HTTPS connections.
Perform the following tasks to create a server certificate and key pair:
- Create a new X.509 certificate container.
- Generate a new key pair for the Apache Tomcat TLS Server certificate.
- Create an approval group for the TLS server certificate.
- Add an issuance policy to the TLS server certificate.
Create a certificate container
Perform the following steps to create a new X.509 certificate container:Select [ Add CA ] at the bottom of the page or right-click anywhere in the window and select Add CA.
In the pop-up menu, specify the following information for the Certificate Container:
- Name: Enter Apache Tomcat.
- Host: Select None.
- Type: Select X.509.
- Owner group: In the drop-down menu, select the role automatically created for the Apache Tomcat service you deployed.
Generate a key pair
Perform the following steps to generate a new key pair for the Apache Tomcat TLS server:Right-click the X.509 certificate container you created and select Add Certificate > New Certificate.
In the Subject DN tab of the certificate creation wizard, select the Classic Preset in the drop-down menu and specify
futurex-tomcat as the Common Name for the certificate.In the Basic Info tab, select the Type as
ECC, select the Curve as Prime 256 (or higher), and select Anonymous Signing for Security Usage.Create an approval group
Perform the following steps to create an approval group for PKI signing:Select [ Add Approval Group ] at the bottom of the page or right-click anywhere in the window and select Add Approval Group.
In the first drop-down list, select the role automatically created for the Apache Tomcat service you deployed, and select [ Add ].
Add an issuance policy
Perform the following steps to add an issuance policy to the Android APK Signing client certificate:In the Basic Info tab, configure the following settings:
- Approvals: Select 0.
- Allowed hashes: Select SHA-256, SHA-384, SHA-512, and SHA-224.
Verifying the Private Key and Certificate in the Java Keystore
The
keytool application is included in the JDK installation, so you can run the keytool command in this section with no additional configuration.Shell
<CRYPTO-OPR-PASS> tag in the fxpkcs11.cfg file.
If the command succeeds, you should see an output similar to the following:Important: Take note of the title (in this example,
None
Apache Tomcat:futurex-tomcat:C) of the entry as that will be needed for the server.xml file in the next section.
