Hi Gagani, Can you try adding the certificate to client-truststore and check?
If that is not working, you can change the axis2.xml to allow all hosts. <HostNameVerifier>AllowAll</HostNameVerifier> Thanks, Chanaka On Wed, Jun 18, 2014 at 7:20 AM, Gagani Amarathunga < [email protected]> wrote: > Hi All, > > I'm invoking the SoundCloud API as a connector through the ESB. When I > invoke https urls I get a security exception in the ESB console as shown > below [1]. > > I tried importing the SoundCloud certificate as in the attachment to WSO2 > Carbon Keystore. But it gives same exception still. But I can invoke the > SoundCloud API using the Rest client widget on Firefox. > > Please have a look. > Thanks in advance. > Gagani Amarathunga > > [1] > [2014-06-18 12:44:29,835] ERROR - TargetHandler I/O error: General > SSLEngine problem > javax.net.ssl.SSLHandshakeException: General SSLEngine problem > at sun.security.ssl.Handshaker.checkThrown(Handshaker.java:1290) > at > sun.security.ssl.SSLEngineImpl.checkTaskThrown(SSLEngineImpl.java:513) > at > sun.security.ssl.SSLEngineImpl.writeAppRecord(SSLEngineImpl.java:1177) > at sun.security.ssl.SSLEngineImpl.wrap(SSLEngineImpl.java:1149) > at javax.net.ssl.SSLEngine.wrap(SSLEngine.java:469) > at > org.apache.http.nio.reactor.ssl.SSLIOSession.doWrap(SSLIOSession.java:220) > at > org.apache.http.nio.reactor.ssl.SSLIOSession.doHandshake(SSLIOSession.java:254) > at > org.apache.http.nio.reactor.ssl.SSLIOSession.isAppInputReady(SSLIOSession.java:380) > at > org.apache.http.impl.nio.reactor.AbstractIODispatch.inputReady(AbstractIODispatch.java:118) > at > org.apache.http.impl.nio.reactor.BaseIOReactor.readable(BaseIOReactor.java:160) > at > org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvent(AbstractIOReactor.java:342) > at > org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvents(AbstractIOReactor.java:320) > at > org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:280) > at > org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:106) > at > org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:604) > at java.lang.Thread.run(Thread.java:745) > Caused by: javax.net.ssl.SSLHandshakeException: General SSLEngine problem > at sun.security.ssl.Alerts.getSSLException(Alerts.java:192) > at sun.security.ssl.SSLEngineImpl.fatal(SSLEngineImpl.java:1683) > at sun.security.ssl.Handshaker.fatalSE(Handshaker.java:278) > at sun.security.ssl.Handshaker.fatalSE(Handshaker.java:270) > at > sun.security.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1341) > at > sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:153) > at sun.security.ssl.Handshaker.processLoop(Handshaker.java:868) > at sun.security.ssl.Handshaker$1.run(Handshaker.java:808) > at sun.security.ssl.Handshaker$1.run(Handshaker.java:806) > at java.security.AccessController.doPrivileged(Native Method) > at sun.security.ssl.Handshaker$DelegatedTask.run(Handshaker.java:1227) > at > org.apache.http.nio.reactor.ssl.SSLIOSession.doRunTask(SSLIOSession.java:238) > at > org.apache.http.nio.reactor.ssl.SSLIOSession.doHandshake(SSLIOSession.java:270) > ... 9 more > Caused by: sun.security.validator.ValidatorException: PKIX path building > failed: sun.security.provider.certpath.SunCertPathBuilderException: unable > to find valid certification path to requested target > at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:385) > at > sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:292) > at sun.security.validator.Validator.validate(Validator.java:260) > at > sun.security.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:326) > at > sun.security.ssl.X509TrustManagerImpl.checkTrusted(X509TrustManagerImpl.java:283) > at > sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:138) > at > sun.security.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1328) > ... 17 more > Caused by: sun.security.provider.certpath.SunCertPathBuilderException: > unable to find valid certification path to requested target > at > sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:196) > at java.security.cert.CertPathBuilder.build(CertPathBuilder.java:268) > at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:380) > ... 23 more > [2014-06-18 12:44:29,849] WARN - EndpointContext Endpoint : > AnonymousEndpoint will be marked SUSPENDED as it failed > [2014-06-18 12:44:29,850] WARN - EndpointContext Suspending endpoint : > AnonymousEndpoint - current suspend duration is : 30000ms - Next retry > after : Wed Jun 18 12:44:59 IST 2014 > > _______________________________________________ > Dev mailing list > [email protected] > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- -- Chanaka Fernando Technical Lead WSO2, Inc.; http://wso2.com lean.enterprise.middleware mobile: +94 773337238 Blog : http://soatutorials.blogspot.com LinkedIn:http://www.linkedin.com/pub/chanaka-fernando/19/a20/5b0 Twitter:https://twitter.com/chanakaudaya Wordpress:http://chanakaudaya.wordpress.com
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
