1

I'm getting below error while trying to connect twitter streaming API using IBM WAS 6.1 for public stream.

Caused by: javax.net.ssl.SSLHandshakeException: com.ibm.jsse2.util.h: No trusted certificate found
    at com.ibm.jsse2.n.a(n.java:28)
        ..............
Caused by: com.ibm.jsse2.util.h: No trusted certificate found
    at com.ibm.jsse2.util.g.a(g.java:24)

Below setting is used to connect public streaming API

ConfigurationBuilder cb = new ConfigurationBuilder();
cb.setDebugEnabled(true)
.setOAuthConsumerKey("kAhViQqgEGR0cdx7VCtKQ")
.setOAuthConsumerSecret("5S3FodQaLv79v8hflczXuCR1btyafRcp3UVRccOYg")
.setOAuthAccessToken("1444743066-dIsA9jRZYw3fRfO5oysYv9A3VNkqUafT7iYkhV6")
.setOAuthAccessTokenSecret("xuoqLYYGE71Qe56XKYJCnh4s1u5bSoyO4RJRmOjHH4")
.setPrettyDebugEnabled(true)
.setDebugEnabled(true)
.setUserStreamRepliesAllEnabled(true)
Raj
  • 1,698
  • 4
  • 22
  • 39

1 Answers1

2

It looks like you're connecting to the Twitter server via SSL (https), and you haven't added its SSL certificate to your WebSphere Trust Store.

See Certificate Management and the links around it.

To me, the easiest approach is to select the "Cell Default Trust Store" and use the "Retrieve from Port" feature to import the remote server's certificate.

dbreaux
  • 4,982
  • 1
  • 25
  • 64
  • 1
    thank you for providing root cause . I added required certificates in JVM and now it is working properly . below link help a lot to clear my concept of SSL connection in java . http://javarevisited.blogspot.in/2012/03/add-list-certficates-java-keystore.html – Raj Jul 10 '13 at 07:16