Click here to Skip to main content
15,889,804 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
I've an assembly in C++/CLI. This assembly is strong named, using Linker options, with a SN.exe generated Key.

However, the same strongly named assembly, if it is digitally signed, using signtool.exe, it seems to remove the strong name signature, indeed the strong name validation fails, and it does not install in the target machine's GAC.

Looking at this documentation : https://msdn.microsoft.com/en-us/library/vstudio/ms235305%28v=vs.100%29.aspx[^]

- it says the strong name key is removed if post processing took, lime mt.exe (I'm not certain if signtool.exe falls in the same tools category)is used afterwards, but it says it does so only if CLR attributes are used. I user Linker options for strong naming.

Kindly advise on the process which can be used to strong name and digitally sign the C++/CLI assembly. Would I have to re-sign the assembly after digitally signing it?

Thanks,
Posted
Updated 10-May-15 19:40pm
v2
Comments
Kornfeld Eliyahu Peter 11-May-15 2:57am    
It should be done in the right order: strong name, and then digital signature...
Member 9378977 11-May-15 2:59am    
That is what I've done. I've strong named it first, using Linker options, and then applied the digital signature, but it seems to affect the strong name signature.

1 solution

Yes you have to do it. Signing is a process from inside to the outside!!!

My experience by using the MageUI-Tool: it is best to sign only once and avoid resigning. And I have reloaded all files in the manifest to update the hashes.
 
Share this answer
 
Comments
Member 9378977 11-May-15 8:37am    
I'm sorry, did you mean I've to resign it? And could you elaborate on the manifest part, please? Thanks.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900