Hex Data Breach Risk After Server Attack

Hex package manager discloses potential data breach after server compromise

The Hex data breach risk emerged after an attacker exploited hex.pm on 23 November 2026. The unauthorised party used a critical server-side vulnerability to execute operating system commands on six web servers.

Hex contained the attack within minutes and found no evidence that packages were altered. However, the service does not log database reads, meaning investigators cannot exclude access to account details, credentials and security secrets.

What happened in the Hex data breach incident

The incident involved hex.pm, the package repository used by developers working with ecosystems including Elixir, Phoenix and Gleam. Hex first disclosed the attack publicly on 24 November 2026 in an incident report describing unauthorised command execution the previous day.

Between 18:16 and 18:29 UTC on 23 November, the attacker sent 69 malicious requests to hex.pm. Those requests successfully caused commands to run on six web servers under the user account associated with the BEAM virtual machine process.

Hex added a firewall rule at 18:27. The rule became effective between approximately 18:30 and 18:33, while every server was replaced with a patched build between 18:30 and 18:31.

The vulnerability is tracked as CVE-2026-129514 and carries the maximum CVSS severity score of 10.0. Confirmed exploitation makes the server vulnerability more than a theoretical software weakness, although the identity and objectives of the attacker remain unknown.

What investigators found

Hex reported no evidence of unauthorised package modification, unexpected database writes or persistent access to its environment. This is significant because malicious package releases could have exposed downstream users to a broader software supply chain attack.

Investigators nevertheless could not determine whether the attacker read information from the database. Database reads were not logged, creating uncertainty over whether email addresses, password hashes, API key hashes, two-factor authentication secrets or active sessions were accessed.

No public indicators of compromise were released. Hex referred to two attacker addresses and documented the exact attack period, but it did not disclose the addresses, file hashes or other indicators that organisations could use for direct matching.

Hex data breach timeline and containment

The response moved quickly once the malicious activity was identified. The known Hex data breach timeline is:

  • 18:16 to 18:29 UTC on 23 November: 69 exploit requests were sent, with commands executing on six web servers.
  • 18:27: Hex added a firewall rule to block the attack traffic.
  • 18:30 to 18:31: All servers were redeployed using a patched build.
  • 18:30 to 18:33: The firewall block became effective across the environment.
  • 18:49: Hex deactivated the relevant AWS key.
  • 19:07: The service received a security report email.
  • 20:21: Major infrastructure and application credential rotation began.
  • 22:58 to 23:26: Reports were filed with Sweden’s IMY, CISA and ENISA.
  • 10:42 on 24 November: Rotation of the remaining credentials was completed.
  • 13:48 on 24 November: CVE-2026-129514 was published.

Hex rotated credentials associated with storage, its content delivery network, email, databases and session signing. The session and access token changes logged all users out, requiring them to authenticate again.

How CVE-2026-129514 enabled command execution

CVE-2026-129514 is an unauthenticated deserialisation vulnerability in the hexpm server application’s request processing pipeline. Deserialisation converts submitted data into objects that an application can process. If untrusted input is converted too freely, specially constructed data can make the application perform unintended operations.

The vulnerable path handled request bodies with the content type application/vnd.hex+erlang. It decoded Erlang external term format data using Plug.Crypto.non_executable_binary_to_term with the [:safe] option.

Although that option blocks functions and the creation of new atoms, it still permitted maps containing a __struct__ key. This allowed an attacker-controlled structure to enter the request parameters before routing and authentication checks occurred.

The exploit chain

When Plug.MethodOverride attempted to access the decoded body parameters, it called a fetch operation on the attacker’s chosen structure. This produced an error carrying the malicious object into the application’s error reporting process.

Inspection of that object triggered protocol dispatch through Ecto.Query.DynamicExpr. The process then reached the Enumerable implementation for DBConnection.Stream, where a log option could contain an attacker-supplied module, function and argument tuple.

The database connection code applied that tuple without sufficient validation. This gave the attacker a route to invoke a chosen function and ultimately execute operating system commands as the BEAM process user.

The weakness had been present in the server code path since 23 February 2016, when an earlier safety check was removed. The Hex data breach flaw was fixed by rejecting decoded terms containing a map with a __struct__ key and returning an HTTP 400 response.

Products and versions affected by the Hex data breach

The affected product is the server-side hexpm application that powers hex.pm and can also be used in self-hosted deployments. The issue is not a vulnerability in the Hex client installed on developer systems.

The affected Git range begins with commit ab1bbcef7cc8395d1056d3b1aa6a174353492d59 and continues up to, but not including, commit 379b0a29bcc95164249f38ad7d772a37a8ff9533. The latter is the patched commit deployed by Hex on 23 November 2026.

For the hosted service, the vulnerable period ran from 23 February 2016 until the patched deployment on 23 November 2026. Operators of self-hosted instances should confirm that their deployment includes the fixed commit.

Related ecosystem issues were disclosed separately. Ash users relying on keyset pagination should update to Ash 3.38.0 for CVE-2026-124283, while db_connection users should update to version 2.10.3 for CVE-2026-133555. These are separate vulnerabilities and should not be confused with the exploited hex.pm server flaw.

Why the Hex data breach matters

Hex is part of the software dependency chain for many development teams. Although investigators found no package tampering, uncertainty over database reads means account credentials and publishing access should be treated as potentially exposed.

Attackers who obtained usable account or API credentials could attempt later access, including fraudulent package activity. There is no evidence that this occurred during the incident, but the logging gap prevents Hex from fully ruling out the necessary precursor data having been read.

Actions for Hex users and development teams

Organisations using hex.pm should take focused steps in response to the Hex data breach:

  • Change hex.pm account passwords, particularly where a password was reused elsewhere.
  • Reset 2FA to generate a new secret and new recovery codes.
  • Review and rotate Hex API credentials used by developers, automation and CI pipelines.
  • Confirm that build systems use the official repo.hex.pm registry endpoint rather than a mirror.
  • Review recent package releases, dependency lock files, checksums and pipeline runs for unexpected changes.
  • Check self-hosted hexpm servers for the patched commit and investigate activity during the documented attack window.
  • Install the forthcoming Hex client update when the new registry signing system becomes available.

There was no verified public proof of concept referenced by Hex or the official advisory at the time of reporting. Claims from vulnerability aggregators should therefore be treated cautiously, while the confirmed real-world exploitation against hex.pm remains the central risk indicator.

Originally reported by securityweek.com.

Share this bulletin

About the Author

Rob McBride Headshot - CyPro Partner and leading cyber security expert

Rob McBride

Partner

  • CISSP
  • ACA Chartered Accountant
  • MPhil
  • BSc
  • SOC 2
  • ISO 27001

Rob McBride

Rob is a Founding Partner at CyPro and a highly experienced CISO. Beginning his career with a successful tenure at Deloitte, Rob has since amassed a wealth of experience, notably serving as a cyber security advisor to the UK government and spearheading cloud security transformations for several global banks.

At CyPro, Rob leads the managed service business line, working extensively across multiple sectors including telecommunications, technology, higher education, travel, and retail. He is passionate about equipping small and medium-sized businesses (SMBs) with robust cyber security strategies to fuel their growth.

View Profile
Back to Bulletins

Related CyPro Services

  • Managed Detection and Response (MDR)

    Managed Detection and Response (MDR) is an end-to-end managed service designed to help organisations detect, analyse and respond to cyber threats quickly and effectively. It...
    View Service
CyPro Cookie Consent

Hmmm cookies...

Our delicious cookies make your experience smooth and secure.

Privacy PolicyOkay, got it!

We use cookies to enhance your experience, analyse site traffic, and for marketing purposes. For more information on how we handle your personal data, please see our Privacy Policy.

Schedule a Call