CVE-2026-76956: libexpat hash flooding denial of service via mishandled entropy generation

CVE-2026-76956 · Severity: medium · CVSS 5.9 · Published 2026-08-20

libexpat is an XML parsing library used in many applications to process XML documents. A logic error in the library's random number generation causes it to fall back to weak entropy sources when processing XML, making the parser vulnerable to hash flooding attacks. An attacker can craft malicious XML content that causes excessive CPU consumption and application slowdown or crash.

Technologies: Libexpat Project Libexpat. Vendors: Libexpat Project.

Quick answers

Is CVE-2026-76956 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-76956 being exploited in the wild.
How severe is CVE-2026-76956?
Medium severity, with a CVSS score of 5.9, published 20 August 2026.
Which products and versions are affected?
libexpat libexpat 2.8.2, 2.8.3.
Is there a fix for CVE-2026-76956?
A patch was published on 2026-08-31: Fixed in libexpat 2.8.4 Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-76956 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-76956?
Check whether you run Libexpat Project Libexpat. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

The vulnerability stems from an inverted return code check in the writeRandomBytes_getentropy() function. The getentropy() system call returns 0 on success, but the code stores this return value directly into a bool variable, inverting the logic—a successful entropy read is treated as a failure. Consequently, legitimate entropy is discarded and the salt generation falls back to weaker time+pid-based randomization. Additionally, the failure path uses an uninitialized buffer. An attacker can exploit this by sending specially crafted XML content that triggers hash collisions in the parser's internal hash tables, causing denial of service. The fix was merged into libexpat 2.8.4, released on or about August 31, 2026; versions 2.8.2 and 2.8.3 are affected.

Affected products

  • libexpat libexpat 2.8.2, 2.8.3

Timeline

  • 2026-08-20: disclosed
  • 2026-08-31: patched: Fixed in libexpat 2.8.4

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.