Latest

Cybersecurity

Cargo quarantine in Rust 1.100, a wait for software

Rust 1.100 stabilizes the minimum publish age in Cargo: it delays versions recently uploaded to crates.io. By default it is 0, so it has to be enabled.

Cargo quarantine in Rust 1.100, a wait for software
Cargo quarantine in Rust 1.100, a wait for software

At 07:15 UTC on August 20, 2026, the Rust security team received an alert: the `proc-macro1` crate, recently uploaded to crates.io, was downloading a malicious payload from its build script. `arrayref`, a dependency with years of history, had just published a version that depended on it and had yanked the previous ones. The poisoned version stayed on the registry for 86 minutes. `internment` lasted 90 and `append-only-vec`, 107. None reached two hours, but any `cargo update` launched in that window could have compiled the attacker's code without the developer touching a single line.

Rust 1.100, arriving on November 12, brings the project's answer to that attack pattern. Cargo will be able to refuse to use versions that are too young, with a setting called minimum publish age and the key `registry.global-min-publish-age`. The default value is `»0″`, so updating the compiler protects against nothing on its own: someone has to write a number in the project configuration. Today the feature is in beta: the Cargo 1.100 changelog dates it to November 12, when it hits the stable channel.

A time window does not scan code or certify that a package is safe. It buys hours for automated analyzers and the maintainers themselves to look at a version before half the ecosystem adopts it. The price is symmetrical and appears at the worst moment, because the patch that fixes a vulnerability is also a freshly published version.

A third-party account and two hours of margin

The official account is on the Rust security response team blog, signed by Manish Goregaokar. The team does not accuse the author of `arrayref` of acting maliciously, though it does maintain that his computer or his credentials were compromised: the account ended up publishing a version that pulled in the malicious package and marking the legitimate versions as yanked. In addition to `proc-macro1`, `proc-macro-en`, `aovine`, `arone`, `aronenao` and `tinymember` were deleted, and the account was blocked as a precaution.

Crate Version Published (UTC) Yanked (UTC) Minutes online
`arrayref` 0.3.10 07:15:00 08:41:40 86
`internment` 0.8.7 07:34:07 09:04:11 90
`append-only-vec` 0.1.9 07:37:49 09:25:24 107

The detail that turns this incident into a design argument is the yank of the good versions, that is, the withdrawal that blocks new installs but leaves intact projects that had already pinned them. With the previous ones marked as yanked and the poisoned one available, a resolver that only prefers the old ends up falling into the trap by elimination. That is why the mechanism Cargo is introducing is not a soft preference but a prohibition that can end in a resolution error, and that nuance separates a useful measure from an ornament. The initial discovery was by the firm Nextron Systems, which alerted the Rust team.

What exactly is enabled on November 12?

The entry in the Cargo changelog is explicit: the minimum publish age settings are stabilized, and when `registry.global-min-publish-age` is defined the resolver ignores versions published more recently than that window, unless they are already in `Cargo.lock`. The proposal began as RFC 3923, the stabilization PR #17335 was merged on August 28 and the tracking issue had been open since May 18, three months before the attack.

Setting Default What it does
`registry.global-min-publish-age` `»0″` Global minimum age, in numbers with units (seconds, minutes, hours, days, weeks or months)
`registries.<name>.min-publish-age` Inherits the global value Per-registry exception, useful for a trusted internal mirror
`resolver.incompatible-publish-age` `»deny»` `deny` excludes what is too new; `allow` disables the check

The scope has gaps worth knowing before relying on it. The check can only be applied where there is a publication timestamp, so git dependencies, local paths and registries that do not store that date are left out. In `cargo install` the minimum age does apply, although the environment variable that disables it does not work there, because the resolver table does not intervene in that path. And the lockfile rules: a version already recorded in `Cargo.lock` is kept even if it is younger than the window.

There is even a naming debate that helps explain the intent. The RFC discards the English word cooldown because it usually describes a rate limiter, and chooses minimum publish age because it speaks of maturity. The press and half the technical world have gone back to the shortcut, and in Spanish we have translated it as quarantine, but no Cargo option is called that.

Why does a window of hours do any good?

The August 20 attack lasted between 86 and 107 minutes, a ridiculous margin for reading a diff and enough for an automated process to compile it. That is the gap the window closes: it does not prevent malicious publication, but it keeps consumers away from the first hours, which are the only ones in which the attacker has an advantage. The RFC itself frames it as a race between automated scanners, human reviewers and the reaction of the legitimate maintainer.

That margin does not depend on the attacker, but on how many people have already updated. A week of waiting does not shield the entire ecosystem, but it keeps whoever configures it in their project away from the well.

The second part of the argument is subtler and explains the harshness of the default value. If Cargo were to merely deprioritize the new and accept it as a last resort, the attacker could publish the bad version and yank the good ones to force that fallback. With `deny` the resolver refuses and returns an error, so the project breaks visibly instead of silently compiling something poisoned. The diagnostics also say which version was skipped and how many days old it is.

The side effect is counterintuitive for a security change. The less widely adopted a version is, the cheaper it is to yank later, because fewer lockfiles have pinned it. The RFC sums it up without embellishment: the practical window for a yank is set by adoption, not by the calendar. Waiting a few days reduces the damage of a flaw and also that of a late yank.

What you pay for arriving late on purpose

The price is acknowledged in the document itself. Any fix is also a new version and is also subject to the minimum age, so the team that needs the patch today has to bypass its own policy with an environment variable and a `cargo update –precise`. Once recorded in the lockfile, that version stays there for subsequent resolutions. It is a manual decision, taken at the worst possible moment: with a security alert open and the clock running.

The tension with vulnerability advisories is real, and it is not Cargo's fault. RUSTSEC bulletins point to the version that fixes the flaw, and that version, freshly published, is exactly what a seven-day window leaves out.

Urgent patches are not negotiated with a calendar. The most recent case is rustup 1.29.2, published on October 20, which updated `rustls-webpki` and `webpki-root-certs` to cover the flaw in the eMudhra intermediate certificates. That kind of urgency admits no waiting.

The RFC acknowledges the underlying objection and calls it its biggest drawback: if everyone waits, problems take longer to be discovered. Its answer is that there will be a spread of values and that some projects will test new versions in continuous integration.

An ecosystem learning to decide with the clock

What is interesting about the change is not the configuration line, but that it turns dependency selection into a written policy shared by the team. Until now that decision lived in the head of whoever launched the update or in the bot that proposed it; from November 12 it can be in a file, with a number the team discusses and reviews.

The campaign that the crates.io team described on September 17, with fake job offers and video calls to compromise maintainer accounts, pushes in the same direction: yesterday's legitimate package is tomorrow's entry point. The slopsquatting guide we published on October 17 covers the other half of the problem, the one about the name that looks too much like the good one.

One question remains that no default value resolves, and that is how long it is worth waiting. Three days hold almost nothing back, thirty freeze the team in an ecosystem that publishes daily, and seven have been the example Rust put on the table. The sensible answer depends on whether your code moves money or just paints an interface, and on whether you have someone watching the advisories the same day they come out.

José Maldonado

Author

José Maldonado

Activist and blogger on technology, free software and blockchain.

The latest
From Huang to Botín, from Zara to Byron: corporate responsibility in global capitalism

Keep reading