Fixing Maven SSL Issues: Unable to Find Valid Certification Path
About
PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested targetSteps to Fix
Solution 1: Install Certificate
1. Download the certificate
2. Import the certificate into the Java keystore
sudo keytool -importcert -alias artifactory-cert \
-keystore /Library/Java/JavaVirtualMachines/jdk-17.jdk/Contents/Home/lib/security/cacerts \
-file /Users/pranayp/Downloads/artifactory-nginx-jfrog-apps-local.pem3. Enter the keystore password
4. Verify the import
5. Restart Maven and try again
Solution 2: Use JAVA_OPTS to specify external certificate
JAVA_OPTS to specify external certificateLast updated