我试图在安装了 VS2010 的 Windows Server 2008 R2 x64 上使用新的代码签名证书对 .NET 应用程序进行身份验证,但 SignTool 一直响应拒绝访问:
SignTool.exe sign /v /a /sha1 <thumbprint> MyApplication.exe
The following certificate was selected:
Issued to: <redacted>
Issued by: VeriSign Class 3 Code Signing 2010 CA
Expires: Thu Jun 28 01:59:59 2012
SHA1 hash: <thumbprint>
Done Adding Additional Store
SignTool Error: Access is denied.
SignTool Error: An error occurred while attempting to sign: MyApplication.exe
Number of files successfully Signed: 0
Number of warnings: 0
Number of errors: 1
证书安装到用户的个人存储中,并且用户是本地管理员组的成员。我也尝试使用 .pfx 文件进行签名,但一直出现相同的错误。禁用 UAC 提示也没有效果。
有任何想法吗?
最佳答案
我也有这个 pb 在 windows 8 中使用 signtool.exe。要解决,你必须直接从 c:\windows\system32\cmd.exe 单击“以管理员身份运行”运行 cmd.exe。
关于.net - 签名工具错误 : Access is denied,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6532468/