Quickly sign your assembly with strong name using VS 2005

when using Visual studio 2003 to sign an assembly you used to generate the key using the snk command utility and override the Assembly.info file manually to set the signing information .

In Visual Studio 2005 you can easily do this with fewer easy steps :

1- Right click on the project which need to be signed and choose properties.

2- Choose Signing from the left panel.

image

3- Check the ‘Sign the assembly ’ checkbox and choose browse if you already have a strong name key or new if you want to generate a new key.

image

4- A dialog will pop up type the key name and whether you need to protect it with password or not.

image

5- Save the settings and build your solution again.

 

Enjoy :)

5 Comments

  • This was really helpful

  • May I ask a stupid question... Why sign your assembly? After an hour of googling, I have found plenty of posts telling me how but none telling me why. I guess I have nothing to fear in signing my assemblies. I just don't see the benefit in signing or the harm in not signing. If anybody has a good article on this, please post it here.

  • you sign the shared assembly because it is placed in the GAC which is accessible by all applications.
    GAC is capable of maintaining multiple copies of an assembly with the same name but different versions.

    which prevent the common dll Hell problem.

    for more information refer to
    http://www.startvbdotnet.com/extras/dhell.aspx
    http://dotnetguts.blogspot.com/2007/09/assemblies-concept-in-net.html

  • Also if your app is signed you cannot reference components that are not signed.


    J

  • Very helpful, simple and straight to the point. Better than the dross on the official Microsoft articles page

Comments have been disabled for this content.