Apply pinning to GitHub Actions#121
Conversation
📝 WalkthroughWalkthroughThis PR hardens GitHub Actions security by introducing automated dependency pinning, explicit job-level permissions, and security validation. It adds Dependabot configuration, pins action commit SHAs in the CI workflow, and deploys Zizmor for continuous validation of secure action usage. ChangesCI Security Hardening
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool. What Enabling Code Scanning Means:
For more information about GitHub Code Scanning, check out the documentation. |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.github/workflows/ci.yaml:
- Around line 19-20: Change the two mutable action refs to immutable commit
SHAs: replace uses: DeterminateSystems/determinate-nix-action@main and uses:
DeterminateSystems/flakehub-cache-action@main with pinned refs that include the
commit SHA (e.g., DeterminateSystems/determinate-nix-action@<commit-sha> and
DeterminateSystems/flakehub-cache-action@<commit-sha>); update the workflow to
reference the specific commit SHAs for these actions so the CI uses fixed
immutable versions and cannot be mutated via branch updates.
In @.github/zizmor.yml:
- Line 5: The namespace policy for DeterminateSystems/* currently uses the
non-hash pinning value "ref-pin", causing symbolic refs like `@main` to be
allowed; change the policy value to "ref-pin: hash" for DeterminateSystems/* so
zizmor requires commit-SHA-only pins (update the DeterminateSystems/* entry to
use ref-pin: hash).
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: d157dd8d-ba77-4206-9234-938f61b986d4
📒 Files selected for processing (4)
.github/dependabot.yml.github/workflows/ci.yaml.github/workflows/zizmor.yml.github/zizmor.yml
Summary by CodeRabbit