0
votes

scenario:
1. in STS open 'servers' view and add 'cloudFoundry' server
2. in the new server wizard enter "https://api.run.pivotal.io/" and user password
3. press next - I get the following exception :

Unable to communicate with server - I/O error on GET request for "https://api.run.pivotal.io/info":sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target; nested exception is javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

tried adding SSL certificate from the URL to the JDK used by STS ,
also tried using the "Trust self-signed certificate" option

both didn't help.

1

1 Answers

0
votes

One suggestion to see why connecting to Pivotal Web Services (api.run.pivotal.io) is not working through STS, is to verify that when you added the SSL certificate to the JDK used by STS, it is listed by Java keytool.

For Pivotal Web Services, I believe it should be DigiCert:

Owner: CN=DigiCert Global Root CA, OU=www.digicert.com, O=DigiCert Inc, C=US

Normally, if this certificate appears in the list of certificates used by the STS JDK, users should be able to connect without getting validator exceptions, and without having to check "Trust self-signed certificate" option.

Maybe this related post can provide additional information:

PKIX path building failed in Java application

Unlike the cf CLI via the option:

--skip-ssl-validation

the Cloud Foundry Tools in STS does not have an option to skip SSL validation.