请问是否可以通过命令行从sys驱动文件中提取数字签名证书?
可以使用第三方工具或内置的Windows工具吗?
谢谢。
请问是否可以通过命令行从sys驱动文件中提取数字签名证书?
可以使用第三方工具或内置的Windows工具吗?
谢谢。
使用PowerShell非常简单:
$driverFile = 'C:\temp\myDriver.sys';
$outputFile = 'C:\temp\output.cer';
$exportType = [System.Security.Cryptography.X509Certificates.X509ContentType]::Cert;
$cert = (Get-AuthenticodeSignature $driverFile).SignerCertificate;
[System.IO.File]::WriteAllBytes($outputFile, $cert.Export($exportType));