...
- Create the Java Keystore using the Keytools from your Java JRE.
- Generate the Java Truststore
- You can use the Java Keystore that will be created with the private key
- for
- the HTTPS support in Jetty. Please note that probably you have to create the directory
JETTY_BASE/etc
Example
Code Block title Sample for generate Keystore with private key and certificate keytool -genkey -alias "joc" -dname "CN=jocHost,O=myCompany" -validity 1461 -keyalg RSA -keysize 1024 -keypass secret_key -keystore "JETTY_BASE/etc/joc.jks" -storepass secret_store
Explanations
- Replace the
JETTY_BASE
placeholder as specified above. - The
-dname
option specifies the certificate issuer, therefore use your own set of CN, OU, DC that specify the issuer's distinguished name. The O setting is required for the issuer. - The
-keypass
option accepts the password that you will need later on to manage your private key. - The
-keystore
option specifies the location of your Keystore file. - The
-storepass
option specifies the password for access to your Keystore file.
- Replace the
- Generate the Java Truststore
...