We Are Going To Discuss About Spring tool suite- SunCertPathBuilderException: unable to find valid certification path to requested target. So lets Start this Java Article.
Spring tool suite- SunCertPathBuilderException: unable to find valid certification path to requested target
- Spring tool suite- SunCertPathBuilderException: unable to find valid certification path to requested target
I encountered the same problem and tried this: Window -> Preferences -> Network Connections Change mode to Manual
It works fine now. - Spring tool suite- SunCertPathBuilderException: unable to find valid certification path to requested target
I encountered the same problem and tried this: Window -> Preferences -> Network Connections Change mode to Manual
It works fine now.
Solution 1
I encountered the same problem and tried this: Window -> Preferences -> Network Connections Change mode to Manual
It works fine now.
Original Author sundar.sat84 Of This Content
Solution 2
It would seem like the http now gets redirected to https. So changing https to http may not work. I am barely familiar with digital certificates. However, I have simply listed what I had to do to get it to work for me. This is perhaps what @Strelok has suggested.
I am on Windows 10 and JDK 1.8.0_144 64bit. I am also behind a corporate proxy. I did the following to get it to work for me. If you are in a similar situation it may work for you.
Export the corporate certificate (There may be other easier ways of doing this)
- On Chrome, I went to https://start.spring.io
- On the location bar clicked on the ‘Lock’ symbol next to https.
- Selected ‘Certificate(Valid)’ on the ensuing pop-up.
- On the resulting dialog box, clicked on the ‘Certificate Path’ tab, from under certificate path tree selected the root node, and then clicked on ‘View Certificate’
- On the resulting dialog box, clicked on the ‘Details’ tab and then clicked on ‘Copy to File’
- This brings up the ‘Export wizard’, clicked on ‘Next’.
- Left the certificate format to default ‘DER encoded..’, clicked on ‘Next’.
- Provided file name (.cer extension) for the certificate.
- Clicked Finish.
The above steps exported a certificate to a file that I imported into truststore (cacerts).
To import
- Opened a ‘Command’ prompt as Administrator to import the certificate
- Went to bin directory of Java installation (this step is not needed if jre/bin is in your path)
-
Ran the following:
C:\Program Files\Java\jre1.8.0_144\bin>keytool -importcert -alias your-alias -keystore “C:\Program Files\Java\jre1.8.0_144\lib\security\cacerts” -storepass changeit -file C:\certificate-file-location\saved-certificate-file.cer
(Substitute your java location, certificate file location and certificate file name as appropriate. The ‘storepass’ should be ‘changeit’.)
Restarted STS
Original Author user2125853 Of This Content
Solution 3
The simplest solution is to install your corporate certificate into the cacerts
keystore of the JDK.
<JAVA_HOME>/bin/keytool -import -alias CorpProxy -keystore <JAVA_HOME>/jre/lib/security/cacerts -file your_corp_cert.crt
You will be prompted for the keystore password which is changeit
by default.
Original Author Strelok Of This Content
Solution 4
Try http instead of https in the URL
http://start.spring.io
The following error will be resolved
“SunCertPathBuilderException: unable to find valid certification path to requested target“
Original Author Zack Dawood Of This Content
Conclusion
So This is all About This Tutorial. Hope This Tutorial Helped You. Thank You.