다음을 통해 공유


Dev Luv: Digital Signatures for Visio Documents

If you are shipping a custom ActiveX control in your Visio solution, it’s important to know that Visio creates a VBA project when you embed an ActiveX control in a Visio document. That means that you need to sign both the custom ActiveX control and the Visio document itself in your solution. For more information on getting a digital signature for your Visio document, check out this KB article. It summarize the digital signature story for Visio and gives more links to a great tutorial on code signing up on MSDN.

The signcode program only works with Visio XML files. If you want to programmatically sign a Visio binary file, you’ll have to write code to open the binary file in Visio, save as a Visio .vdx, close the file, run the signcode program, reopen the file and save back as binary.

I get a lot of questions asking how to automatically “turn off” the macro warning dialog for customers. The short answer is that you can’t. Only users can turn down their own macro warnings. A responsible developer shouldn’t ask the user to turn down the macro warning settings. There’s only one recommended way to get the macro warning dialog to not appear when opening a Visio document (or any Office document) that contains VBA: the developer must digitally sign the document and the user must select the checkbox about trusting all documents from this source.

Mai-lan

This posting is provided "AS IS" with no warranties, and confers no rights

Comments

  • Anonymous
    January 24, 2005
    Mai Lan, can you elaborate on your experience on getting a good certificate? we don't all have deep pockets. (USD 400!) What happened to: Digital ID for Individual Software Publishers from Microsoft? I can't find any references anymore for obtaining a certificate like that USD 20!
  • Anonymous
    January 26, 2005
    The concept of Digital Signatures is a good idea, but it's implementation leaves a lot to be desired. There is no easy / inexpensive method for an individual to obtain a digital signature.