Import private key and certificate into Java Key Store (JKS)
Apache Tomcat and many other Java applications expect to retrieve SSL/TLS certificates from a Java Key Store (JKS). Jave Virtual Machines usually come with keytool to help you create a new key store.
Keytool helps you to:
* create a new JKS with a new private key
* generate a Certificate Signung Request (CSR) for the private key in this JKS
* import a certificate that you received for this CSR into your JKS
Keytool does not let you import an existing private key for which you already have a certificate. So you need to do this yourself, here's how:
Let's assume you have a private key (key.pem) and a certificate (cert.pem
Javology.