From fbe64a7ab2e5ce8da1ab69aed0b330f7685c01ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=8F=E8=8E=AB?= Date: Tue, 13 Oct 2026 12:31:53 +0000 Subject: [PATCH] fix(installer): pass test signer switch safely (#924) --- scripts/ci/signpath-files.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ci/signpath-files.ps1 b/scripts/ci/signpath-files.ps1 index b060dd66..3242b279 100644 --- a/scripts/ci/signpath-files.ps1 +++ b/scripts/ci/signpath-files.ps1 @@ -11,7 +11,7 @@ param( [Parameter(Mandatory)][string]$Directory, [string]$Version, [string]$ExpectedSignerThumbprint, - [switch]$AllowUntrustedSigner + [string]$AllowUntrustedSigner ) $ErrorActionPreference = 'Stop' @@ -61,7 +61,7 @@ else { $signed = Join-Path $Directory $file if (-not (Test-Path -LiteralPath $signed)) { throw "SignPath returned no $file" } $signature = Get-AuthenticodeSignature -LiteralPath $signed - if ($signature.Status -ne 'Valid' -and -not $AllowUntrustedSigner) { + if ($signature.Status -ne 'Valid' -and $AllowUntrustedSigner -ne 'true') { throw "SignPath returned $file with signature status $($signature.Status)" } if (-not $signature.SignerCertificate) {