CA certificate in Java keystore

It may be necessary to load a certificate into the Java keystore (cacerts) of the JVM used by the Relution server and make it trusted. This is necessary, for example, when the Relution server establishes a TLS connection to an internal service whose certificate was issued by an internal CA.


Instructions

  1. The Windows command line is opened with administrative privileges.

  2. The current directory is changed to %JAVA_HOME%\lib\security.
    The path may vary depending on the Java version and provider.

  3. The following command is executed in the CMD (in the example, the certificate is located under C:\temp\mdeCert.cer):

    keytool -import -trustcacerts -alias mdecert -file C:\temp\mdeCert.cer -keystore cacerts
    
  4. If a password is requested, changeit is entered. This is the default password of the keystore.

  5. When asked whether the certificate should be trusted, yes is entered.
    The certificate is imported and a message with the content Certificate was added to keystore should appear.

  6. The Relution service is then restarted. The Java keystore is only read at startup; the imported certificate is used only after the restart.

Top