none
Signing word documents (2007,2010) use VSTO RRS feed

  • Question

  • Hello All,

    I have project signing content of word documents. I use VSTO to create add in ribbon on word interface. When signing, i get document's content by ThisAddIn.extendedDocument.WordOpenXML, sign content by my certificate and then create an signature image and insert it on document, i create a new package to store data of signature. When verifying, i get document's content (including signature image) and process OpenXML data to retrieve original content to verify (remove signature image).

    But, i have a big problem, data before signing and data after verifying are different -> verify failure. I check data after removing signature image comparing with original content and discovered some new tags and ID of some images in document is changed, etc...

    How can i get exactly original content after inserting an image on word document and then processing XML data to retrieve original content? 

    Any idea?

    Thanks and best regard.

    (sorry my E is not well).

     

    • Moved by 许阳(无锡)Moderator Wednesday, November 2, 2011 8:19 AM OpenXml issue (From:Visual Studio Tools for Office)
    Monday, October 31, 2011 8:54 AM

All replies

  • Hi Tunglq,

     

    Thanks for posting in the MSDN Forum.

     

    It’s based on my experience that your goal is hard approach. Your goal is against the main aim to use digital certificate to sign the document. It’s based on my understanding that sign the document has two goals:

     

    1.         The identified the author of this document.

    2.         Prevent the document to be distorted.

     

    So if you changed something in the document file the digital certificate will lost.

     

    By the way, your issue seems a OpenXml issue. I will move it to that forum to give more specialty support.

     

    Have a good day,

     

    Tom


    Tom Xu [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Wednesday, November 2, 2011 8:17 AM
    Moderator
  • thanks Tom,

    I agree with your point, but when you use "signature line" of MS office, you can see the signature present on word documents, and then verify OK so i think having a same solution "signature line". I also try some solutions of CoSign and ProSigner, they insert image signature on documents. How is your opinion about this solution?

    thank you,

    Tunglq

     



    • Edited by Tunglq Thursday, November 3, 2011 2:07 AM
    Thursday, November 3, 2011 2:04 AM
  • Hi Tunglq,

    I think your goal seems to add a water mark into the document. Is it right?

    Tom


    Tom Xu [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Tuesday, November 8, 2011 9:58 AM
    Moderator
  • Hi Tom,

    No, it's not a water mark, its exactly an image that reference to signature data.

    thanks.

    tunglq 

    Thursday, November 10, 2011 10:30 AM