利用WSE 加密SOAP报文(8)-.Net技术-3P代码网
繁体中文
设为首页
加入收藏
当前位置:.Net技术首页 >> Web Service开发 >> 利用WSE 加密SOAP报文(8)

利用WSE 加密SOAP报文(8)

2004-10-01 08:26:10  作者:  来源:互联网  浏览次数:16  文字大小:【】【】【
简介:下面是被WSE在运行时序列化后产生的报文加密后的结果 <?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/&qu...
关键字:报文 加密 SOAP WSE

下面是被WSE在运行时序列化后产生的报文加密后的结果

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

xmlns:wsu="http://schemas.xmlsoap.org/ws/2002/07/utility">

2003-02-11T20:21:52Z

2003-02-11T20:26:52Z

xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/07/secext">

Type="http://www.w3.org/2001/04/xmlenc#EncryptedKey"

xmlns:xenc="http://www.w3.org/2001/04/xmlenc#">

Algorithm="http://www.w3.org/2001/04/xmlenc#rsa-1_5" />

YmlKVwXYD8vuGuYliuIOXOY7ZYN9PwHbfAhCiYOV0aYdEAQQPw=

UyKGBEXdY8lYSzqgdgxOXOY7ZYN9PwHbfAhCiYOV0...bwRnWk=

"#EncryptedContent-cf014249-0e2a-4f8b-9002-13a7de916be0" />

Type="http://www.w3.org/2001/04/xmlenc#EncryptedKey"

xmlns:xenc="http://www.w3.org/2001/04/xmlenc#">

Algorithm="http://www.w3.org/2001/04/xmlenc#rsa-1_5" />

YmlKVwXYD8vuGuYliuIYdEAQQPw=

In8Kf1cIdiJJJXCLZ+... wMqBEevXmzk=

"#EncryptedContent-0744279a-02bf-4ad1-998e-622208eded0e" />

This part of the response does not need encryption

wsu:Id="Id:e5e8d792-abe7-4476-91d0-856fbdf4a958"

xmlns:wsu="http://schemas.xmlsoap.org/ws/2002/07/utility">

Id=

"EncryptedContent-cf014249-0e2a-4f8b-9002-13a7de916be0"

Type="http://www.w3.org/2001/04/xmlenc#Content"

xmlns:xenc="http://www.w3.org/2001/04/xmlenc#">

Algorithm=

"http://www.w3.org/2001/04/xmlenc#tripledes-cbc" />

2MNHCkGVH/5jb0pF4pCh3u2VaUKsWSA...AfEvJZT=

注意,在这个加密后的报文里,这里有一个用于表示X.509证书的BinarySecurityToken元素,但有两个分开的EncryptedKey元素,每个EncryptedData元素都被添加到SoapContext,在最外面的被加密的元素中(EncryptedResponse),你只能看到EncryptedData元素,当EncryptedResponse被加密后,表示EncryptedSub元素的EncryptedData元素也随之转换为密文了。当这个报文在客户端被收到时,SecurityInputFilter使用来自记号的信息来得到曾给两个EncryptedKey元素解密过的私有密钥。

责任编辑:admin
相关文章