By Hamza Faisal

Hackers broke into Hex.pm, the package registry that supplies code libraries to Elixir and Erlang developers around the world, exploiting a critical flaw that had sat quietly in the service's code for more than a decade. The attackers ran commands on six production servers before the maintainers shut the attack down in about fifteen minutes — but they may have walked away with users' account data.

Hex.pm is the default registry behind mix deps.get, rebar3 and gleam add, the tools developers use to fetch their software's building blocks. A breach of the registry is a supply-chain incident: whatever flows through it ends up inside countless applications.

A ten-year-old flaw, exploited in thirteen minutes

The attack began on Monday, November 23, at 18:16 UTC. Over the next thirteen minutes the attackers sent 69 malicious requests from two addresses, and exploit-created files appeared on six web servers — in one case three milliseconds after a request arrived. By 18:30, every server had been replaced with a patched build.

The flaw, now tracked as CVE-2026-129514, carries the maximum CVSS severity score of 10.0. Hex.pm accepted some API requests in Erlang's own term format, and its body parser decoded those payloads with a function from the Plug.Crypto library that was supposed to be safe. The decoder blocked most dangerous terms — but it still let through maps carrying a special struct marker. Chained through the Ecto and DBConnection libraries, that gap turned into full remote code execution on the server.

The flaw had been there since February 23, 2016, when a safety check was removed from the code. There is no evidence it was exploited before Monday. The attackers appear to have spent the previous week downloading Hex.pm's dependencies, apparently building a local copy to test against.

No packages tampered with — but account data may have been read

According to the Hex.pm team, no package was modified. The 23 releases published during the attack all match the audit log, no older release was changed, and the files written to package storage that evening match the database records. The Hex client on developers' own machines was not affected — only the hosted service.

The bad news is that database reads are not logged, so the team cannot rule out that the attacker read account data, including email addresses, password hashes, API key hashes, two-factor authentication secrets, sessions and audit logs. The maintainers reported a personal data breach to IMY, the Swedish data protection authority, that night, and notified the US Cybersecurity and Infrastructure Security Agency (CISA) the same evening.

Because the attacker's commands could read server credentials, the team replaced them all — storage, content delivery, email and database credentials, plus the keys that sign sessions and access tokens. That logged every Hex.pm user out. One credential has not yet been replaced: the registry signing key. A new signing system that supports key rotation is being built, with new client releases expected in the coming days.

What Hex.pm users should do now

Every Hex.pm account holder should change their password and reset two-factor authentication, setting up a new authenticator entry and storing the new recovery codes, and log back in with mix hex.user auth or, for Erlang projects, rebar3 hex user auth. Until the new client ships, developers should fetch packages only from repo.hex.pm and avoid third-party mirrors.

Users should also be wary of phishing: with email addresses possibly exposed, messages claiming to come from Hex should be checked carefully, and links should lead to hex.pm itself. The attacker behind the breach remains unknown.