Skip to content

chore: pin GitHub Actions to commit SHAs#207

Merged
gregorydemay merged 1 commit into
mainfrom
chore/pin-actions-to-sha
May 11, 2026
Merged

chore: pin GitHub Actions to commit SHAs#207
gregorydemay merged 1 commit into
mainfrom
chore/pin-actions-to-sha

Conversation

@slawomirbabicz
Copy link
Copy Markdown
Contributor

Pin GitHub Actions to commit SHAs

GitHub Actions referenced by tag (e.g. actions/checkout@v4) use a mutable pointer — the tag owner can move it to a different commit at any time, including a malicious one. This is the attack vector used in the tj-actions/changed-files incident (CVE-2025-30066).

Pinning to a full 40-character commit SHA makes the reference immutable. The # tag comment preserves human readability so reviewers can tell which version is pinned.

Important: a SHA can also originate from a forked repository. A malicious actor can fork an action, push a compromised commit to the fork, and the SHA will resolve — but it won't exist in the upstream canonical repo. Each SHA in this PR was verified against the action's canonical repository (not a fork).

Changes

  • actions/checkout@v3 -> actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0

  • actions/cache@v3 -> actions/cache@6f8efc29b200d32929f49075959781ed54ec270c # v3.5.0

Files modified

  • .github/workflows/ci.yml

@gregorydemay gregorydemay merged commit 5d670e5 into main May 11, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants