Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ssl/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
使用java(Axis2)通过代理服务器(mod_Proxy)的SSL连接失败_Java_Ssl_Proxy_Axis2 - Fatal编程技术网

使用java(Axis2)通过代理服务器(mod_Proxy)的SSL连接失败

使用java(Axis2)通过代理服务器(mod_Proxy)的SSL连接失败,java,ssl,proxy,axis2,Java,Ssl,Proxy,Axis2,我正在使用Java(Axis2)连接.NETWeb服务 我从WSDL2Java转换器创建了存根类 代理服务器:Apache mod_Proxy 以下所有案例都使用C#代码,但在Java(Axis2)中出现错误 详细错误日志 Exception Message: Unrecognized SSL message, plaintext connection? Stack Trace: org.apache.axis2.AxisFault: Unrecognized SSL message, pla

我正在使用Java(Axis2)连接.NETWeb服务

我从WSDL2Java转换器创建了存根类

代理服务器:Apache mod_Proxy

以下所有案例都使用C#代码,但在Java(Axis2)中出现错误

详细错误日志

Exception Message: Unrecognized SSL message, plaintext connection? 
Stack Trace: org.apache.axis2.AxisFault: Unrecognized SSL message, plaintext    connection? 
at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430) 
at org.apache.axis2.transport.http.AxisRequestEntity.writeRequest(AxisRequestEntity.java:98) 
at org.apache.commons.httpclient.methods.EntityEnclosingMethod.writeRequestBody(EntityEnclosingMethod.java:499) 
at org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java:2114) 
at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1096) 
at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398) 
at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171) 
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397) 
at org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:621) 
at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:193) 
at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:75) 
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:404) 
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:231) 
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:443) 
at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:406) 
at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229) 
at org.apache.axis2.client.OperationClient.execute(OperationClient.java:165) 
at WebService.ServiceStub.calWebFunction(ServiceStub.java:1892) 
Caused by: 

javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection? 
at sun.security.ssl.InputRecord.handleUnknownRecord(Unknown Source) 
at sun.security.ssl.InputRecord.read(Unknown Source) 
at sun.security.ssl.SSLSocketImpl.readRecord(Unknown Source) 
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source) 
at sun.security.ssl.SSLSocketImpl.writeRecord(Unknown Source) 
at sun.security.ssl.AppOutputStream.write(Unknown Source) 
at java.io.BufferedOutputStream.flushBuffer(Unknown Source) 
at java.io.BufferedOutputStream.flush(Unknown Source) 
at java.io.FilterOutputStream.flush(Unknown Source) 
at org.apache.axis2.transport.http.AxisRequestEntity.writeRequest(AxisRequestEntity.java:94) ... 20 more


    Apache access.log
10.128.43.60 - - [24/Sep/2013:13:49:02 +0900] "\x16\x03\x01" 501 215

Please reply ASAP

你说的是正向代理还是反向代理?@Bruno:它的正向代理带有设置。{ProxyRequests on,ProxyRemote*http:XX.XXXXXXXXX.XX:8080}看起来您的客户端正在直接连接到代理,就像它是目标服务器一样。(请注意,切勿使用EasySSLContext:它容易受到MITM攻击。)
Exception Message: Unrecognized SSL message, plaintext connection? 
Stack Trace: org.apache.axis2.AxisFault: Unrecognized SSL message, plaintext    connection? 
at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430) 
at org.apache.axis2.transport.http.AxisRequestEntity.writeRequest(AxisRequestEntity.java:98) 
at org.apache.commons.httpclient.methods.EntityEnclosingMethod.writeRequestBody(EntityEnclosingMethod.java:499) 
at org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java:2114) 
at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1096) 
at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398) 
at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171) 
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397) 
at org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:621) 
at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:193) 
at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:75) 
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:404) 
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:231) 
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:443) 
at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:406) 
at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229) 
at org.apache.axis2.client.OperationClient.execute(OperationClient.java:165) 
at WebService.ServiceStub.calWebFunction(ServiceStub.java:1892) 
Caused by: 

javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection? 
at sun.security.ssl.InputRecord.handleUnknownRecord(Unknown Source) 
at sun.security.ssl.InputRecord.read(Unknown Source) 
at sun.security.ssl.SSLSocketImpl.readRecord(Unknown Source) 
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source) 
at sun.security.ssl.SSLSocketImpl.writeRecord(Unknown Source) 
at sun.security.ssl.AppOutputStream.write(Unknown Source) 
at java.io.BufferedOutputStream.flushBuffer(Unknown Source) 
at java.io.BufferedOutputStream.flush(Unknown Source) 
at java.io.FilterOutputStream.flush(Unknown Source) 
at org.apache.axis2.transport.http.AxisRequestEntity.writeRequest(AxisRequestEntity.java:94) ... 20 more


    Apache access.log
10.128.43.60 - - [24/Sep/2013:13:49:02 +0900] "\x16\x03\x01" 501 215

Please reply ASAP