SunCertPathBuilderException: unable to find valid certification path to requested target

Solution Verified - Updated -

Issue

  • Using maven quarkus-container-image-jib extension for pushing container image to private image registry and issued following command and got the resulting error:
mvn clean package "-DskipTests=true" "-Dquarkus.container-image.push=true" "-Djavax.net.ssl.trustStore=E:\path\to\my.jks" "-Djavax.net.ssl.trustStorePassword=****" "-Djavax.net.ssl.type=PKCS12"

[ERROR] [io.quarkus.container.image.jib.deployment.JibProcessor] I/O error for image [registry.access.redhat.com/ubi8/openjdk-17-runtime]:
[ERROR] [io.quarkus.container.image.jib.deployment.JibProcessor]     javax.net.ssl.SSLHandshakeException
[ERROR] [io.quarkus.container.image.jib.deployment.JibProcessor]     PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

Environment

  • Red Hat build of Quarkus

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content