I want to install a assembly to the global assembly cache (gac) on Windows Server 2008 R2. It is not working since the last Windows Updates.
For example I take the AjaxControlToolkit:
First I check it with the tool sn, after that, I try to install it with the gacutil using the gacuil and the -i option. The command prompt shows the following:
D:\lib>sn -v AjaxControlToolkit.dll
Microsoft (R) .NET Framework Strong Name Utility Version 4.0.30319.1
Copyright (c) Microsoft Corporation. All rights reserved.
Assembly 'AjaxControlToolkit.dll' is valid
D:\lib>gacutil -i AjaxControlToolkit.dll
Microsoft (R) .NET Global Assembly Cache Utility. Version 4.0.30319.1
Copyright (c) Microsoft Corporation. All rights reserved.
Failure adding assembly to the cache: Strong name signature could not be verifie
d. Was the assembly built delay-signed?
The check with sn shows, that everything is ok with the assembly and it is correct string signed. But nevertheless the gacutil cannot verify the strong name signature.
Your assembly is probably delay signed as the error suggests. You are probably skipping verification with using the sn.exe -Vr option. Try the following and verify the assembly without skipping verification (notice the use of -vf instead of -v).
The reason gacutil is not skipping validation might be because your sn.exe is 32 bit and gacutil.exe is 64 bit or the other way around. Verification skipping can be different depending on the bitness of the process.
If the assembly is delay signed make sure you really sign it before it adding it to the GAC.