Connecting Tech Pros Worldwide Help | Site Map

XML Digital Signature

Diego Mourglia
Guest
 
Posts: n/a
#1: Jun 27 '08
Hi

I'm trying to Sign an XML Document Using SignedXml.ComputeSignature from the
namespace System.Security.Cryptography.Xml.

I need the XML in the following way, with the prefix DS ahead the tag name:

<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:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"
/>
- <ds:Reference URI="#1003 Fri Jun 06 14:56:14 VET 2008">
- <ds:Transforms>
<ds:Transform Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"
/>
</ds:Transforms>
<ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
<ds:DigestValue>xctwBpj1DjKCnGWLnxSXrFjv0Xk=</ds:DigestValue>
</ds:Reference>
</ds:SignedInfo>
<ds:SignatureValue>WI48iJNIBsQJDnMx5OVhQMFL7/AvKR7/+SWWpvqGOm
vazdF64zBvrSskYkPivUvFIL0toB10eqNbXbPIfc/a1XSq0YvOBlMtaX
+ykN/AHZl8FkLPNokQHE wPuxvo2Y+bMt5N9xG6c=</ds:SignatureValue>
- <ds:KeyInfo>
<ds:KeyName>1003</ds:KeyName>
</ds:KeyInfo>
- <ds:Object Id="1003 Fri Jun 06 14:56:14 VET 2008">
- <Originante_ACH>
<num_orden_originante>Datos.....</num_orden_originante>
</Originante_ACH>
</ds:Object>
</ds:Signature>

I have the same XML but without the ds prefix. Anybody kows how to add it ?

Tanks

Closed Thread