[xsd-users] XML signature validation

Boris Kolpackov boris at codesynthesis.com
Tue Apr 2 10:19:35 EDT 2013


Hi Arul,

Prakash, Arul <Arul.Prakash2 at rsa.com> writes:

> I am trying to verify the signature in a xml document, was wondering 
> if there is any option to do that using CodeSynthesis?

No, XSD does not provide built-in support for this. Rather, you would
need to do it at the Xerces-C++ DOM level. That is, first read the XML
to DOM, verify the signature, then parse DOM to object model. Similarly,
for serialization, first serialize the object model to DOM, add the
signature, then serialize DOM to XML.

You can use the Apache XML Security Library for C++ to do all the
signing/verifying:

http://santuario.apache.org

This page has some sample code:

http://stackoverflow.com/questions/15334616/enveloping-and-detached-xml-signatures-using-apache-xml-security-c-xsec

Boris



More information about the xsd-users mailing list