Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 19 additions & 4 deletions .github/workflows/reusable-release-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -249,12 +249,27 @@ jobs:
if [ "${DH_PUSH}" = "true" ]; then
refs="${refs} ${DH_IMAGE}@${DIGEST}"
fi
# Docker Hub's referrers index is eventually consistent: a signature
# pushed <1 s ago can read as "no signatures found" (#595). Retry
# each ref, 6 attempts over ~59 s; the gate stays hard.
for ref in ${refs}; do
echo "Verifying ${ref}"
cosign verify \
--certificate-oidc-issuer https://token.actions.githubusercontent.com \
--certificate-identity-regexp '^https://github\.com/mechubsec/mecmcp/\.github/workflows/reusable-release-image\.yml@' \
"${ref}" > /dev/null
attempt=1
for delay in 2 4 8 15 30 0; do
if cosign verify \
--certificate-oidc-issuer https://token.actions.githubusercontent.com \
--certificate-identity-regexp '^https://github\.com/mechubsec/mecmcp/\.github/workflows/reusable-release-image\.yml@' \
"${ref}" > /dev/null; then
break
fi
if [ "${delay}" -eq 0 ]; then
echo "::error::cosign verify failed for ${ref} after ${attempt} attempts"
exit 1
fi
echo "cosign verify attempt ${attempt}/6 failed for ${ref}; retrying in ${delay}s"
sleep "${delay}"
attempt=$((attempt + 1))
done
done
env:
GHCR_IMAGE: ${{ inputs.image }}
Expand Down
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
>
> Entries from 0.21.0 onward should be written by hand at release time.

## [Unreleased]

### Fixed

- **ci**: `reusable-release-image.yml` `Verify signatures (hard gate)` now retries each
ref's `cosign verify` (6 attempts, backoff 2/4/8/15/30 s, about 59 s) before failing.
Docker Hub's referrers index is eventually consistent, so verify right after signing could
report `no signatures found` and fail the release (seen on rustsdcmcp v0.6.0). The gate
stays hard: a signature that never appears still fails the job with cosign's last error.
Consumers pin this workflow by SHA, so they only get the fix after bumping that pin (#595).

## [0.31.1] - 2026-10-29

### Fixed
Expand Down
Loading