您知道为什么签名证书链中会缺少“Microsoft 代码验证根”吗?
我们最近在两个域之间移动了构建系统,不得不重新安装证书。我们发现我们有一个签名问题,其中 Microsoft 不在导致安装过程中内核驱动程序被拒绝的链中。
我们注意到我们在 certmgr 中有 2 个额外的证书:可信发布者:证书
- 3 级公共(public)初级认证..
- 威瑞信 3 类代码签名...
在禁用Class 3 Public Primary Certification 后,“问题”消失了,我们拥有了正确的签名链,Microsoft 处于领先地位。
我不确定 Class 3 Public Primary Certification 是如何安装的,或者我们使用它的目的是什么,我正在测试以了解我们可能面临的影响。
有没有人遇到过这种问题,他们是如何解决的?有没有办法在命令行上禁用 class-3,这样我就可以单独保留 certmgr 设置,从而降低风险?
感谢帮助
彼得
签署命令
signtool.exe sign /v /ac MSCV-VSClass3.cer /s TrustedPublisher /n "My Corp" /t http://timestamp.verisign.com/scripts/timstamp.dll mydriver.sys
签名验证 signtool 验证/kp/v mydriver.sys
*** Signing Certificate Chain:
*** Issued to: Class 3 Public Primary Certification Authority
*** Issued by: Class 3 Public Primary Certification Authority
*** Expires: 8/2/2028 7:59:59 PM
*** SHA1 hash: xxxxxxxxxxxxxxxxxx
Issued to: VeriSign Class 3 Code Signing 2009-2 CA
Issued by: Class 3 Public Primary Certification Authority
Expires: 5/20/2019 7:59:59 PM
SHA1 hash: xxxxxxxxxxxxxxxxxx
Issued to: My Corp
Issued by: VeriSign Class 3 Code Signing 2009-2 CA
Expires: 9/10/2013 8:59:59 PM
SHA1 hash: xxxxxxxxxxxxxxxxxx
最佳答案
理论上,我可以将与我的证书相匹配的 verisign 交叉签名证书安装到证书存储中,signtool 将自动使用它。但是,这可能会导致错误的证书被用于交叉签名。
越明确越好
- 为通过 certmgr.msc 签名的用户在 trustedpublisher 商店中安装我的证书
- 为您的证书获取正确的证书 ( https://knowledge.verisign.com/support/code-signing-support/index?page=content&actp=CROSSLINK&id=SO5820 )
- 签名时要明确
SignTool.exe sign/v/s trustedpublisher/ac path-to-retrieved-cert\MSCV-VSClass3.cer/n myCertName/t http://timestamp.verisign.com/scripts/timestamp.dll驱动程序文件签名
- 验证
SignTool.exe verify/kp/v drive-file-to-check
或者如果你有目录文件
SignTool.exe verify/kp/v/c driver-cat-file.cat drive-sys-file.sys
关于windows - 驱动程序安装失败,因为交叉签名链不包含微软,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7258613/