CVE-2024-8176

Libexpat: expat: improper restriction of xml entity expansion depth in libexpat

7.5 high EPSS 1.35%

Published 14 Mar 2025 Updated 24 Nov 2026 CNA: redhat

Check your servers for CVE-2024-8176

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2024-8176 affects expat, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

A stack overflow vulnerability exists in the libexpat library due to the way it handles recursive entity expansion in XML documents. When parsing an XML document with deeply nested entity references, libexpat can be forced to recurse indefinitely, exhausting the stack space and causing a crash. This issue could lead to denial of service (DoS) or, in some cases, exploitable memory corruption, depending on the environment and library usage.

Severity (CVSS)

7.5 high CVSS 3.1 from redhat (CNA)
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Attack vector
network: an attacker can reach the vulnerable part over the network, often from the internet
Attack complexity
low: an attack works without special conditions
Privileges required
none: the attacker does not need an account
User interaction
none: nobody has to click or open anything
Scope
unchanged: the damage stays inside the vulnerable component
Impact
confidentiality none, integrity none, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)

Exploitation

EPSS 1.35%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 72.3% of all scored CVEs. Scores of 1 Dec 2026.

The assessment of CISA (SSVC, 14 Mar 2025):

Exploitation
poc: a proof of concept is public
Automatable
yes: an attacker can automate the attack across many targets
Technical impact
partial: limited control or limited data

Weakness

Affected products

As the CNA lists them.

ProductVersions
libexpat
package libexpat
affected before 2.7.0
Other versions: unaffected
Red Hat Enterprise Linux 10
package expat
unaffected 0:2.7.1-1.el10_0 and later
Other versions: affected
Red Hat Enterprise Linux 8
package expat
unaffected 0:2.2.5-17.el8_10 and later
Other versions: affected
Red Hat Enterprise Linux 8
package xmlrpc-c
unaffected 0:1.51.0-11.el8_10 and later
Other versions: affected
Red Hat Enterprise Linux 8.2 Advanced Update Support
package expat
unaffected 0:2.2.10-1.el8_2 and later
Other versions: affected
Red Hat Enterprise Linux 8.2 Advanced Update Support
package xmlrpc-c
unaffected 0:1.51.0-5.el8_2.2 and later
Other versions: affected
Red Hat Enterprise Linux 8.4 Advanced Mission Critical Update Support
package expat
unaffected 0:2.2.10-1.el8_4 and later
Other versions: affected
Red Hat Enterprise Linux 8.4 Advanced Mission Critical Update Support
package xmlrpc-c
unaffected 0:1.51.0-5.el8_4.2 and later
Other versions: affected
Red Hat Enterprise Linux 8.4 Extended Update Support Long-Life Add-On
package expat
unaffected 0:2.2.10-1.el8_4 and later
Other versions: affected
Red Hat Enterprise Linux 8.4 Telecommunications Update Service
package xmlrpc-c
unaffected 0:1.51.0-5.el8_4.2 and later
Other versions: affected
Red Hat Enterprise Linux 8.4 Update Services for SAP Solutions
package xmlrpc-c
unaffected 0:1.51.0-5.el8_4.2 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Advanced Mission Critical Update Support
package expat
unaffected 0:2.2.10-1.el8_6 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Advanced Mission Critical Update Support
package xmlrpc-c
unaffected 0:1.51.0-6.el8_6.1 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Telecommunications Update Service
package expat
unaffected 0:2.2.10-1.el8_6 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Telecommunications Update Service
package xmlrpc-c
unaffected 0:1.51.0-6.el8_6.1 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Update Services for SAP Solutions
package expat
unaffected 0:2.2.10-1.el8_6 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Update Services for SAP Solutions
package xmlrpc-c
unaffected 0:1.51.0-6.el8_6.1 and later
Other versions: affected
Red Hat Enterprise Linux 8.8 Extended Update Support
package xmlrpc-c
unaffected 0:1.51.0-8.el8_8.1 and later
Other versions: affected
Red Hat Enterprise Linux 8.8 Telecommunications Update Service
package expat
unaffected 0:2.2.10-1.el8_8 and later
Other versions: affected
Red Hat Enterprise Linux 8.8 Update Services for SAP Solutions
package expat
unaffected 0:2.2.10-1.el8_8 and later
Other versions: affected
Red Hat Enterprise Linux 9
package expat
unaffected 0:2.5.0-3.el9_5.3 and later
Other versions: affected
Red Hat Enterprise Linux 9
package expat
unaffected 0:2.5.0-5.el9_6 and later
Other versions: affected
Red Hat Enterprise Linux 9
package expat
unaffected 0:2.5.0-3.el9_5.3 and later
Other versions: affected
Red Hat Enterprise Linux 9
package expat
unaffected 0:2.5.0-5.el9_6 and later
Other versions: affected
Red Hat Enterprise Linux 9.0 Update Services for SAP Solutions
package expat
unaffected 0:2.2.10-12.el9_0.4 and later
Other versions: affected
Red Hat Enterprise Linux 9.2 Update Services for SAP Solutions
package expat
unaffected 0:2.5.0-1.el9_2.3 and later
Other versions: affected
Red Hat Enterprise Linux 9.4 Extended Update Support
package expat
unaffected 0:2.5.0-2.el9_4.3 and later
Other versions: affected
Red Hat JBoss Core Services 2.4.62.SP1
package expat
unaffected the record does not list versions
DevWorkspace Operator 0.33
package devworkspace/devworkspace-project-clone-rhel9
unaffected 0.33-1744075017 and later
Other versions: affected
Red Hat Discovery 1.14
package discovery/discovery-server-rhel9
unaffected 1.14.3-1748529279 and later
Other versions: affected
Red Hat Discovery 1.14
package discovery/discovery-ui-rhel9
unaffected 1.14.2-1748467619 and later
Other versions: affected
Red Hat Enterprise Linux 6
package compat-expat1
unknown the record does not list versions
Red Hat Enterprise Linux 6
package expat
unknown the record does not list versions
Red Hat Enterprise Linux 7
package expat
unknown the record does not list versions
Red Hat Enterprise Linux 7
package firefox
unknown the record does not list versions
Red Hat Enterprise Linux 7
package thunderbird
unknown the record does not list versions
Red Hat Enterprise Linux 8
package firefox
affected the record does not list versions
Red Hat Enterprise Linux 8
package lua-expat
unaffected the record does not list versions
Red Hat Enterprise Linux 8
package mingw-expat
affected the record does not list versions
Red Hat Enterprise Linux 8
package thunderbird
affected the record does not list versions
Red Hat Enterprise Linux 9
package firefox
affected the record does not list versions
Red Hat Enterprise Linux 9
package firefox:flatpak/firefox
affected the record does not list versions
Red Hat Enterprise Linux 9
package thunderbird
affected the record does not list versions
Red Hat Enterprise Linux 9
package thunderbird:flatpak/thunderbird
affected the record does not list versions
Red Hat OpenShift Container Platform 4
package openshift/ose-rhel-coreos-8
affected the record does not list versions
Red Hat OpenShift Container Platform 4
package openshift/ose-rhel-coreos-9
affected the record does not list versions

Is my server affected?

Find the installed version of expat and compare it with the fixed version of your distribution. Distributions often fix a CVE in a package version of their own, so the version number of the upstream project can mislead.

Debian, Ubuntu

dpkg -l | grep -i expat
# packages whose changelog names the CVE (fixed in the installed version)
zgrep -l CVE-2024-8176 /usr/share/doc/*/changelog.Debian.gz
# Ubuntu
pro fix CVE-2024-8176

RHEL, Rocky, Alma, Fedora

rpm -q expat
# lists the advisory while the fix is not installed
dnf updateinfo list --cve CVE-2024-8176

Alpine

apk list --installed | grep -i expat

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2024-8176
trivy image --scanners vuln IMAGE | grep CVE-2024-8176

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Advisories

9 more

Other references

8 more

Source: the record CVE-2024-8176 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST; the CWE catalog of MITRE, CWE Terms of Use. The text of the record is shown as published. Data sources and licences.