Google Calendar API and WebSphere Application Server Certification Error

Are you having problems connectiong to your Google Calendar with WebSphere Application Server but the application is running just fine with other Application Servers such as Apache Tomcat? If this sounds like you this site should help to get those errors resolved.

When using Google's Calendar API's if you see the following error:

O CWPKI0022E: SSL HANDSHAKE FAILURE: A signer with SubjectDN "CN=www.google.com, O=Google Inc, L=Mountain View, ST=California, C=US" was sent from target host:port "null:null". The signer may need to be added to local trust store "C:/IBM/RADInstall/runtimes/base_v61/profiles/AppSrv01/config/cells/LasNode01Cell/nodes/LasNode01/trust.p12" located in SSL configuration alias "NodeDefaultSSLSettings" loaded from SSL configuration file "security.xml". The extended error message from the SSL handshake exception is: "No trusted certificate found". R com.google.gdata.util.AuthenticationException: Error connecting with login URI
R at com.google.gdata.client.GoogleService.getAuthToken(Unknown Source)
R at com.google.gdata.client.GoogleService.setUserCredentials(Unknown Source)
R at com.google.gdata.client.GoogleService.setUserCredentials(Unknown Source)
R at com.ibm.common.CalendarHelper.getCalendarEntries(CalendarHelper.java:61)
R at com.ibm._jsp._searchResults._jspService(_searchResults.java:122)
R at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:85)
R at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
R at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:966)
R at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
R at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:463)
R at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:115)
R at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.handleRequest(AbstractJSPExtensionServletWrapper.java:168)
R at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3129)
R at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:238)
R at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
R at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1433)
R at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:93)
R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465)
R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:394)
R at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
R at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:152)
R at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:213)
R at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(AbstractAsyncFuture.java:195)
R at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
R at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
R at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:741)
R at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
[5/30/07 11:28:00:123 PDT] 0000002f SystemErr R at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)
[5/30/07 11:28:00:123 PDT] 0000002f SystemErr R Caused by: javax.net.ssl.SSLHandshakeException: com.ibm.jsse2.util.h: No trusted certificate found
at com.ibm.jsse2.n.a(n.java:17)
at com.ibm.jsse2.jc.a(jc.java:541)
at com.ibm.jsse2.db.a(db.java:403)
at com.ibm.jsse2.db.a(db.java:278)
at com.ibm.jsse2.eb.a(eb.java:137)
at com.ibm.jsse2.eb.a(eb.java:157)
at com.ibm.jsse2.db.m(db.java:243)
at com.ibm.jsse2.db.a(db.java:280)
at com.ibm.jsse2.jc.a(jc.java:104)
at com.ibm.jsse2.jc.g(jc.java:470)
at com.ibm.jsse2.jc.a(jc.java:284)
at com.ibm.jsse2.jc.startHandshake(jc.java:172)
at com.ibm.net.ssl.www2.protocol.https.b.afterConnect(b.java:65)
at com.ibm.net.ssl.www2.protocol.https.c.connect(c.java:3)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:865)
at com.ibm.net.ssl.www2.protocol.https.a.getOutputStream(a.java:54)
at com.google.gdata.client.GoogleService.makePostRequest(Unknown Source)
at com.google.gdata.client.GoogleService.getAuthToken(Unknown Source)
at com.google.gdata.client.GoogleService.setUserCredentials(Unknown Source)
at com.google.gdata.client.GoogleService.setUserCredentials(Unknown Source)
at com.ibm.common.CalendarHelper.getCalendarEntries(CalendarHelper.java:61)
at com.ibm._jsp._searchResults._jspService(_searchResults.java:122)
at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:85)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:966)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:463)
at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:115)
at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.handleRequest(AbstractJSPExtensionServletWrapper.java:168)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3129)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:238)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1433)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:93)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:394)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:152)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:213)
at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(AbstractAsyncFuture.java:195)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:741)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)
Caused by: com.ibm.jsse2.util.h: No trusted certificate found
at com.ibm.jsse2.util.g.b(g.java:34)
at com.ibm.jsse2.util.g.b(g.java:16)
at com.ibm.jsse2.util.e.a(e.java:8)
at com.ibm.jsse2.yb.checkServerTrusted(yb.java:18)
at com.ibm.ws.ssl.core.WSX509TrustManager.checkServerTrusted(WSX509TrustManager.java:183)
at com.ibm.jsse2.hb.checkServerTrusted(hb.java:11)
at com.ibm.jsse2.eb.a(eb.java:222)
... 40 more
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.n.a(n.java:17)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.jc.a(jc.java:541)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.db.a(db.java:403)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.db.a(db.java:278)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.eb.a(eb.java:137)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.eb.a(eb.java:157)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.db.m(db.java:243)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.db.a(db.java:280)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.jc.a(jc.java:104)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.jc.g(jc.java:470)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.jc.a(jc.java:284)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.jc.startHandshake(jc.java:172)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.net.ssl.www2.protocol.https.b.afterConnect(b.java:65)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.net.ssl.www2.protocol.https.c.connect(c.java:3)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:865)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.net.ssl.www2.protocol.https.a.getOutputStream(a.java:54)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.google.gdata.client.GoogleService.makePostRequest(Unknown Source)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R ... 28 more
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R Caused by: com.ibm.jsse2.util.h: No trusted certificate found
at com.ibm.jsse2.util.g.b(g.java:34)
at com.ibm.jsse2.util.g.b(g.java:16)
at com.ibm.jsse2.util.e.a(e.java:8)
at com.ibm.jsse2.yb.checkServerTrusted(yb.java:18)
at com.ibm.ws.ssl.core.WSX509TrustManager.checkServerTrusted(WSX509TrustManager.java:183)
at com.ibm.jsse2.hb.checkServerTrusted(hb.java:11)
at com.ibm.jsse2.eb.a(eb.java:222)
at com.ibm.jsse2.eb.a(eb.java:157)
at com.ibm.jsse2.db.m(db.java:243)
at com.ibm.jsse2.db.a(db.java:280)
at com.ibm.jsse2.jc.a(jc.java:104)
at com.ibm.jsse2.jc.g(jc.java:470)
at com.ibm.jsse2.jc.a(jc.java:284)
at com.ibm.jsse2.jc.startHandshake(jc.java:172)
at com.ibm.net.ssl.www2.protocol.https.b.afterConnect(b.java:65)
at com.ibm.net.ssl.www2.protocol.https.c.connect(c.java:3)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:865)
at com.ibm.net.ssl.www2.protocol.https.a.getOutputStream(a.java:54)
at com.google.gdata.client.GoogleService.makePostRequest(Unknown Source)
at com.google.gdata.client.GoogleService.getAuthToken(Unknown Source)
at com.google.gdata.client.GoogleService.setUserCredentials(Unknown Source)
at com.google.gdata.client.GoogleService.setUserCredentials(Unknown Source)
at com.ibm.common.CalendarHelper.getCalendarEntries(CalendarHelper.java:61)
at com.ibm._jsp._searchResults._jspService(_searchResults.java:122)
at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:85)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:966)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:463)
at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:115)
at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.handleRequest(AbstractJSPExtensionServletWrapper.java:168)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3129)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:238)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1433)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:93)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:394)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:152)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:213)
at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(AbstractAsyncFuture.java:195)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:741)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)

[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.util.g.b(g.java:34)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.util.g.b(g.java:16)
[5/30/07 11:28:00:143 PDT] 0000002f SystemErr R at com.ibm.jsse2.util.e.a(e.java:8)
[5/30/07 11:28:00:153 PDT] 0000002f SystemErr R at com.ibm.jsse2.yb.checkServerTrusted(yb.java:18)
[5/30/07 11:28:00:153 PDT] 0000002f SystemErr R at com.ibm.ws.ssl.core.WSX509TrustManager.checkServerTrusted(WSX509TrustManager.java:183)
[5/30/07 11:28:00:153 PDT] 0000002f SystemErr R at com.ibm.jsse2.hb.checkServerTrusted(hb.java:11)
[5/30/07 11:28:00:153 PDT] 0000002f SystemErr R at com.ibm.jsse2.eb.a(eb.java:222)
[5/30/07 11:28:00:153 PDT] 0000002f SystemErr R ... 40 more

It means that you need to go into your WebSphere Administrative Console and make the following changes:

  1. First you must either create a Google Certificate from the Administrator console or just download this google.cer I created. To download just right click on the link and say > Save As rather than clicking on the link.
  2. Next install the certificate to the following location:
    {WAS_INSTALL}\runtimes\base_v61\profiles\AppSrv01\etc
    Make sure the path matches your installation (could be different from above)
  3. Next you'll have to log into your administrative console. If you installed it at it's default location it can be found here
  4. On the left of the Admin Console choose Security > SSL certificate and key management
  5. Choose Key stores and certificates
  6. Select NodeDefaultTrustStore
  7. Choose Signer certificates
    From this page you should see a button to Add
  8. You will see a page similar to this:
    Add Certificate
  9. For Alias type google
  10. For File name point to the location that you installed the certificate in step 2.
  11. Click OK
  12. Your Signer certificates should now include the new certifcate you just added and will look similar to this:
    AdminConsole

    If you select the link to your new google certificate the details should look similar to the following:
    Google Signer Certificate Information
  13. Restart your Server and Try Again!