Font Size:
Ask Joget AI

SSLHandshakeException – PKIX Path Building Failed

Introduction

When integrating Joget with external HTTPS endpoints, you may encounter the following error:

ERROR org.joget.marketplace.EnhancedJsonTool - javax.net.ssl.SSLHandshakeException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target Caused by: sun.security.validator.ValidatorException: PKIX path building failed Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

Cause

This error indicates that Joget (your Java application) is trying to establish an HTTPS connection, but Java does not trust the SSL certificate of the target endpoint. To resolve this, you must extract the certificate and import it into the Java truststore.

Solution

You can resolve this issue by following the steps below:

  1. Get the server’s certificate:

    openssl s_client -connect <your_target_host>:443 -showcerts
    Bash
     
  2. Copy the certificate (or the full chain) into a .crt file (e.g., server.crt). Upload it in the /home/joget folder.

  3. Import it into your JDK’s truststore:

    sudo keytool -import -trustcacerts -alias myserver -file server.crt -keystore $JAVA_HOME/lib/security/cacerts -storepass changeit
    Bash
     
changeit is the default password for the cacerts truststore unless it’s been changed.
  1. Restart your Joget server.

Created by Debanraj Ravindran Last modified by Debanraj Ravindran on Apr 24, 2026