VS2008版本引入第三方dll无强签名

sn.exe 和ilasm.exe 是系统自带程序。如果显示无此命令,可以从“我的电脑”直接搜索。 将dll文件放入目录下,用VS开发人员命令执行以下命令即可。(以Interop.Scripting.dll为例) 1.创建一个新的随机密钥对: sn -k Interop.Scripting.snk 2.反编译目标程序集 ildasm Interop.Scripting.dll /out=Interop.Scripting.il 3.重新编译,附带强命名参数 ilasm Interop.Scripting.il /dll /resource=Interop.Scripting.res /key=Interop.Scripting.snk /optimize 4.验证签名信息 sn -v Interop.Scripting.dll

原文地址:https://www.cnblogs.com/qiu18359243869/p/10314844.html