@@ -79,11 +79,6 @@ function Test-RequiredAssets {
79
79
}
80
80
81
81
Write-Host " ✅ Found $ ( $required.Value ) in: $ ( $found.Name ) " - ForegroundColor Green
82
-
83
- # Verify GitHub attestation
84
- if (-not (Test-GithubAttestation - FilePath $found.FullName - RepoName " Yubico/Yubico.NET.SDK" )) {
85
- throw " Attestation verification failed for: $ ( $found.Name ) "
86
- }
87
82
}
88
83
}
89
84
@@ -198,6 +193,7 @@ Invoke-NuGetPackageSigning -Thumbprint "0123456789ABCDEF" -WorkingDirectory "C:\
198
193
. NOTES
199
194
Requires:
200
195
- A smart card with the signing certificate
196
+ - Github CLI for attestation
201
197
- signtool.exe (Windows SDK)
202
198
- nuget.exe
203
199
- PowerShell 5.1 or later
@@ -287,6 +283,12 @@ function Invoke-NuGetPackageSigning {
287
283
$packages = Get-ChildItem - Path $extractPath - Recurse - Include * .nupkg, * .snupkg
288
284
foreach ($package in $packages ) {
289
285
Write-Host " Copying: $ ( $package.Name ) "
286
+
287
+ # Verify GitHub attestation (that the file has been downloaded from our repo)
288
+ if (-not (Test-GithubAttestation - FilePath $package.FullName - RepoName " Yubico/Yubico.NET.SDK" )) {
289
+ throw " Attestation verification failed for: $ ( $package.Name ) "
290
+ }
291
+
290
292
Copy-Item - Path $package.FullName - Destination $directories.Unsigned - Force
291
293
}
292
294
Write-Host " ✓ Copied $ ( $packages.Count ) package(s)"
@@ -325,7 +327,7 @@ function Invoke-NuGetPackageSigning {
325
327
}
326
328
327
329
# Copy symbol packages to output directory
328
- Write-Host " `n Copying symbol packages..."
330
+ Write-Host " `n Copying symbol packages..." - ForegroundColor Yellow
329
331
$symbolPackages = Get-ChildItem - Path $directories.Unsigned - Filter " *.snupkg"
330
332
foreach ($package in $symbolPackages ) {
331
333
Write-Host " Copying: $ ( $package.Name ) "
0 commit comments