1

我被困在我的基于axis2的客户端从websphere 6.1调用ssl服务并抛出以下异常以及顶部的消息的问题。我已按照单击此处的步骤在默认信任库中使用 IBM websphere 管理控制台安装 ssl 证书。请注意,此客户端在 APACHE Tomcat 上运行良好。在这方面的任何帮助将非常感谢。

setting up default SSLSocketFactory

class com.ibm.websphere.ssl.protocol.SSLSocketFactory is loaded

SSLSocketFactory instantiation failed: java.lang.ClassCastException: 
com.ibm.websphere.ssl.protocol.SSLSocketFactory incompatible with         javax.net.ssl.SSLSocketFactory

{HttpMethodDirector:439} - I/O exception (java.net.SocketException) caught when     processing request: java.lang.ClassCastException:     com.ibm.websphere.ssl.protocol.SSLSocketFactory 
incompatible with javax.net.ssl.SSLSocketFactory

{HttpMethodDirector:445} - Retrying request

{HttpMethodDirector:439} - I/O exception (java.net.SocketException) caught when     processing request: java.lang.ClassCastException:     com.ibm.websphere.ssl.protocol.SSLSocketFactory incompatible with     javax.net.ssl.SSLSocketFactory

{HttpMethodDirector:445} - Retrying request

{HttpMethodDirector:439} - I/O exception (java.net.SocketException) caught when     processing request: java.lang.ClassCastException: com.ibm.websphere.ssl.protocol.SSLSocketFactory incompatible with javax.net.ssl.SSLSocketFactory

{HttpMethodDirector:445} - Retrying request

{HTTPSender:202} - Unable to sendViaPost to url[https://sma/CBDSMS/api/GetDue.svc]
java.net.SocketException: java.lang.ClassCastException:     com.ibm.websphere.ssl.protocol.SSLSocketFactory incompatible with     javax.net.ssl.SSLSocketFactory
at javax.net.ssl.DefaultSSLSocketFactory.throwException(Unknown Source)
at javax.net.ssl.DefaultSSLSocketFactory.createSocket(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:615)
at org.apache.commons.httpclient.protocol.ReflectionSocketFactory.createSocket(ReflectionSocketFactory.java:116)
at org.apache.commons.httpclient.protocol.SSLProtocolSocketFactory.createSocket(SSLProtocolSocketFactory.java:130)
at org.apache.commons.httpclient.HttpConnection.open(HttpConnection.java:707)
at org.apache.commons.httpclient.MultiThreadedHttpConnectionManager$HttpConnectionAdapter.open(MultiThreadedHttpConnectionManager.java:1361)
at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:387)
at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346)
at org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:560)
at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:199)
at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:76)
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:400)
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:225)
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:438)
at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:402)
at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229)
at org.apache.axis2.client.OperationClient.execute(OperationClient.java:165)
4

1 回答 1

0

请在此 Web 应用程序的类加载器中使用“最后一个父级”设置。有关详细信息,请参见此处

于 2012-06-06T11:39:00.867 回答