rust-lang / rust-lang/rustc_codegen_cranelift

Discussion: Mitigating supply chain & CI attacks via delayed dependency updates

Open
#1,653 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
2.1k
Forks
157
Avg merge
1d 19h
Merged PRs (30d)
3

Description

Supply chain attacks (like those recently seen in npm) and AI-assisted CI cache poisoning are escalating. In Rust, a compromised "day-zero" dependency could execute malicious build.rs scripts or proc-macros during an automated PR build to poison shared CI caches or exfiltrate runner tokens.

To be proactive, a deliberate "cool-down" period(like 7 days) before bumping dependency versions in Cargo.toml. Waiting a week gives the wider community and automated security scanners time to detect and yank compromised packages. This keeps cg_clif and our CI infra out of the immediate blast radius.

Doubt:

How would a 1 week delay impact the workflow for pulling in crucial cranelift fixes or keeping up with rustc API changes? Would it make sense to apply this 7 day rule strictly to third-party transitive dependencies, while exempting high-trust core dependencies (like cranelift itself)?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing Cargo.toml and the repository's CI configuration, focusing on how dependency updates and automated pull-request builds are handled. Compare the proposed seven-day delay for third-party dependencies with exemptions for cranelift and rustc-related updates. Done would require an agreed policy and a clearly specified implementation scope, which this discussion does not yet define.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
build-system, ci-cd, security
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.