Dotfuscator and GAC
-
I have an assembly that is strongly named and is added to the GAC. All works well. however, if I obfuscate the assmebly using Dotfuscator I get the following error: Failure adding assembly to the cache: Strong name signature could not be verified. Was the assembly built delay-signed? Any ideas on how to fix this?
-
I have an assembly that is strongly named and is added to the GAC. All works well. however, if I obfuscate the assmebly using Dotfuscator I get the following error: Failure adding assembly to the cache: Strong name signature could not be verified. Was the assembly built delay-signed? Any ideas on how to fix this?
nevermind I found it http://www.kessler.de/prd/preemptive/dotfuscator_userguide.pdf[^] Apparently I seem to find soultions after I post a question :-)
-
I have an assembly that is strongly named and is added to the GAC. All works well. however, if I obfuscate the assmebly using Dotfuscator I get the following error: Failure adding assembly to the cache: Strong name signature could not be verified. Was the assembly built delay-signed? Any ideas on how to fix this?
You need to obfuscate it before adding the strong name. The strong name includes a cryptographic hash of the contents of the DLL, which is verified on adding to the GAC, and obfuscating it (obviously) changes the contents. Use
sn.exe
with the -R switch to strong-name-sign a DLL. You may need to specify/delaysign+
to the compiler forsn.exe
to work. I found I had to do this when rebasing a Primary Interop Assembly generated withtlbimp
, sincetlbimp
does not allow the base address to be specified.Stability. What an interesting concept. -- Chris Maunder