Resource: signature_template.rsa.xml
The KeyFromCSP example uses a signature template file that contains internally referenced text data to be signed. This file has the following characteristics:
- The signed text data, "Hello, World!", is held as the content of a
<ds:Object Id="HelloWorld">
element. - The algorithm used to generate the signature is http://www.w3.org/2000/09/xmldsig#dsa-sha1.
- The signature information,
<ds:KeyInfo>
, is missing and will be added when the data is signed.
Signature Template (signature_template.rsa.xml)
<?xml version="1.0" encoding="UTF-8"?> <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="#HelloWorld" Type= "http://www.w3.org/2000/09/xmldsig#;Object"> <ds:DigestMethod Algorithm= "http://www.w3.org/2000/09/xmldsig#sha1"/> <ds:DigestValue/> </ds:Reference> </ds:SignedInfo> <ds:SignatureValue /> <ds:Object Id="HelloWorld" MimeType="text/plain">Hello, World!</ds:Object> </ds:Signature>