Why is the "strong key name file" copied to the project?

I want to sign one assembly in my project (for use by another team). In my experience, soon I will need to sign other projects, and I want to sign them with just one file.

I have done the following:

  • Right-click my project, go to properties, go to the "Signing" tab, check the box "Sign assembly", enter the name of the key file (MyKey), click "OK".

my file (MyKey.snk) was saved inside the project folder.

  • I moved the generated key file 1 up to the solutions folder;
  • the Signing tab will open again and in the selected file "Choose a strong key file" from a new location;

and the file MyKey.snk was copied to the project folder.

This is normal? Can I prevent the key file from being copied to the project folder?

Many thanks.

PS I work in VS 2008

+7
source share
1 answer

I believe that VS will always want to see the snk file in the project, but it is great if it is added as a linked file ...

  • Delete snk that was copied to the project
  • Right-click on the project in VS and choose Add> Existing Element ... "
  • Go to the snk solution and in the Add menu, select Add As Link
  • Go to the project properties. Signing tab and you can select the associated snk
+11
source

All Articles