添加特定软件证书到windows不信任列表

$target="C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe"
$filePath=$PSScriptRoot+(New-Guid).Guid
$cer = Get-AuthenticodeSignature $target
Export-Certificate -Cert $cer.SignerCertificate -FilePath $filePath
Import-Certificate -FilePath $filePath -CertStoreLocation Cert:\LocalMachine\Disallowed\
Import-Certificate -FilePath $filePath -CertStoreLocation Cert:\CurrentUser\Disallowed\
rm $filePath -Force

 

posted @ 2020-05-25 17:10  talentzemin  阅读(341)  评论(0)    收藏  举报