Wednesday, April 22, 2015

Strong names to Assembly using sn.exe

To protect assemblies from unauthorised changes they need to be signed with a strong name key. Strong name is valuable in guaranteeing the uniqueness of the assembly. A signed assembly can also be registered in the GAC.

How to sign an assembly?

To sign an assembly first generate a public/private key pair with the sn.exe utility:

sn.exe –k KeyPair.snk

Then you use Visual Studio project properties screen to sign the assembly with the snk file generated above.

image

Technorati Tags: ,

No comments:

Post a Comment