Tho*_*fer 5 .net code-signing authenticode
我尝试在安装了 VS2010 的 Windows Server 2008 R2 x64 上使用新的代码签名证书对 .NET 应用程序进行authenticode 签名,但 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
Run Code Online (Sandbox Code Playgroud)
证书安装到用户的个人存储中,并且用户是本地管理员组的成员。我还尝试使用 .pfx 文件进行签名,但不断收到相同的错误。禁用 UAC 提示也没有效果。
有任何想法吗?
原因是启用了私钥保护,但除非以管理员身份运行命令提示符,否则相应的“应用程序正在请求访问受保护的项目”。没有出现提示。
为了解决这个问题,我必须删除证书和密钥,然后从 .pfx 文件重新导入它,这次没有选择强私钥保护选项。
| 归档时间: |
|
| 查看次数: |
9236 次 |
| 最近记录: |