Content Controls, Custom XML, Digital Signatures

Hi,

I'm not sure if this is exactly the right place to ask this, but here goes.

I'm using classes System.IO.Packaging to digitally sign a custom XML part inside a DOCX file. With a simple document everything is OK, I can verify the signature both by using PackageDigitalSignatureManager as well as MS Word 2007 (both show valid signatures). Also when I modify the custom XML, the signature is correctly reported as broken.

Everything works also with a document that has content controls that are not bound to Custom XML.

But when I bind those content controls to any custom xml inside the DOCX and sign it, Word 2007 isn't able to validate the signature, but verifying using System.IO.Packaging still works, however.

Im using this excellent post (http://blogs.infosupport.com/wouterv/archive/2007/02/24/Signing-Office-Open-XML-documents-using-the-Packaging-API.aspx) as the basis with the difference that I'm only signing a Custom XML part inside. Maybe I'm adding an incorrect office object or something, but it's hard to find documentation on the issue.

Thanks,

Jarno

[1399 byte] By [JarnoLeikas] at [2008-3-7]