fix(pins): see what a Docker action executes, not only what it uses - #185
Merged
Conversation
The corrected walk collected `uses:` references at any nesting. A Docker action does not have one -- it names what it runs under `runs.image`. So ossf/scorecard-action, pinned here by commit SHA, ended its action.yaml with `image: "docker://ghcr.io/ossf/scorecard-action:v2.4.4"`, a tag, and the walk extracted nothing from it at all. Reported from a consuming repository as #173, which named two cases. Once the walk could see the shape it found five: Scorecard across three workflows, Checkov, commitlint, and both ClusterFuzzLite actions on a floating v1. None can be pinned from here without forking the action, so catalog/action-images.yml records each with what a consumer is exposed to. Recording is not accepting: it is the shape KNOWN_UNTAGGED already uses, and for the same reason -- an advisory tier that is permanently red is an advisory nobody reads. The contract runs both ways, so an undeclared tag-addressed image is a finding and a recorded one the tree no longer reaches unpinned is a finding too. An `image:` naming a Dockerfile is built from the action's own source at the pinned commit and introduces nothing new.
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.
Closes the gap #173 reported. Filed by an agent auditing
macos-ubuntu-bootstrap'sconsumption of these reusables — the cause was here, and it was in code I had just
rewritten.
The gap
The corrected walk (#179) collects
uses:references from the parsed document at anynesting. A Docker action does not have one. It names what it executes under
runs.image:Verified against my own parser before fixing it:
The action is pinned by commit SHA. The image is addressed by tag. Retagging it
changes what every consumer executes while every pin in this tree still looks
immutable.
Five, not two
The issue named Scorecard and one other. With the shape visible, the walk finds:
ossf/scorecard-actionghcr.io/ossf/scorecard-action:v2.4.4bridgecrewio/checkov-actionghcr.io/bridgecrewio/checkov:3.3.9iac-scan.ymlwagoid/commitlint-github-actionwagoid/commitlint-github-action:6.2.1pr-hygiene.ymlgoogle/clusterfuzzlite/…/build_fuzzersgcr.io/oss-fuzz-base/…-build-fuzzers:v1clusterfuzzlite.ymlgoogle/clusterfuzzlite/…/run_fuzzersgcr.io/oss-fuzz-base/…-run-fuzzers:v1clusterfuzzlite.ymlTwo ClusterFuzzLite entries are on a floating major — the weakest of the set.
Recorded, not accepted
None can be pinned from here without forking the action.
catalog/action-images.ymlrecords each with the workflows that reach it and what a consumer is exposed to.
This is deliberately the shape
KNOWN_UNTAGGEDalready uses incheck_release_ledger.py, and for the same stated reason: an advisory tier that ispermanently red is an advisory nobody reads. Recording keeps the exposure reviewable
in the catalog instead of invisible in a sweep everyone learns to skip.
The contract runs both ways:
So the list cannot quietly stop describing the graph, in either direction.
Left alone deliberately
An
image:naming a Dockerfile is built from the action's own source at the pinnedcommit, so it introduces nothing new. Covered by a self-test.
Verification
digest-addressed and Dockerfile-built images
validate_all— all tiers OK withGH_TOKEN·actionlint— clean