签名/验证.exe给出了未知的出版商

时间:2013-08-01 13:16:03

标签: visual-studio-2008 code-signing

Visual Basic Express 2008,开发了vb.net数据库应用程序。在Win7 x64 PC上。

我更改了构建配置。管理器到平台:x86,因此.exe在x86和x64机器上运行。最后的答案:Setting 32-bit x86 build target in Visual C# 2008 Express Edition?

购买MS Authenticode证书。来自Symantec / Verisign,收到证书,安装在浏览器中。出口证书从浏览器到.pfx。在VS属性/签名选项卡中,选中签名组件,然后导航到.pfx。

在构建之后,使用signtool签署.exe

signtool.exe sign /ac "c:\users\me\desktop\debugv6\winCert.cer" /s MY /t  http://timestamp.verisign.com/scripts/timestamp.dll /n "Our Company Inc." /v c:\users\me\desktop\debugv6\db.exe

The following certificate was selected:
Issued to: Our Company Inc.
Issued by: VeriSign Class 3 Code Signing 2010 CA
Expires:   7/31/2014 6:59:59 PM
SHA1 hash: xxlongStringxx

Done Adding Additional Store

Attempting to sign: c:\users\me\desktop\debugv6\db.exe
Successfully signed and timestamped: c:\users\me\desktop\debugv6\db.exe

Number of files successfully Signed: 1
Number of warnings: 0
Number of errors: 0

然后用signtool验证

signtool.exe verify /pa /v c:\users\me\desktop\debugv6\db.exe

Verifying: c:\users\me\desktop\debugv6\db.exe
SHA1 hash of file: xxlongStringxx
Signing Certificate Chain:
    Issued to: VeriSign Class 3 Public Primary Certification Authority - G5
    Issued by: VeriSign Class 3 Public Primary Certification Authority - G5
    Expires:   7/16/2036 6:59:59 PM
    SHA1 hash: xxlongStringxx

        Issued to: VeriSign Class 3 Code Signing 2010 CA
        Issued by: VeriSign Class 3 Public Primary Certification Authority - G5
        Expires:   2/7/2020 6:59:59 PM
        SHA1 hash: xxlongStringxx

            Issued to: Our Company Inc.
            Issued by: VeriSign Class 3 Code Signing 2010 CA
            Expires:   7/31/2014 6:59:59 PM
            SHA1 hash: xxlongStringxx

The signature is timestamped: 7/31/2013 4:18:46 PM
Timestamp Verified by:
    Issued to: Thawte Timestamping CA
    Issued by: Thawte Timestamping CA
    Expires:   12/31/2020 6:59:59 PM
    SHA1 hash: xxlongStringxx

        Issued to: Symantec Time Stamping Services CA - G2
        Issued by: Thawte Timestamping CA
        Expires:   12/30/2020 6:59:59 PM
        SHA1 hash: xxlongStringxx

            Issued to: Symantec Time Stamping Services Signer - G4
            Issued by: Symantec Time Stamping Services CA - G2
            Expires:   12/29/2020 6:59:59 PM
            SHA1 hash: xxlongStringxx

Successfully verified: c:\users\me\desktop\debugv6\db.exe

Number of files successfully Verified: 1
Number of warnings: 0
Number of errors: 0

问题

从WinXP 32位系统启动.exe时,我得到了发布者:我们的公司很棒。 但是当从一些 Win7 x64机器启动时,我得到了发布者:未知。

任何人都有这个问题。前?

谢谢!

1 个答案:

答案 0 :(得分:3)

简短回答
VeriSign目前的代码签名证书有两条†路径。一个人使用G5作为root。另一个(更兼容)使用G5作为中间。解决方案不仅是添加辅助中间体(如您所做的那样),还包括主要中间体:Download

长答案

检查证书存储区有问题的机器是否找到你的根(VeriSign G5),例如使用开始»执行»mmc.exe»菜单文件»添加管理单元»证书(计算机,本地)»添加»可信第三方证书。如果不存在,我知道这五种替代解决方案:

备选方案A(在有问题的机器上)

  1. 下载'VeriSign Class 3主要CA - G5'(根)
  2. 在Windows中,双击它并在其属性底部
  3. ,单击“安装证书”

备选方案B(在有问题的机器上)

  1. 下载最新的“根证书更新”(KB931125),
  2. 要求您通过正版Windows验证
    (安装几个)新的根源,包括'VeriSign Class 3 Public PCA - G5')

替代C(在有问题的机器上;仅限Windows XP)

  1. 打开Windows Update -Website和
  2. 不选择Express但选择自定义
  3. 安装所有可选更新(安装“根证书更新”)

用户可能已关闭自动根证书更新。在Windows XP中,可以通过开始»控制面板»软件»Windows组件»更新根证书来控制。或者(在Windows XP,Windows Vista和Windows 7中)通过mmc.exe»菜单文件»添加管理单元»组策略对象(本地)»添加»本地计算机策略»管理模板(可选:菜单»操作»添加模板»添加»系统»打开»关闭»)系统»Internet»Internet»关闭自动根证书更新。

备选D

    作为中间证书,使用较旧的< / em>'VeriSign Class 3 Code Signing 2010 CA'到期日:Wed Jan 01 19:59:59 2014年SHA1哈希:14FCF0BB187D563B568EEA5FC888A53D288698D6
    (此中间链接到'3级公共初级认证权限'直接没有G5)

备选方案

    看到简短的回答。 VeriSign对SSL / TLS也做同样的事情。因此,有关详细信息,请查看this explanation …

†实际上有三种途径:G5 CA作为root,G5 CA作为中间,以及旧的2010 CA.作为root的G5 CA是有问题的路径。

示例(根据备选方案E签名)是Adobe Reader(目前为v11.0.0.5)和Apple AirPort实用程序(当前为v5.6.1)。顺便提一下,browser plug-inskernel code drivers有类似的指南。