CVE-2024-8176: Software Security Vulnerability Vulnerability

HIGH
Advisory Identifier: GHSA-9hcv-xw76-m4h6
CVSS 7.5
CWE-674
Published
Advisory Summary

CVE-2024-8176 is a HIGH (CVSS 7.5) security vulnerability vulnerability (CWE-674: Uncontrolled Recursion) affecting Software libraries in the Maven ecosystem. The weakness occurs when the product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack.. Remediation is available in the latest vendor maintenance releases.

CVE-2024-8176 at a Glance

CVE Identifier CVE-2024-8176
GHSA Identifier GHSA-9hcv-xw76-m4h6
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-674: Uncontrolled Recursion
Affected Product Software
Package Ecosystem Maven
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity None (I:N)
Availability High (A:H)

How to Fix CVE-2024-8176

To remediate this vulnerability, upgrade all affected Software dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

mvn dependency:tree

How to Check if You Are Affected

To determine whether your Java application is affected by CVE-2024-8176, inspect your build dependencies using the Maven Dependency Plugin:

mvn dependency:tree

Analyze the terminal output to locate any version of Software in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.

Note: The mvn dependency:tree command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-674: Uncontrolled Recursion, where the product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack. In Software, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

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.

References

NVD — CVE-2024-8176 NVD
https://nvd.nist.gov/vuln/detail/CVE-2024-8176
Software Source Repository REPOSITORY
https://github.com/libexpat/libexpat/issues/893
Software Source Repository REPOSITORY
https://github.com/libexpat/libexpat/pull/973
access.redhat.com/errata/rhsa-2025:75... WEB
https://access.redhat.com/errata/RHSA-2025:7512
access.redhat.com/errata/rhsa-2025:83... WEB
https://access.redhat.com/errata/RHSA-2025:8385
Software Security Information SECURITY
https://access.redhat.com/security/cve/CVE-2024-8176
blog.hartwork.org/posts/expat-2-7-0-r... WEB
https://blog.hartwork.org/posts/expat-2-7-0-released
bugzilla.redhat.com/show_bug.cgi WEB
https://bugzilla.redhat.com/show_bug.cgi?id=2310137
bugzilla.suse.com/show_bug.cgi WEB
https://bugzilla.suse.com/show_bug.cgi?id=1239618
cert-portal.siemens.com/productcert/html/ss... WEB
https://cert-portal.siemens.com/productcert/html/ssa-355557.html
cert-portal.siemens.com/productcert/html/ss... WEB
https://cert-portal.siemens.com/productcert/html/ssa-398330.html
Software Source Repository REPOSITORY
https://github.com/libexpat/libexpat/blob/R_2_7_0/expat/Changes#L40-L52
gitlab.alpinelinux.org/alpine/aports/-/com... WEB
https://gitlab.alpinelinux.org/alpine/aports/-/commit/d068c3ff36fc6f4789988a09c69b434db757db53
Software Security Information SECURITY
https://security-tracker.debian.org/tracker/CVE-2024-8176
Software Security Information SECURITY
https://security.netapp.com/advisory/ntap-20250328-0009
Software Security Information SECURITY
https://ubuntu.com/security/CVE-2024-8176
www.kb.cert.org/vuls/id/760160 WEB
https://www.kb.cert.org/vuls/id/760160
access.redhat.com/errata/rhsa-2025:13... WEB
https://access.redhat.com/errata/RHSA-2025:13681
access.redhat.com/errata/rhsa-2025:22... WEB
https://access.redhat.com/errata/RHSA-2025:22033
access.redhat.com/errata/rhsa-2025:22... WEB
https://access.redhat.com/errata/RHSA-2025:22034
access.redhat.com/errata/rhsa-2025:22... WEB
https://access.redhat.com/errata/RHSA-2025:22035
access.redhat.com/errata/rhsa-2025:22... WEB
https://access.redhat.com/errata/RHSA-2025:22607
access.redhat.com/errata/rhsa-2025:22... WEB
https://access.redhat.com/errata/RHSA-2025:22785
access.redhat.com/errata/rhsa-2025:22... WEB
https://access.redhat.com/errata/RHSA-2025:22842
access.redhat.com/errata/rhsa-2025:22... WEB
https://access.redhat.com/errata/RHSA-2025:22871
access.redhat.com/errata/rhsa-2025:35... WEB
https://access.redhat.com/errata/RHSA-2025:3531
access.redhat.com/errata/rhsa-2025:37... WEB
https://access.redhat.com/errata/RHSA-2025:3734
access.redhat.com/errata/rhsa-2025:39... WEB
https://access.redhat.com/errata/RHSA-2025:3913
access.redhat.com/errata/rhsa-2025:40... WEB
https://access.redhat.com/errata/RHSA-2025:4048
access.redhat.com/errata/rhsa-2025:44... WEB
https://access.redhat.com/errata/RHSA-2025:4446
access.redhat.com/errata/rhsa-2025:44... WEB
https://access.redhat.com/errata/RHSA-2025:4447
access.redhat.com/errata/rhsa-2025:44... WEB
https://access.redhat.com/errata/RHSA-2025:4448
access.redhat.com/errata/rhsa-2025:44... WEB
https://access.redhat.com/errata/RHSA-2025:4449
access.redhat.com/errata/rhsa-2025:74... WEB
https://access.redhat.com/errata/RHSA-2025:7444
seclists.org/fulldisclosure/2025... WEB
http://seclists.org/fulldisclosure/2025/May/10
seclists.org/fulldisclosure/2025... WEB
http://seclists.org/fulldisclosure/2025/May/11
seclists.org/fulldisclosure/2025... WEB
http://seclists.org/fulldisclosure/2025/May/12
seclists.org/fulldisclosure/2025... WEB
http://seclists.org/fulldisclosure/2025/May/6
seclists.org/fulldisclosure/2025... WEB
http://seclists.org/fulldisclosure/2025/May/7
seclists.org/fulldisclosure/2025... WEB
http://seclists.org/fulldisclosure/2025/May/8
Software Security Information SECURITY
http://www.openwall.com/lists/oss-security/2025/03/15/1
Software Security Information SECURITY
http://www.openwall.com/lists/oss-security/2025/09/24/11

Frequently Asked Questions

What is CVE-2024-8176?
CVE-2024-8176 is a security vulnerability in Software classified as a security vulnerability vulnerability under CWE-674: Uncontrolled Recursion.
Which Software versions are affected?
Affected versions include releases prior to current release patches.
What version fixes CVE-2024-8176?
Upgrading to current release patches (or the latest patched release for your respective branch) resolves the vulnerability.
What is the CVSS score of CVE-2024-8176?
CVE-2024-8176 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
What CWE is associated with CVE-2024-8176?
CVE-2024-8176 is classified under CWE-674: Uncontrolled Recursion (The product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack.).
How can I check Maven dependencies for CVE-2024-8176?
Run the dependency tree command: 'mvn dependency:tree'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-9hcv-xw76-m4h6",
  "modified" : "2026-10-15T03:34:43Z",
  "published" : "2025-03-14T09:34:06Z",
  "aliases" : [ "CVE-2024-8176" ],
  "details" : "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" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
  } ],
  "affected" : [ ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-8176"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/libexpat/libexpat/issues/893"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/libexpat/libexpat/pull/973"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:7512"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:8385"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/security/cve/CVE-2024-8176"
  }, {
    "type" : "WEB",
    "url" : "https://blog.hartwork.org/posts/expat-2-7-0-released"
  }, {
    "type" : "WEB",
    "url" : "https://bugzilla.redhat.com/show_bug.cgi?id=2310137"
  }, {
    "type" : "WEB",
    "url" : "https://bugzilla.suse.com/show_bug.cgi?id=1239618"
  }, {
    "type" : "WEB",
    "url" : "https://cert-portal.siemens.com/productcert/html/ssa-355557.html"
  }, {
    "type" : "WEB",
    "url" : "https://cert-portal.siemens.com/productcert/html/ssa-398330.html"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/libexpat/libexpat/blob/R_2_7_0/expat/Changes#L40-L52"
  }, {
    "type" : "WEB",
    "url" : "https://gitlab.alpinelinux.org/alpine/aports/-/commit/d068c3ff36fc6f4789988a09c69b434db757db53"
  }, {
    "type" : "WEB",
    "url" : "https://security-tracker.debian.org/tracker/CVE-2024-8176"
  }, {
    "type" : "WEB",
    "url" : "https://security.netapp.com/advisory/ntap-20250328-0009"
  }, {
    "type" : "WEB",
    "url" : "https://ubuntu.com/security/CVE-2024-8176"
  }, {
    "type" : "WEB",
    "url" : "https://www.kb.cert.org/vuls/id/760160"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:13681"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:22033"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:22034"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:22035"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:22607"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:22785"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:22842"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:22871"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:3531"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:3734"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:3913"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:4048"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:4446"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:4447"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:4448"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:4449"
  }, {
    "type" : "WEB",
    "url" : "https://access.redhat.com/errata/RHSA-2025:7444"
  }, {
    "type" : "WEB",
    "url" : "http://seclists.org/fulldisclosure/2025/May/10"
  }, {
    "type" : "WEB",
    "url" : "http://seclists.org/fulldisclosure/2025/May/11"
  }, {
    "type" : "WEB",
    "url" : "http://seclists.org/fulldisclosure/2025/May/12"
  }, {
    "type" : "WEB",
    "url" : "http://seclists.org/fulldisclosure/2025/May/6"
  }, {
    "type" : "WEB",
    "url" : "http://seclists.org/fulldisclosure/2025/May/7"
  }, {
    "type" : "WEB",
    "url" : "http://seclists.org/fulldisclosure/2025/May/8"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2025/03/15/1"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2025/09/24/11"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-674" ],
    "severity" : "HIGH",
    "github_reviewed" : false,
    "github_reviewed_at" : null,
    "nvd_published_at" : "2025-03-14T09:15:14Z"
  }
}