[xmlsec] Re: How to add <Reference URI=""> instead of <Reference> in dynamically signed xml and also name space to the signature tag and its child elements

Yeshwanth C cyeshwanth at gmail.com
Fri Dec 22 01:18:11 PST 2006


I am using the xmlsec functions given in the sample for dynamically signing
the xml document
but it does NOT come in the following format.  The "ds:" name space does not
appear though everything else appears.  I need to dynamically sign so that
this ds: will be also appear.  This is required so that some Java verifying
program can verify it.
Thanks in advance,
Yesh

<ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
<ds:SignedInfo>
<ds:CanonicalizationMethod Algorithm="
http://www.w3.org/TR/2001/REC-xml-c14n-20010315"></ds:CanonicalizationMethod
>
<ds:SignatureMethod Algorithm="
http://www.w3.org/2000/09/xmldsig#rsa-sha1"></ds:SignatureMethod>
<ds:Reference URI="">
<ds:Transforms>
<ds:Transform Algorithm="
http://www.w3.org/2000/09/xmldsig#enveloped-signature"></ds:Transform>
<ds:Transform Algorithm="
http://www.w3.org/TR/2001/REC-xml-c14n-20010315#WithComments"></ds:Transform
>
</ds:Transforms>
<ds:DigestMethod Algorithm="
http://www.w3.org/2000/09/xmldsig#sha1"></ds:DigestMethod>
<ds:DigestValue>EHfSXC1GvkZzHFiEHXV6eaxaIfI=</ds:DigestValue>
</ds:Reference>
</ds:SignedInfo>
<ds:SignatureValue>



On 12/22/06, Aleksey Sanin <aleksey at aleksey.com> wrote:
>
> >
> > But how to add the namespace for the <signature> tag ? and also it's
> > child elements in a dynamically generated signed xml?
>
> If you use xmlsec functions for creating templates, then namespace
> nodes will be added automatically.
>
> Aleksey
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.aleksey.com/pipermail/xmlsec/attachments/20061222/be9be9bd/attachment-0002.htm


More information about the xmlsec mailing list