0

For a non-relevant reason for this question, I need to install some DLL in the client GAC before activate one module on my app.

So, I have done with visual studio 2013 a msi installer to register this DLL into client GAC. As you know, for insert something in the GAC it must be signed. However, despite of the DLL i'm trying to install is signed, every time I try to build de MSI I get this error:

Error   13  Assembly 'Jurassic.dll' must have a shared name to be installed globally

I have correctly signed the dll with this command:

"C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\signtool.exe" sign /n "DIGO ######## S.L" /v Jurassic.dll

enter image description here

Rumpelstinsk
  • 3,107
  • 3
  • 30
  • 57

1 Answers1

1

You are using the wrong signature.

signtool.exe is used to code sign binaries. Code signing is used to proof the binary is not tampered with and comes for a known source. This is not a requirement for the GAC.

To be able to put assemblies in the GAC they have to have a strong name. This requires them to be signed with another signature. This signing also proofs the assembly is not tampered with, but only proofs it comes from a certain source, but not which source it was. You don't need to purchase a certificate from a certificate authority.

So you have to sign it by setting the right project options for the compiler. You can verify it is signed for a strong name with the following command on sn.exe:

sn.exe -vf Jurassic.dll
Lars Truijens
  • 42,837
  • 6
  • 126
  • 143
  • @LarsTrujiens I forget to say it on my question, but the DLL I need to install is not a custom DLL created by me. I downloaded it from internet, so the MSDN article is not useful on this case. I do not have any project, only the DLL. – Rumpelstinsk Jul 06 '15 at 06:22
  • 1
    Then have a look as these questions: http://stackoverflow.com/questions/1669139/signing-an-unsigned-assembly and http://stackoverflow.com/questions/7977363/using-unsigned-assemblies-in-signed-ones – Lars Truijens Jul 29 '15 at 07:30