Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/394.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

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/redis/2.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 Spring WS-SOAP请求集签名引用URI';s_Java_Spring_Soap_Spring Ws - Fatal编程技术网

Java Spring WS-SOAP请求集签名引用URI';s

Java Spring WS-SOAP请求集签名引用URI';s,java,spring,soap,spring-ws,Java,Spring,Soap,Spring Ws,需要将自定义引用URI值添加到我的SignedInfo和SecurityTokenReference 使用SpringWS和SpringWS安全性并创建了一个SOAP客户端,该客户端由相互身份验证、地址头和二进制安全令牌和签名的设置组成。。。一切都会产生美好的。。。除非服务提供者要求我将引用URI设置为特定值,而不是框架设置的值 我不知道该怎么做?我正在使用Wss4jSecurityInterceptor创建签名等,但不确定如何定义特定的URI 我有一个定制的客户界面,我想也许我可以在那里做,但

需要将自定义引用URI值添加到我的SignedInfo和SecurityTokenReference

使用SpringWS和SpringWS安全性并创建了一个SOAP客户端,该客户端由相互身份验证、地址头和二进制安全令牌和签名的设置组成。。。一切都会产生美好的。。。除非服务提供者要求我将引用URI设置为特定值,而不是框架设置的值

我不知道该怎么做?我正在使用Wss4jSecurityInterceptor创建签名等,但不确定如何定义特定的URI

我有一个定制的客户界面,我想也许我可以在那里做,但也不确定这是否可行

<ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#" Id="SIG-81fb309">
            <ds:SignedInfo>
               <ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
                  <ec:InclusiveNamespaces xmlns:ec="http://www.w3.org/2001/10/xml-exc-c14n#" PrefixList="SOAP-ENV wsa" />
               </ds:CanonicalizationMethod>
               <ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1" />
               <ds:Reference URI="#id-29b0d50b-caa1-422a-b90d-bb6543300ff1">
                  <ds:Transforms>
                     <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" />
                  </ds:Transforms>
                  <ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
                  <ds:DigestValue>gqH/tJW0lrWqkuugE8cUgkK3ofk=</ds:DigestValue>
               </ds:Reference>
            </ds:SignedInfo>
            <ds:SignatureValue>abcdefg</ds:SignatureValue>
            <ds:KeyInfo Id="KI-624f4c36-5">
               <wsse:SecurityTokenReference wsu:Id="STR-b426">
                  <wsse:Reference URI="#X509-74d2f26b-6e2b-4c07-b290-d4e71a94cd21" ValueType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509v3" />
               </wsse:SecurityTokenReference>
            </ds:KeyInfo>

gqH/tjw0lrwqkuuge8cugk3ofk=
abcdefg
因此,从上面开始,需要设置自定义的
URI

ds:Reference URI=“MYCUSTOMURI”和 wsse:Reference URI=“MYCUSTOMURI”