cancel
Showing results for 
Search instead for 
Did you mean: 

XML Signature ignoring tag

Former Member
0 Kudos

Hello

I have a java class that signs XML documents using the sap class com.sap.engine.lib.xml.signature.generator.SignatureGenerator.

The problem is that is ignores the tag <Signature xmlns="http://www.w3.org/2000/09/xmldsig#">, if the document to be signed have a Signature included.

For example, the xml structured to be signed is:

<MainTag>

<Xml1>

<Xml1Info/>

<Signature xmlns="http://www.w3.org/2000/09/xmldsig#">

..

</Signature>

</Xml1>

</MainTag>

The result should be:

<MainTag>

<Xml1>

<Xml1Info/>

<Signature xmlns="http://www.w3.org/2000/09/xmldsig#">

..

</Signature>

</Xml1>

<Signature xmlns="http://www.w3.org/2000/09/xmldsig#">

..

</Signature>

</MainTag>

The problem is that the generated signature is the same if we sign using this source xml:

<MainTag>

<Xml1>

<Xml1Info/>

</Xml1>

</MainTag>

Its completelly ignoring the tag Signature.

Does anyone have faced this problem?

I have another question, where I can find the Sap Javadoc for com.sap.engine.lib.xml.signature.generator.SignatureGenerator ?

Thanks

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

HI Vitor,

I have the same problem.. I am also trying to generate digital signature of an XML  document. I dont know whether there is an api which can do it for me.

If you have solved it, Can you please share a simple code snippet with me ?

Regards

Jony Khatri