Axis 调用.net WebServic接口出现:验证消息的安全性时发生错误

解决方法:call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP12_CONSTANTS);

参考:http://www.blogjava.net/andy199999/

异常内容:

AxisFault

faultCode: {http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd}InvalidSecurity

faultSubcode:

faultString: 验证消息的安全性时发生错误。

faultActor:

faultNode:

faultDetail:

{http://xml.apache.org/axis/}stackTrace:验证消息的安全性时发生错误。

at org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:222)

at org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:129)

at org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087)

at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:601)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1782)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2939)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:647)

at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:140)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:511)

at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:808)

at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)

at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:119)

at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1205)

at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:522)

at javax.xml.parsers.SAXParser.parse(SAXParser.java:395)

at org.apache.axis.encoding.DeserializationContext.parse(DeserializationContext.java:227)

at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:696)

at org.apache.axis.Message.getSOAPEnvelope(Message.java:435)

at org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.java:796)

at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:144)

at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)

at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)

at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)

at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)

at org.apache.axis.client.Call.invokeEngine(Call.java:2784)

at org.apache.axis.client.Call.invoke(Call.java:2767)

at org.apache.axis.client.Call.invoke(Call.java:2443)

at org.apache.axis.client.Call.invoke(Call.java:2366)

at org.apache.axis.client.Call.invoke(Call.java:1812)

at com.xhdx.ems.entity.AuthClient.main(AuthClient.java:40)

Axis 调用.net WebServic接口出现:验证消息的安全性时发生错误

时间: 2024-10-23 00:51:04

Axis 调用.net WebServic接口出现:验证消息的安全性时发生错误的相关文章

Axis 调用.net WebServic接口出现:验证消息的安全性时错误发生

解决方法:call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP12_CONSTANTS); 參考:http://www.blogjava.net/andy199999/ 异常内容: AxisFault faultCode: {http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd}InvalidSecurity faultS

(微信API接口开发) 使用HttpWebRequest进行请求时发生错误:基础连接已关闭,发送时发生错误处理

最近调试原来的微信模拟登陆时发生了"基础连接已关闭,发送时发生错误"的错误提示,原来都是好好的,只是很久没用了. 出错代码如下: ? 1 2 3 4 5 6 7 HttpWebRequest req = (HttpWebRequest)HttpWebRequest.Create("https://mp.weixin.qq.com/cgi-bin/loginpage?t=wxm2-login&lang=zh_CN");///cgi-bin/loginpage?

SVN“验证位置时发生错误”的解决办法

验证位置时发生错误:“org.tigris.subversion.javahl.ClientException...... 验证位置时发生错误:“org.tigris.subversion.javahl.ClientException: RA layer request failed svn: Server sent unexpected return value (403 Forbidden) in response to OPTIONS request for 'http://192.168

验证位置时发生错误:“org.tigris.subversion.javahl.ClientException......

验证位置时发生错 误:“org.tigris.subversion.javahl.ClientException: RA layer request failed svn: Server sent unexpected return value (403 Forbidden) in response to OPTIONS request for 'http://192.168.1.50/svn/products/PD007D1020/changAnCar/' 解决方法: 删除C:\Documen

微信超时5s,调用客服接口异步回复消息(PHP)

当用户触发事件,如果不能保证在5s内响应,可以先返回success,然后异步调用返回的信息.代码如下: 1 // 立即返回(异步执行) 2 ignore_user_abort(true);//start========= 3 ob_start(); 4 echo 'success'; // send the response 5 header('Connection: close'); 6 header('Content-Length: ' . ob_get_length()); 7 ob_en

使用AXIS调用需要身份验证的WebService

使用AXIS调用WebService的方法请参见我另一篇博文Java调用WebService的方法总结,这里只记叙使用axis验证身份. 1.验证信息通过请求报文头传递 我遇到的情况是访问WebService需要进行Windows身份验证,做法是将用户名和密码信息加密后通过添加“Authorization”请求报文头发送,所以实现的Java代码如下: /* * Create new Service and Call objects. These are the standard * JAX-RP

调用支付宝转账接口(单笔)

下面这几个类都是支付宝demo里面的,直接拿过来用就可以 using System.Web; using System.Text; using System.IO; using System.Net; using System; using System.Collections.Generic; namespace Com.Alipay { public class Config { #region 字段 private static string partner = ""; priv

asp.net mvc 如何调用微信jssdk接口:分享到微信朋友(圈)| 分享到qq空间

如何在asp.net mvc 项目里, 调用微信jssdk接口,现实功能: 分享到微信朋友(圈)| 分享到qq空间 1 创建一个Action,准备一些数据,初始化数据(签名): /// <summary> /// 分享的内容 /// 必须写在html的head里面才可以生效 /// </summary> /// <param name="fxUrl"></param> /// <returns></returns>

WCF使用安全证书验证消息加密

首先安装 服务端安全证书  代码如下:  // 下面第一行是安装证书,第二行是将证书列入信任 makecert.exe -sr LocalMachine -ss MY -a sha1 -n CN=localhost -sky exchange -pe certmgr.exe -add -r LocalMachine -s My -c -n localhost -r CurrentUser -s TrustedPeople 安装客户端安全证书代友如下 makecert.exe -sr LocalM