检查数字签名(交叉签名)

(1)检查数字签名

命令为:signtool verify /v /kp test.sys

signtool是vs自带的工具,vs2013是放在C:\Program Files (x86)\Windows Kits\8.0\bin\x64目录上。

(2)检查是否有交叉签名

在数字签名信息中,检查是否有如下内容:

Cross Certificate Chain:
    Issued to: Microsoft Code Verification Root
    Issued by: Microsoft Code Verification Root
    Expires:   Sat Nov 01 21:54:03 2025
    SHA1 hash: 8FBE4D070EF8AB1BCCAF2A9D5CCAE7282A2C66B3


        Issued to: GlobalSign Root CA
        Issued by: Microsoft Code Verification Root
        Expires:   Tue May 24 01:10:51 2016
        SHA1 hash: 3EEB2750A199F5E7B6A8952430BE5062FE04E9E5

(3)数字签名范例(64位下有交叉签名)

E:\wesley\临时文件>"C:\Program Files (x86)\Windows Kits\8.0\bin\x64\signtool.exe

" verify /v /kp E:\test.sys


Verifying: E:\Driver_Repo\DSPrivateData\tags\T_20121108_01_D\Bin\amd64\DSPrivate
Data64.sys
Signature Index: 0 (Primary Signature)
Hash of file (sha1): 3C31CF8C0EB5D2D71A5C4BC73E36292794A6D4AF


Signing Certificate Chain:
    Issued to: GlobalSign Root CA
    Issued by: GlobalSign Root CA
    Expires:   Fri Jan 28 20:00:00 2028
    SHA1 hash: B1BC968BD4F49D622AA89A81F2150152A41D829C


        Issued to: GlobalSign CodeSigning CA - G2
        Issued by: GlobalSign Root CA
        Expires:   Sat Apr 13 18:00:00 2019
        SHA1 hash: 9000401777DD2B43393D7B594D2FF4CBA4516B38


            Issued to: Hangzhou Shunwang Technology Co.,Ltd
            Issued by: GlobalSign CodeSigning CA - G2
            Expires:   Fri Jun 27 11:56:06 2014
            SHA1 hash: 65041C1F155D40DC5BAE81239FBD05827F7ACC2F


The signature is timestamped: Thu Nov 08 11:21:32 2012
Timestamp Verified by:
    Issued to: GlobalSign Root CA
    Issued by: GlobalSign Root CA
    Expires:   Fri Jan 28 20:00:00 2028
    SHA1 hash: B1BC968BD4F49D622AA89A81F2150152A41D829C


        Issued to: GlobalSign Timestamping CA
        Issued by: GlobalSign Root CA
        Expires:   Fri Jan 28 20:00:00 2028
        SHA1 hash: 958D23902D5448314F2F811034356A58255CDC9B


            Issued to: GlobalSign Time Stamping Authority
            Issued by: GlobalSign Timestamping CA
            Expires:   Tue Dec 22 17:32:56 2020
            SHA1 hash: AEDF7DF76BBA2410D67DBAF18F5BA15B417E496C


Cross Certificate Chain:
    Issued to: Microsoft Code Verification Root
    Issued by: Microsoft Code Verification Root
    Expires:   Sat Nov 01 21:54:03 2025
    SHA1 hash: 8FBE4D070EF8AB1BCCAF2A9D5CCAE7282A2C66B3


        Issued to: GlobalSign Root CA
        Issued by: Microsoft Code Verification Root
        Expires:   Tue May 24 01:10:51 2016
        SHA1 hash: 3EEB2750A199F5E7B6A8952430BE5062FE04E9E5


            Issued to: GlobalSign CodeSigning CA - G2
            Issued by: GlobalSign Root CA
            Expires:   Sat Apr 13 18:00:00 2019
            SHA1 hash: 9000401777DD2B43393D7B594D2FF4CBA4516B38


                Issued to: Hangzhou Shunwang Technology Co.,Ltd
                Issued by: GlobalSign CodeSigning CA - G2
                Expires:   Fri Jun 27 11:56:06 2014
                SHA1 hash: 65041C1F155D40DC5BAE81239FBD05827F7ACC2F




Successfully verified: E:\Driver_Repo\DSPrivateData\tags\T_20121108_01_D\Bin\amd
64\DSPrivateData64.sys


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


阅读更多

更多精彩内容