| 1 | name: Verify Windows cloud signing without a release |
| 2 | on: |
| 3 | workflow_dispatch: |
| 4 | inputs: |
| 5 | mode: |
| 6 | description: Sign a disposable probe, or only read credential information without signing |
| 7 | type: choice |
| 8 | options: [sign, credential-info] |
| 9 | default: sign |
| 10 | permissions: |
| 11 | contents: read |
| 12 | concurrency: |
| 13 | group: cage-windows-signing-check |
| 14 | cancel-in-progress: false |
| 15 | jobs: |
| 16 | verify: |
| 17 | if: github.repository == 'Lee-xeo/Claude-Cage' && github.ref == 'refs/heads/main' |
| 18 | runs-on: windows-2025 |
| 19 | environment: cage-release |
| 20 | timeout-minutes: 20 |
| 21 | steps: |
| 22 | - uses: actions/checkout@v4 |
| 23 | with: |
| 24 | ref: ${{ github.sha }} |
| 25 | persist-credentials: false |
| 26 | - uses: actions/setup-node@v4 |
| 27 | with: |
| 28 | node-version: 24 |
| 29 | - uses: actions/setup-java@v4 |
| 30 | with: |
| 31 | distribution: temurin |
| 32 | java-version: '21' |
| 33 | - name: Run the selected signing verification or read-only diagnosis |
| 34 | shell: pwsh |
| 35 | env: |
| 36 | CAGE_WINDOWS_SIGNING_PROVIDER: ${{ vars.CAGE_WINDOWS_SIGNING_PROVIDER }} |
| 37 | CAGE_ESIGNER_USERNAME: ${{ secrets.CAGE_ESIGNER_USERNAME }} |
| 38 | CAGE_ESIGNER_PASSWORD: ${{ secrets.CAGE_ESIGNER_PASSWORD }} |
| 39 | CAGE_ESIGNER_CREDENTIAL_ID: ${{ secrets.CAGE_ESIGNER_CREDENTIAL_ID }} |
| 40 | CAGE_ESIGNER_CERTIFICATE_SERIAL: ${{ vars.CAGE_ESIGNER_CERTIFICATE_SERIAL }} |
| 41 | CAGE_ESIGNER_TOTP_SECRET: ${{ secrets.CAGE_ESIGNER_TOTP_SECRET }} |
| 42 | CAGE_SIGNING_CHECK_MODE: ${{ inputs.mode }} |
| 43 | run: ./scripts/check-windows-signing.ps1 -Mode $env:CAGE_SIGNING_CHECK_MODE |
| 44 | - name: Preserve verification facts only |
| 45 | if: always() |
| 46 | uses: actions/upload-artifact@v4 |
| 47 | with: |
| 48 | name: windows-signing-verification-${{ github.run_id }} |
| 49 | path: _output/signing-check/result.json |
| 50 | if-no-files-found: ignore |
| 51 | retention-days: 14 |