Elixir and the BEAM for AI systems

Dependency Cooldowns for Every Package Manager (Hex Too)

Dependency cooldown settings for npm, pnpm, Yarn, Bun, uv, pip, Poetry, Cargo, Bundler and Hex, with units and defaults, plus the Hex cooldown bypass CVE.

In this post
  1. What I changed on this site
  2. How the Hex cooldown works
  3. The Hex cooldown bypass (CVE-2026-105668)
  4. The setting in every package manager
  5. What a cooldown does not do
  6. What I’d set today

This site now sets a seven-day dependency cooldown in mix.exs, and CI runs mix hex.audit. Both landed in PR #154 on November 27, 2026. That day the audit found a vulnerable package, and the cooldown held nothing back.

A dependency cooldown, sometimes called a minimum release age, tells your package manager to ignore any version published less than N days ago. The idea is that a bad release gets the most reach in its first days, and a delay lets you skip that stretch. The twelve tools in the table below all have it now. They all name it differently, and they don’t even agree on the unit.

The table for all twelve tools is further down. The Hex part comes first because it’s the one I ran.

What I changed on this site

Before the PR, my local machine ran Hex 2.6.0 with no cooldown set in mix.exs. CI ran mix deps.audit (the mix_audit package) but not mix hex.audit, which is the audit built into Hex.

I ran mix hex.audit by hand while adding the cooldown, and it flagged idna 7.1.0 for EEF-CVE-2026-117678, severity medium. The advisory says punycode labels are decoded before the 63-octet length check, so a long xn-- label causes super-linear CPU use. The same day, mix deps.audit printed “No vulnerabilities found.” I didn’t check why the two disagreed, so I won’t guess. I just know that on that day only one of them told me about it.

The OSV record shows the advisory published on 2026-11-19, with the fix in idna 8.0.0. Hex.pm shows 8.0.0 was published on 2026-11-12.

That fix wasn’t a one-line bump. swoosh 1.29.3, which this site uses for email, required idna >= 6.0.0 and < 8.0.0. The fix needed swoosh 1.30.0, released 2026-11-18. So I ran mix deps.update swoosh idna, and it also moved finch from 0.24.0 to 0.25.0, nimble_options from 1.1.1 to 1.2.0, nimble_pool from 1.1.0 to 1.2.0 and ranch from 2.3.0 to 2.4.0.

With cooldown: "7d" already set, that update held nothing back. Every release it chose was more than seven days old. Afterward mix hex.outdated showed one update still available: sobelow 0.19.0, a dev and test dependency released 2026-11-12. That’s 15 days old, so the cooldown wasn’t holding it. I just hadn’t asked for it.

The final state is hex: [cooldown: "7d"] in mix.exs, a mix hex.audit step in CI right after mix deps.audit, and 661 passing tests.

The two controls did different jobs here. The audit told me what to move. The cooldown would have held back anything published in the last week, and that day there was nothing to hold.

How the Hex cooldown works

Hex 2.5.0 added the cooldown, released 2026-06-29. The dependency policies docs cover the details. You can set it in three places:

# mix.exs, in the project config
hex: [cooldown: "7d"]
# environment variable
export HEX_COOLDOWN=7d

# or user-level config
mix hex.config cooldown 7d

Units are 7d, 2w and 1mo. The default is "0d", which means off. The environment variable wins over mix.exs: with HEX_COOLDOWN=0d set, mix hex.config cooldown on this project prints "0d" instead of "7d". So for one urgent update, HEX_COOLDOWN=0d mix deps.update <pkg> skips the window.

How it behaves:

  • It never touches dependencies already locked in mix.lock. It applies when resolution runs: mix deps.get with changes, mix deps.update, and Mix.install/2.
  • mix hex.outdated is cooldown-aware. It still lists a held-back update, marked (cooldown), so you can see what is available and when it becomes installable.
  • mix hex.audit checks your whole lockfile for advisories and retired releases. Its --policy and --policy-overrides flags, which check the lockfile against an organization dependency policy, need Hex 2.6 or newer.

There’s also a deliberate escape hatch. As shipped in 2.5.0, if the release you had locked was retired or carried a security advisory, the cooldown was lifted for that package, so you could get off the bad version.

The Hex cooldown bypass (CVE-2026-105668)

GHSA-pqhp-5x9x-69h7, also CVE-2026-105668, was published on 2026-10-12. It’s rated High, CVSS v4 7.1. The title is “Hex release-age cooldown is lifted package-wide when the locked release is retired.”

The advisory says that when a locked release is retired or has an advisory, Hex lifts the cooldown “for every version of that package and of every package the locked release depends on.” Retiring a release takes the same package owner permission as publishing one. So an owner, or an attacker who has taken over an owner’s account, could publish a malicious release, retire the release you have locked, and your next mix deps.update would pick the new release no matter how young it was.

The check also went by package name alone, so the bypass covered same-named packages in other repositories. Organization dependency policies were not affected.

It affected Hex >= 2.5.0, < 2.5.2. The fix is 2.5.2, released the same day the advisory was published. Since 2.5.2 a retired locked release no longer lifts the cooldown. A locked release with a security advisory still does, for that package and the direct dependencies of the locked release. The advisory’s workaround, for anyone who couldn’t upgrade, was to enforce the cooldown through an organization dependency policy, or to run mix hex.audit before mix deps.update and not update a package whose locked release was retired until its replacement had been reviewed.

No source I read says this was exploited.

If you run Hex, you want 2.5.2 or later. I’m on 2.6.0, one release behind 2.7.0. This is also a different problem from the hex.pm server compromise on November 23, where the registry itself was attacked, and from the eMudhra CA distrust in October, where bumping castore did nothing for a default Req app.

The setting in every package manager

Here are the twelve I checked, as of 2026-11-27. Check the unit column first. npm counts days, pnpm counts minutes, Bun counts seconds, Cargo wants the string "3 days" and Hex wants "7d". Set 7 in the wrong file and you get a seven-minute cooldown or a seven-second one.

Tool Setting and file Unit On by default?
npm min-release-age in .npmrc days (number) No. Added in 11.10.0 (2026-02-11)
pnpm minimumReleaseAge in pnpm-workspace.yaml minutes Yes since 11.0.0: 1440 (1 day)
Yarn Berry npmMinimalAgeGate in .yarnrc.yml duration string (the docs example is 1w) Yes since 4.15.0: 1d
Bun install.minimumReleaseAge in bunfig.toml seconds; the install docs also take 3d No
uv exclude-newer in pyproject.toml or uv.toml timestamp or duration (1 week, P7D) No
pip --uploaded-prior-to flag or PIP_UPLOADED_PRIOR_TO datetime, or days as P3D No
Poetry solver.min-release-age days No. Added in 2.4.0 (2026-05-03)
Dependabot cooldown in dependabot.yml days Yes since 2026-07-14: 3 days, version updates only
Renovate minimumReleaseAge in renovate.json string like "3 days" No
Bundler bundle config set cooldown 7 days No (opt-in). Added in 4.0.13 (2026-06-03)
Cargo global-min-publish-age under [registry] string like "3 days" No (opt-in)
Hex cooldown in mix.exs, or HEX_COOLDOWN string: 7d, 2w, 1mo No ("0d")

A few of these need more than a table cell.

Cargo is the new one

Rust 1.100, released 2026-11-12, stabilized the Cargo setting. You put it in .cargo/config.toml:

[registry]
global-min-publish-age = "3 days"

When a newer release is being held back, cargo update tells you: “Locking 2 packages to highest compatible version as of min-publish-age.” That message is useful, because a silent cooldown is hard to debug. To override it for one package, the release post gives this:

CARGO_RESOLVER_INCOMPATIBLE_PUBLISH_AGE=allow \
  cargo update clap --precise 4.6.9

Two limits from the same post. Versions that have no pubtime field in the registry index are never held back, and cargo install ignores the minimum publish age. The post also says cooldowns “are not a complete defense on their own.”

The Node tools disagree on defaults

pnpm and Yarn turned this on for everyone. The pnpm 11 release notes say minimumReleaseAge defaults to 1440, one day, and you opt out with minimumReleaseAge: 0. Yarn made 1d the default in 4.15.0, per its release notes. npm and Bun are still off until you set them.

npm has an exclusion list, min-release-age-exclude, which takes names or minimatch globs and arrived in 11.17.0.

Python has three different shapes

uv takes a timestamp or a duration through exclude-newer, and compares it against each file’s upload time. Relative durations like 1 week arrived in uv 0.9.17. Months and years aren’t allowed. pip’s flag arrived in 26.0, and the P3D day-duration form in 26.1, per the pip changelog. Poetry added solver.min-release-age in 2.4.0. pip and Poetry only work against indexes that report upload times. Poetry’s configuration docs say a release with no upload time “is not filtered out,” so on an index that doesn’t report upload times Poetry holds nothing back.

Bots have their own cooldowns

Dependabot’s default is 3 days since the July 14, 2026 changelog, and it doesn’t apply to security updates. Renovate’s minimumReleaseAge is off by default, and its docs say “Security updates bypass any minimumReleaseAge checks.”

Both skip security updates on purpose. If there’s a fix for a known vulnerability, you want it today. The Hex bypass came from the same kind of exception: whoever controlled a release could also trigger the path that skips the cooldown.

What a cooldown does not do

It doesn’t make a bad release safe. It only keeps you out of the first days after publishing. A package that stays malicious for three weeks gets through a seven-day cooldown just fine.

It doesn’t help with what’s already locked. Hex says so directly: the cooldown never touches locked deps. If a malicious version got into your lockfile last month, the setting does nothing about it, which is why mix hex.audit against the whole lockfile matters.

It can also delay a security patch. A cooldown that delays a fix by a week is a bad trade when the fix is for something being exploited. npm has an exclusion list, Cargo has an override, Hex lifts the cooldown for a locked release with an advisory, and Dependabot and Renovate skip it for security updates. CVE-2026-105668 was a bug in one of those exemptions.

And the setting only covers installs that read it. hex: [cooldown: "7d"] in mix.exs travels with the repo, so it applies on my laptop and in CI. HEX_COOLDOWN and mix hex.config apply only on the machine where you set them. And cargo install ignores Cargo’s setting, so a tool you install globally skips the check.

What I’d set today

If you have no cooldown anywhere, pick the tool you use most and add one. Seven days is a reasonable starting number, and it’s what I set for Hex. Then check the unit, because the cost of getting it wrong is silent. For the two that already default to one day, pnpm and Yarn, consider whether one day is enough for your risk.

Pair it with an audit that reads the lockfile, run in CI. On this site, the audit found something the other tool didn’t, and the cooldown had nothing to hold back.

If you want someone to look at your whole dependency and CI posture, not one setting at a time, that’s part of what I do in consulting.