Repository navigation
fix: match a promoted image to its release by digest - #79
Merged
Merged
Conversation
A stable release promotes the image built on dev, so its tag names a later commit than the one the image's signed bill of materials names. The release lookup by commit found no release for every promoted image and skipped the release-file check. The guide now finds the release whose tag names the same image digest, verifies the release file's signature and compares its packages and versions with the list signed into the image. The self-test derives its cases from live releases.
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
examples/images/verify.shand its copy indocs/images.md: a promoted stable release's tag names a later commit than the image it publishes, so the lookup by the image's source commit found no release and skipped the release-file check. The lines now pick the stable release whose tag names the same image digest, verify the release file's signature, and compare its package names and versions with the list signed into the image. Metadata a scan rewrites (date, document name, scanner version, references) is not compared.tests/images/verify.shderives every case from live releases: a promoted release matched to its own file, an older major never matched with the newest release, a moved tag, a restored file, another release's file refused, a re-scan accepted and a changed package version refused.This turns the Examples
imagesjob green again; it has been red on main since 2026-10-10.Testing
bash tests/images/verify.shagainst live GHCR and Sigstore: 17 checks pass. This host has no Docker, so a stand-in answereddocker buildx imagetools inspectfrom the registry API; CI runs the real one.scripts/snippets.py --check, shellcheck and shfmt are clean.