security: pin third-party GitHub Actions to commit SHAs + least-privilege permissions#177
Merged
Merged
Conversation
…lege permissions Pin all third-party actions to full 40-char commit SHAs (version comments retained) and add a top-level least-privilege 'permissions: contents: read' block to pure-CI workflows. dtolnay/rust-toolchain gains an explicit 'toolchain: stable' input so the SHA pin preserves channel selection. From the 2026-06-22 workspace GitHub Actions security audit. Assisted-With: Claude Opus 4.8 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #177 +/- ##
=====================================
Coverage 2.29% 2.29%
=====================================
Files 4 4
Lines 131 131
=====================================
Hits 3 3
Misses 128 128 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Pin msgpack-python>=1.2.1 (GHSA-6v7p-g79w-8964) in the pip-audit security block and regenerate pixi.lock. pip-audit now reports no known vulnerabilities. Assisted-With: Claude Opus 4.8 <noreply@anthropic.com>
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.
What
Supply-chain hardening of GitHub Actions workflows:
# versioncomment so the intended release stays readable.permissions: contents: readblock to pure-CI workflows that had no top-level permissions and perform no privileged operations.First-party
actions/*andgithub/*are intentionally left tag-pinned per group convention.Why
Supply-chain hardening per group convention (pin third-party Actions to SHA hashes where possible; least-privilege tokens). From the 2026-06-22 workspace GitHub Actions security audit.
Pins applied
prefix-dev/setup-pixi(4x in test_and_deploy, 1x in update-lockfiles)5185adfbffb4bd703da3010310260805d89ebb11codecov/codecov-actionfb8b3582c8e4def4969c97caa2f19720cb33a72fneutrons/conda-actions/pkg-installbba9ca89d48d9ae846db9650cc63fde736340b3dneutrons/conda-actions/pkg-verifybba9ca89d48d9ae846db9650cc63fde736340b3dneutrons/conda-actions/grypebba9ca89d48d9ae846db9650cc63fde736340b3dneutrons/conda-actions/publishbba9ca89d48d9ae846db9650cc63fde736340b3dneutrons/conda-actions/pkg-removebba9ca89d48d9ae846db9650cc63fde736340b3dpypa/gh-action-pypi-publishcef221092ed1bacb1cc03d23a2d87d1d172e277bpeter-evans/create-pull-request5f6978faf089d4d20b00c7766989d076bb2fc7f1Permissions
copilot-setup-steps.yml: added top-levelpermissions: contents: read(no privileged operations, no pre-existing top-level block).test_and_deploy.yaml: no top-level permissions change — it usesid-token: write(trusted PyPI publishing) andpypa/gh-action-pypi-publish; existing per-job permissions are preserved untouched.update-lockfiles.yml: no permissions change — already has a top-levelpermissions:block (contents: write,pull-requests: write) forpeter-evans/create-pull-request.Notes
dtolnay/rust-toolchainandtaiki-e/install-actiondo not appear in this repo, so their special-case handling did not apply.🤖 Assisted with Claude Code