Hi, All:

 

I have a simple question. I have an XML document like following.

 

<?xml version="1.0" encoding="UTF-8">
<Root>
  <Data Id="1234">
    The data I want to sign
  </Data>
</Root>

 

I would like to sign <Data> node with different keys like, rsa_private_key1.pem and rsa_private_key2.pem. How do I do that with the xmlsec app (xmlsec1)?

 

I create a template with two <Signature> nodes in the same XML document. “xmlsec1” always signs the first <Signature> node.

 

<?xml version="1.0" encoding="UTF-8">
<Root>
  <Data Id="1234">
    The data I want to sign
  </Data>

 

        <Signature>

        . . .

    <Reference URI=”#1234”> . . . </Reference>

        . . .

        </Signature>

 

        <Signature>

        . . .

    <Reference URI=”#1234”> . . . </Reference>

        . . .

  </Signature>
</Root>

 

I tried “xmlsec1 –sign –private-pem rsa_private_key1.pem template.xml > tmp.xml”, and then “xmlsec1 –sign –private-pem rsa_private_key2.pem tmp.xml”. I did not have any luck.

 

I am not sure that I did it right. Any help would be appreciated.

 

Thanks.

--Yunhong

 

 

_______________________________________________
xmlsec mailing list
[EMAIL PROTECTED]
http://www.aleksey.com/mailman/listinfo/xmlsec

Reply via email to