GHSA-x3m8-899r-f7c3 — xml-crypto
Fix: node-saml/xml-crypto@28f9221GHSA-x3m8-899r-f7c3 is a CWE-347 vulnerability in xml-crypto. A fix is available for xml-crypto — see the affected versions and patch details below.
xml-crypto Vulnerable to XML Signature Verification Bypass via DigestValue Comment
Exploitation Status
Proof-of-concept exploit code exists
- CISA’s SSVC triage found public proof-of-concept exploit code for this CVE, though no confirmed active exploitation.
- CISA assesses this as automatable — exploitation doesn’t require manual, per-target effort, which raises the odds of mass scanning and opportunistic attacks.
- A successful exploit gives an attacker total control of the affected component, not partial access.
Exploitation and automatability from CISA’s SSVC triage for GHSA-x3m8-899r-f7c3.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
Real-World Exposure
How broadly this vulnerability is actually deployed: weekly install volume shows current usage, and reverse-dependency count shows how many other packages break if it stays unpatched.
xml-cryptonpmDescription
Impact
An attacker may be able to exploit this vulnerability to bypass authentication or authorization mechanisms in systems that rely on xml-crypto for verifying signed XML documents. The vulnerability allows an attacker to modify a valid signed XML message in a way that still passes signature verification checks. For example, it could be used to alter critical identity or access control attributes, enabling an attacker to escalate privileges or impersonate another user.
Patches
All versions <= 6.0.0 are affected. Please upgrade to version 6.0.1.
If you are still using v2.x or v3.x please upgrade to the associated patch version.
Indicators of Compromise
When logging XML payloads, check for the following indicators. If the payload includes encrypted elements, ensure you analyze the decrypted version for a complete assessment. (If encryption is not used, analyze the original XML document directly). This applies to various XML-based authentication and authorization flows, such as SAML Response payloads.
Presence of Comments in DigestValue
A DigestValue should not contain comments. If you find comments within it, this may indicate tampering.
Example of a compromised DigestValue:
<DigestValue>
<!--TBlYWE0ZWM4ODI1NjliYzE3NmViN2E1OTlkOGDhhNmI=-->
c7RuVDYo83z2su5uk0Nla8DXcXvKYKgf7tZklJxL/LZ=
</DigestValue>
Code to test
Pass in the decrypted version of the document
decryptedDocument = ... // yours to implement
const digestValues = xpath.select(
"//*[local-name()='DigestValue'][count(node()) > 1]",
decryptedDocument,
);
if (digestValues.length > 0) {
// Compromise detected, yours to implement
}
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 📦npm | xml-crypto | ≥ 4.0.0&&< 6.0.1 | 6.0.1npm install xml-crypto@6.0.1 |
| 📦npm | xml-crypto | ≥ 3.0.0&&< 3.2.1 | 3.2.1npm install xml-crypto@3.2.1 |
| 📦npm | xml-crypto | all versions | 2.1.6npm install xml-crypto@2.1.6 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for xml-crypto, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update xml-crypto to 6.0.1 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-x3m8-899r-f7c3 is resolved across your whole dependency graph.
Workarounds
Put an independent control in front of the weakness: restrict the affected endpoint or interface to trusted networks, require an additional authentication factor or proxy-level check, and invalidate existing sessions and credentials in case the flaw has already been used.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
Mitigation for this issue is either not available or the currently available options don't meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.Source: Red Hat security advisory for GHSA-x3m8-899r-f7c3 (CC BY 4.0)
| Product | Fixed in | Advisory |
|---|---|---|
| Red Hat Developer Hub 1.5 | rhdh/rhdh-hub-rhel9:1.5 | RHSA-2025:3374 |
| Red Hat Developer Hub 1.6 | rhdh/rhdh-hub-rhel9:1.6.0-1745956724 | RHSA-2025:7626 |
| Red Hat Developer Hub (RHDH) 1.4 | rhdh/rhdh-hub-rhel9:1.4.3-1743652461 | RHSA-2025:3595 |
Frequently Asked Questions
Is GHSA-x3m8-899r-f7c3 in your dependencies?
Find it across npm, including transitive dependencies.