|
1 | | -name: Windows validated signing handoff |
| 1 | +name: Windows signed package attestations |
2 | 2 |
|
3 | 3 | on: |
4 | 4 | push: |
5 | 5 | branches: [shailendra-nv/windows-security-handoff] |
6 | | - paths: ['.github/workflows/windows-signing-handoff.yml', 'signing-handoff/**'] |
| 6 | + paths: ['.github/workflows/windows-signing-handoff.yml', 'signing-handoff/signed-release/**'] |
7 | 7 | workflow_dispatch: |
8 | 8 |
|
9 | 9 | permissions: |
10 | 10 | contents: read |
11 | 11 | actions: read |
12 | | - attestations: read |
13 | 12 |
|
14 | 13 | jobs: |
15 | | - handoff: |
| 14 | + attest: |
16 | 15 | if: github.repository == 'NVIDIA/OpenShell' |
17 | 16 | runs-on: ubuntu-latest |
18 | 17 | timeout-minutes: 15 |
| 18 | + permissions: |
| 19 | + contents: read |
| 20 | + actions: read |
| 21 | + id-token: write |
| 22 | + attestations: write |
| 23 | + artifact-metadata: write |
19 | 24 | steps: |
20 | 25 | - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 |
21 | 26 | with: |
22 | 27 | persist-credentials: false |
| 28 | + sparse-checkout: signing-handoff/signed-release |
23 | 29 | - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 |
24 | 30 | with: |
25 | 31 | name: OpenShell-Windows-0.1.8-signing-candidates |
26 | | - run-id: 43545453103 |
| 32 | + run-id: 43743849384 |
27 | 33 | github-token: ${{ github.token }} |
28 | | - path: handoff |
29 | | - - name: Verify original GitHub-built ZIP attestations |
| 34 | + path: candidates |
| 35 | + - name: Verify original GitHub build provenance |
30 | 36 | env: |
31 | 37 | GH_TOKEN: ${{ github.token }} |
32 | 38 | run: | |
33 | 39 | for arch in arm64 x64; do |
34 | | - gh attestation verify "handoff/OpenShell-Windows-0.1.8-$arch-unsigned-candidate.zip" \ |
| 40 | + gh attestation verify "candidates/OpenShell-Windows-0.1.8-$arch-unsigned-candidate.zip" \ |
35 | 41 | --repo NVIDIA/OpenShell \ |
36 | 42 | --signer-workflow NVIDIA/OpenShell/.github/workflows/windows-packages.yml \ |
37 | | - --signer-digest 1c2521b7e839ffeb1ae0f37a77f5b9a700d3a536 \ |
| 43 | + --signer-digest f258c85b202a78e0b233f39cc8f991069ef509ab \ |
38 | 44 | --deny-self-hosted-runners \ |
39 | | - --bundle handoff/github-attestation.sigstore.json |
| 45 | + --bundle candidates/github-attestation.sigstore.json |
40 | 46 | done |
41 | 47 | - uses: jdx/mise-action@e6a8b3978addb5a52f2b4cd9d91eafa7f0ab959d # v4.2.0 |
42 | 48 | with: |
43 | 49 | install: false |
44 | | - experimental: true |
45 | | - - name: Bind external validation report and stage signing inputs |
| 50 | + - name: Install validation tools |
| 51 | + run: mise install uv@0.10.12 python@3.14.5 |
| 52 | + - name: Verify external signing and validation records |
| 53 | + run: mise exec uv@0.10.12 python@3.14.5 -- uv run --no-project python signing-handoff/signed-release/verify-record.py |
| 54 | + - name: Attest final signed archive checksums |
| 55 | + id: attest |
| 56 | + uses: actions/attest@1e69f48acb82d1966a394da916b4c1698aa569d6 # v4.2.2 |
| 57 | + with: |
| 58 | + subject-checksums: signing-handoff/signed-release/OpenShell-Windows-0.1.8-SHA256SUMS |
| 59 | + predicate-type: https://nvidia.com/openshell/attestations/windows-signed-package/v1 |
| 60 | + predicate-path: signing-handoff/signed-release/signed-package-predicate.json |
| 61 | + push-to-registry: false |
| 62 | + create-storage-record: false |
| 63 | + - name: Assemble verification artifact |
| 64 | + env: |
| 65 | + BUNDLE_PATH: ${{ steps.attest.outputs.bundle-path }} |
46 | 66 | run: | |
47 | | - mise install --locked uv python |
48 | | - mise exec uv python -- uv run --no-project python signing-handoff/assemble.py |
| 67 | + mkdir verification |
| 68 | + cp signing-handoff/signed-release/OpenShell-Windows-0.1.8-SHA256SUMS verification/ |
| 69 | + cp signing-handoff/signed-release/OpenShell-Windows-0.1.8-validation.json verification/ |
| 70 | + mise exec uv@0.10.12 python@3.14.5 -- uv run --no-project python - <<'PY' |
| 71 | + import json, os |
| 72 | + from pathlib import Path |
| 73 | + bundles = [Path('candidates/github-attestation.sigstore.json'), Path(os.environ['BUNDLE_PATH'])] |
| 74 | + result = '\n'.join(json.dumps(json.loads(p.read_text()), separators=(',', ':')) for p in bundles) |
| 75 | + Path('verification/OpenShell-Windows-0.1.8-attestations.jsonl').write_text(result + '\n') |
| 76 | + PY |
49 | 77 | - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 |
50 | 78 | with: |
51 | | - name: OpenShell-Windows-0.1.8-validated-signing-handoff |
52 | | - path: handoff/ |
| 79 | + name: OpenShell-Windows-0.1.8-signed-package-verification |
| 80 | + path: verification/ |
53 | 81 | if-no-files-found: error |
54 | 82 | retention-days: 30 |
0 commit comments