Strange problems about strong name verification skipping
My ASP.NET application is using an assembly without strong name. When I run it in IE, it shows an error saying:
Could not load file or assemlby 'xxxxx.' or one of its dependencies. Strong na开发者_JAVA百科me signatuer could not be verified. The assembly may have been tampered with, or it was delay signed but not fully signed with the correct private key. (Exception from HRESULT: 0x80131045)"
I use sn.exe -Vr xxxx
to register that assembly to skip the strong name verification, but still it shows that error. What could be causing this problem, and what can I do next to fix it?
This is because you are using 32 bit sn.exe to unsign an assembly in your 64 bit machine or vice versa. Use proper sn.exe you to solve this issue. Please see the hyperlink for the solution
That's delay signing, intended for testing: you need to run sn -Vr
on every machine that you want to skip verification on.
I guess you'll have to complete the signing, sn -r
, before you publish your assembly to the web.
精彩评论