Re: XChange/PXIX SSL/TSL handshake traceback error for new users.
Please type your response : I Agree
2013-04-19 20:07:36,553 ←[34m:←[0;39m Aido ATP has started successfully
2013-04-19 20:07:36,553 ←[34m:←[0;39m Using trend following to decide some trades.
2013-04-19 20:07:36,563 ←[34m:←[0;39m Connecting to BTC-e Exchange
2013-04-19 20:07:36,563 ←[34m:←[0;39m Connecting to MtGox Exchange
2013-04-19 20:07:42,645 ←[31m:←[0;39m WARNING: Testing connection to exchange MtGox
Exception in thread "Thread-2" com.xeiam.xchange.rest.HttpException: Problem POSTing
(IO)
at com.xeiam.xchange.rest.HttpTemplate.executeRequest(HttpTemplate.java:198)
at com.xeiam.xchange.rest.HttpTemplate.executeRequest(HttpTemplate.java:97)
at com.xeiam.xchange.rest.RestInvocationHandler.invokeHttp(RestInvocationHand
ler.java:61)
at com.xeiam.xchange.rest.RestInvocationHandler.invoke(RestInvocationHandler.
java:56)
at com.sun.proxy.$Proxy7.getAccountInfo(Unknown Source)
at com.xeiam.xchange.mtgox.v1.service.account.MtGoxPollingAccountService.getA
ccountInfo(MtGoxPollingAccountService.java:74)
at org.aido.atp.AccountManager.refreshAccounts(AccountManager.java:121)
at org.aido.atp.AccountManager.run(AccountManager.java:101)
at java.lang.Thread.run(Unknown Source)
Caused by: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorExcep
tion: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderExc
eption: unable to find valid certification path to requested target
at sun.security.ssl.Alerts.getSSLException(Unknown Source)
at sun.security.ssl.SSLSocketImpl.fatal(Unknown Source)
at sun.security.ssl.Handshaker.fatalSE(Unknown Source)
at sun.security.ssl.Handshaker.fatalSE(Unknown Source)
at sun.security.ssl.ClientHandshaker.serverCertificate(Unknown Source)
at sun.security.ssl.ClientHandshaker.processMessage(Unknown Source)
at sun.security.ssl.Handshaker.processLoop(Unknown Source)
at sun.security.ssl.Handshaker.process_record(Unknown Source)
at sun.security.ssl.SSLSocketImpl.readRecord(Unknown Source)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)
at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)
at sun.net.www.protocol.https.HttpsClient.afterConnect(Unknown Source)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unkn
own Source)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(Unknown Source
)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getOutputStream(Unknown
Source)
at com.xeiam.xchange.rest.HttpTemplate.executeRequest(HttpTemplate.java:181)
... 8 more
Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.
security.provider.certpath.SunCertPathBuilderException: unable to find valid certific
ation path to requested target
at sun.security.validator.PKIXValidator.doBuild(Unknown Source)
at sun.security.validator.PKIXValidator.engineValidate(Unknown Source)
at sun.security.validator.Validator.validate(Unknown Source)
at sun.security.ssl.X509TrustManagerImpl.validate(Unknown Source)
at sun.security.ssl.X509TrustManagerImpl.checkTrusted(Unknown Source)
at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(Unknown Source)
... 21 more
Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find
valid certification path to requested target
at sun.security.provider.certpath.SunCertPathBuilder.engineBuild(Unknown Sour
ce)
at java.security.cert.CertPathBuilder.build(Unknown Source)
... 27 more
Ok, I've made slight progress re: the SSL/TLS handshake issue with the XChange library used in ATP.
After importing the entire SSL cert chain from both
1. mtgox.com
2. https://data.mtgox.com
To java cacerts, version 1.7_u13 64 bit, I no longer receive the PXIX/handshake/xchange traceback.
you'll need to download and install java SE 7 update 13.
Use your browser to download
all of the CA and site certs (In Chrome you can do this by downloading in .P7B format when viewing the cert properties). Then, for Windows you'll need to import the P7B in to the Certificate manager, then perform an export of all of the CA and site certs to individual x509 DER files.
Use java's keytool utility to import each cert.
Confirmed working.