ci: pin actions to commit SHAs - #21
Conversation
Tags are mutable. actions/checkout@v4 resolves to whatever the v4 tag points at today, so a compromised or repointed tag changes what runs in a workflow that signs and publishes release artifacts. Pin all four actions to full commit SHAs with the version in a trailing comment, so sha_pinning_required can be turned on for the repository. Same guarantee the immutable releases work applies to the outputs, applied to the build inputs. actions/checkout 11d5960 (v4) actions/setup-go 40f1582 (v5) goreleaser/goreleaser-action e435ccd (v6) actions/attest-build-provenance e8998f9 (v2)
|
Warning Review limit reached
Next review available in: 50 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Tags are mutable.
actions/checkout@v4resolves to whatever thev4tag points at today — a repointed or compromised tag silently changes what runs in a workflow that signs and publishes release artifacts.Pins all four actions to full commit SHAs so
sha_pinning_requiredcan be enabled for the repository. Same guarantee the immutable-releases work gives the outputs, applied to the build inputs.actions/checkout11d5960a326750d5838078e36cf38b85af677262v4actions/setup-go40f1582b2485089dde7abd97c1529aa768e1baffv5goreleaser/goreleaser-actione435ccd777264be153ace6237001ef4d979d3a7av6actions/attest-build-provenancee8998f949152b193b063cb0ec769d69d929409bev2Version stays in a trailing comment so the file is still readable.
Context — why the tag builds were failing
Unrelated to the workflow syntax. The repo's Actions policy had been set to
local_only, which blocks every external action includingactions/checkout. Every run since came backstartup_failurewith no jobs and no logs; GitHub only surfaces the reason as a run annotation, not through the API.Policy is now
selected:{"github_owned_allowed": true, "verified_allowed": false, "patterns_allowed": ["goreleaser/goreleaser-action@*"]}GitHub-owned actions plus goreleaser, everything else still blocked. The SHA-pinned refs still match that pattern.
sha_pinning_requiredgets enabled after this merges — turning it on while the workflow still used tags would break pushes the same way.Verification
actionlintexit 0uses:lines resolve to 40-char SHAsFull path still needs a tag push. Immutability remains off until that passes.
🤖 Generated with Claude Code