Back up your SSL certificate: Tomcat

We recommended you backup your certificate and its corresponding private key in the event that there is a hardware failure or other disaster affecting your Server, the following instructions will show you how. These instructions will also help you export your certificate from one web server and import the certificate and its private key to another web server.

  • Step 1 of 2

    Running Apache Tomcat over SSL, add the storeFile.p12 to the store by executing the following commands:

    keytool -import

    -alias alias-like-tomcat

    -keystore storeFile.p12

  • Step 2 of 2

    Update the server.xml configuration file to something like this:

    <Connector port="8443" maxThreads="150" minSpareThreads="25" maxSpareThreads="75"

    enableLookups="false" disableUploadTimeout="true"

    acceptCount="100" debug="0" scheme="https" secure="true"

    clientAuth="false" sslProtocol="TLS">

    <Factory className="org.apache.coyote.tomcat5.CoyoteServerSocketFactory"

    clientAuth="false" protocol="TLS"

    keystoreType="PKCS12" keystoreFile="mykeystore.p12" keystorePass=yourKeystorePass />