chore: Pin actions-rust-lang/setup-rust-toolchain to SHA digest - #92681
chore: Pin actions-rust-lang/setup-rust-toolchain to SHA digest#92681erezrokah wants to merge 1 commit into
Conversation
|
Allow CI Workflow Run
Note: this should only be enabled once the PR is ready to go and can only be enabled by a maintainer |
There was a problem hiding this comment.
Pull request overview
Pins the external GitHub Action used by the repo’s internal composite “Rust Setup” action to an immutable commit SHA to reduce supply-chain risk from mutable tags.
Changes:
- Update
actions-rust-lang/setup-rust-toolchainusage from@v1to a specific commit SHA (with a# v1reference comment).
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Doing this in #93609 Thank you for pointing this out! |
|
Thanks for the review @bgw, I highly recommend setting up renovate to manage the sha pinning and provide visibility into updates (hard to understand changes between versions when using sha pinning). Finally, if you don't want to install an additional GitHub App into the Vercel org, you can self host (e.g. via the GitHub Action https://github.com/renovatebot/github-action). P.S. I don't work for renovate or anything like that, just it has been super helpful for us to tighten our supply chain attack surface |
Pin
actions-rust-lang/setup-rust-toolchainfrom mutable tag@v1to immutable SHA@150fca883cd4034361b621bd4e6a9d34e5143606in.github/actions/setup-rust/action.yml, preventing supply chain attacks via tag hijacking. This was missed by #92016 which pinned 19 other actions.Recommendations
.github/workflows/build_and_deploy.yml:385usescurl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh. Consider replacing with a pinned install method when one becomes available..github/workflows/pull_request_stats.yml:122runsnpm installin.github/actions/next-stats-action/which has nopackage-lock.json. Consider committing a lockfile and switching tonpm ci.