Skip to main content

CVE-2024-52596 — Vulnerability in simplesamlphp/xml-common

HIGH

SimpleSAMLphp xml-common XXE vulnerability

Published December 2, 2024Updated December 12, 2024Source: OSV

What Should I Do?

Address in Next Maintenance Window

Low exploitation probability (1.30%). Schedule for your next planned update.

Does your project use an affected simplesamlphp/xml-common version?

Paste your composer.lock to check it for CVE-2024-52596 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.

Check my composer.lock

Summary

Summary

When loading an (untrusted) XML document, for example the SAMLResponse, it's possible to induce an XXE.

$options is defined as: https://github.com/simplesamlphp/xml-common/blob/v1.19.0/src/DOMDocumentFactory.php#L39 including the DTDLoad option, which allows an attacker to read file contents from local file system OR internal network.

While there is the NONET option, an attacker can simply bypass if by using PHP filters: php://filter/convert.base64-encode/resource=http://URL OR FILE

From there an attacker can induce network connections and steal the targeted file OOB (haven't fully tested this).

RCE may be possible with the php://expect or php://phar wrappers, but this hasn't been tested.

Note: The mitigation here: https://github.com/simplesamlphp/xml-common/blob/v1.19.0/src/DOMDocumentFactory.php#L58 Comes too late, as the XML has already been loaded into a document. Mitigation:

Remove the LIBXML_DTDLOAD | LIBXML_DTDATTR options. Additionally, as a defense in depth measure, check if there is the string: <!DOCTYPE inside the XML before parsing it. (This is not a complete fix because someone may be able to exploit some parser differentials, to load a DOCTYPE, maybe through spacing like: <! DOCTYPE)

Advisory Timeline

  • First published December 2, 2024 (724 days ago).
  • Last revised December 12, 2024 — 10 days after initial publication.

Remediation

Upgrade to the fixed version using your package manager.

Composer
Update simplesamlphp/xml-common to 1.20.0 or later
composer require "simplesamlphp/xml-common:^1.20.0"

After upgrading, scan your dependencies again to confirm the vulnerability is resolved.

Affected Packages (1)

Affects 1 ecosystem: Packagist (1).

PackageFixed In
simplesamlphp/xml-common Packagist · Affected: 0.8.11, 0.8.12, v0.1.0, v0.1.1 (+118 more)1.20.0

Vulnerability Classification

Common Weakness Enumeration (CWE) identifiers for this vulnerability type.

  • CWE-611
    XML External Entity (XXE)MITRE

CVSS Score Breakdown

What the CVSS (Common Vulnerability Scoring System) 10.0 score means for each attack dimension.

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
—
Confidentiality
—
Integrity
—
Availability
—

CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:H/SC:L/SI:L/SA:N

Frequently Asked Questions

What is CVE-2024-52596?
SimpleSAMLphp xml-common XXE vulnerability. This vulnerability has been assigned a severity rating of HIGH (CVSS score: 10.0/10).
How do I check if my project is affected by CVE-2024-52596?
CVE-2024-52596 affects simplesamlphp/xml-common. It has a 1.3% probability of exploitation within 30 days (EPSS score). Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2024-52596 and 200,000+ other known vulnerabilities.

Severity & Exploitability

CVSS Score
10.0

Maximum impact if exploited, often with little effort or access required.

EPSS Score (30-day exploit probability)
1.30%
EPSS percentile: 70.4

This is an above-median EPSS score — 70.4% of tracked vulnerabilities score at or below it, putting its exploitation likelihood in the upper half of the tracked corpus.

Also Known As

GHSA-2x65-fpch-2fcm

Related CVEs

  • CVE-2026-103035
    HIGH

    TeamPass folder re-parenting authorization bypass

  • CVE-2026-110782
    HIGH

    SAML2: Incomplete fix of CVE-2026-49283: unsigned embedded Response bypasses HTTP-Artifact signature verification (no embedded-Issuer binding)

Check your own dependencies

Free, with no signup for up to 10 packages.

Check my composer.lock