fix(release-sign): use .sigstore extension for scorecard detection#12
Merged
mreuvekamp merged 1 commit intomainfrom May 8, 2026
Merged
fix(release-sign): use .sigstore extension for scorecard detection#12mreuvekamp merged 1 commit intomainfrom
mreuvekamp merged 1 commit intomainfrom
Conversation
OpenSSF Scorecard's signed-releases probe matches assets by suffix
{.asc, .minisig, .sig, .sign, .sigstore, .sigstore.json}. Cosign v3's
--bundle output is sigstore-bundle JSON, but the .bundle extension we
chose isn't in the allowlist, so v0.2.0 scored 0/10 despite being
correctly signed.
Renames signing output to .sigstore (content unchanged) so a fresh
scorecard scan recognizes future releases as signed. v0.2.0 assets
need a separate retrofit (rename existing .bundle -> .sigstore on the
release).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Collaborator
Author
Retrofit-script v0.2.0Na merge uitvoeren zodat bestaande release ook in scorecard's 5-release lookback als getekend telt. Inhoud assets blijft identiek — alleen filename verandert van set -euo pipefail
TAG=v0.2.0
REPO=RijksICTGilde/hackathon-claude-code
ARCHIVE=hackathon-claude-code-${TAG}
WORK=$(mktemp -d)
trap 'rm -rf "$WORK"' EXIT
cd "$WORK"
# 1. Download bestaande bundles
gh release download "$TAG" --repo "$REPO" \
--pattern "${ARCHIVE}.tar.gz.bundle" \
--pattern "${ARCHIVE}.tar.gz.sha256.bundle"
# 2. Hernoem (content unchanged)
mv "${ARCHIVE}.tar.gz.bundle" "${ARCHIVE}.tar.gz.sigstore"
mv "${ARCHIVE}.tar.gz.sha256.bundle" "${ARCHIVE}.tar.gz.sha256.sigstore"
# 3. Sanity-check: verifieer voor upload dat nieuwe filename nog
# geldige cosign-bundle is (zelfde IDENTITY_REGEXP als workflow).
gh release download "$TAG" --repo "$REPO" \
--pattern "${ARCHIVE}.tar.gz" \
--pattern "${ARCHIVE}.tar.gz.sha256"
IDENTITY_REGEX='^https://github\.com/RijksICTGilde/hackathon-claude-code/\.github/workflows/release-sign\.yml@refs/(heads/main|tags/v[0-9A-Za-z._+-]+)$'
ISSUER='https://token.actions.githubusercontent.com'
cosign verify-blob \
--bundle "${ARCHIVE}.tar.gz.sigstore" \
--certificate-identity-regexp "$IDENTITY_REGEX" \
--certificate-oidc-issuer "$ISSUER" \
"${ARCHIVE}.tar.gz"
cosign verify-blob \
--bundle "${ARCHIVE}.tar.gz.sha256.sigstore" \
--certificate-identity-regexp "$IDENTITY_REGEX" \
--certificate-oidc-issuer "$ISSUER" \
"${ARCHIVE}.tar.gz.sha256"
# 4. Upload nieuwe namen + delete oude. Volgorde: eerst upload, dan
# delete — zo is er geen window waarin de release onbeschermd is.
gh release upload "$TAG" --repo "$REPO" \
"${ARCHIVE}.tar.gz.sigstore" \
"${ARCHIVE}.tar.gz.sha256.sigstore"
gh release delete-asset "$TAG" "${ARCHIVE}.tar.gz.bundle" --repo "$REPO" --yes
gh release delete-asset "$TAG" "${ARCHIVE}.tar.gz.sha256.bundle" --repo "$REPO" --yes
# 5. Verifieer eindstaat
gh release view "$TAG" --repo "$REPO" --json assets --jq '.assets[].name'Verwachte assets na retrofit:
Daarna scorecard handmatig triggeren of wachten op weekly run — Signed-Releases moet ≥8/10 worden. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
.bundlenaar.sigstorezodat OpenSSF Scorecard de assets als getekend detecteert.Achtergrond
Scorecard scan op commit
e1cd5d8(na PR #11) gaf nog steedsSigned-Releases: 0/10:Reden: scorecard's
releasesAreSignedprobe matcht assets op vaste suffix-allowlist:.bundlezit daar niet in. PR #11 produceerde correct ondertekende cosign v3 sigstore-bundle JSON, alleen onder verkeerde extensie. Inhoud is ongewijzigd, alleen filename.Vervolg
v0.2.0release-assets staan nog onder.bundle. Na merge volgt aparte retrofit (download.bundle→ upload als.sigstore→ delete.bundle) zodat de bestaande release ook in scorecard's lookback (laatste 5 releases) groen wordt.Test plan
.sigstoreassets.bundlehernoemd naar.sigstoreop release🤖 Generated with Claude Code