Skip to content

Commit

Permalink
(maint) Updates Install Signing Script
Browse files Browse the repository at this point in the history
The Chocolatey code signing script was recently changed for Reasons, and during the process our expected subject changed slightly.
  • Loading branch information
JPRuskin committed May 21, 2024
1 parent 6498db7 commit 0a73ca0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion OfflineInstallPreparation.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ if (-not (Test-Path $ChocoInstallScript)) {

$Signature = Get-AuthenticodeSignature -FilePath $ChocoInstallScript

if ($Signature.Status -eq 'Valid' -and $Signature.SignerCertificate.Subject -eq 'CN="Chocolatey Software, Inc.", O="Chocolatey Software, Inc.", L=Topeka, S=Kansas, C=US') {
if ($Signature.Status -eq 'Valid' -and $Signature.SignerCertificate.Subject -eq 'CN="Chocolatey Software, Inc", O="Chocolatey Software, Inc", L=Topeka, S=Kansas, C=US') {
if (-not (Get-Command choco.exe -ErrorAction SilentlyContinue)) {
if (Test-Path $PSScriptRoot\files\chocolatey.*.nupkg) {
$env:ChocolateyDownloadUrl = (Convert-Path $PSScriptRoot\files\chocolatey.*.nupkg)[0]
Expand Down
2 changes: 1 addition & 1 deletion Start-C4bNexusSetup.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ process {

$Signature = Get-AuthenticodeSignature -FilePath $ChocoInstallScript

if ($Signature.Status -eq 'Valid' -and $Signature.SignerCertificate.Subject -eq 'CN="Chocolatey Software, Inc.", O="Chocolatey Software, Inc.", L=Topeka, S=Kansas, C=US') {
if ($Signature.Status -eq 'Valid' -and $Signature.SignerCertificate.Subject -eq 'CN="Chocolatey Software, Inc", O="Chocolatey Software, Inc", L=Topeka, S=Kansas, C=US') {
New-NexusRawComponent -RepositoryName 'choco-install' -File $ChocoInstallScript
} else {
Write-Error "ChocolateyInstall.ps1 script signature is not valid. Please investigate."
Expand Down

0 comments on commit 0a73ca0

Please sign in to comment.