Node-SAML CVE-2025-54369
CRITICALAttack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessObtain validly signed SAML assertion from IdP
-
DeliveryModify unsigned username/auth details in response
-
ExploitSubmit crafted response to node-saml relying party
-
ExecutionSignature validates against original signed region
-
ImpactAuthenticate as impersonated identity
Vulnerability Assessment
| Weakness |
CWE
|
| Exploitation Conditions | Exploitation requires that the attacker already possess a validly signed SAML response/assertion issued by the trusted identity provider (per the GHSA advisory), then tamper with the authentication details - e.g. the NameID/username - in the unsigned original response document that node-saml loads, since that differs from the signature-verified region. It applies to applications using @node-saml/node-saml version 5.0.1 or below (and legacy node-saml <= 3.1.2). The principal limiting factor is the need for a genuine IdP-signed document to start from, meaning the attacker must typically control or obtain a legitimately authenticated assertion; no additional user interaction is required and the modification itself (such as removing a single character) is trivial. |
| Impact | This is a genuine high-priority issue, not a CVSS-inflated one. The input assigns CVSS 4.0 9.3 (AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N) and a vuln.today Decision label of act_now, and the flaw is a SAML signature-verification bypass (GHSA classifies it CWE-347/CWE-287/CWE-87): node-saml reads the assertion from the unsigned original response document rather than from the signature-verified content, letting an attacker alter authentication details inside an already-validly-signed assertion. The real-world urgency is driven by the decision framework and the direct authentication-bypass impact rather than by probabilistic signals - no EPSS score and no KEV status were supplied in the input, and no CISA KEV listing is indicated, so active exploitation is not confirmed. No working public exploit is referenced (only the fixing commit, the 5.1.0 release, and the GHSA advisory), so this should be treated as a confirmed, high-impact logic flaw with a clear fix rather than as confirmed in-the-wild exploitation. One important nuance not captured by the PR:N metric: the advisory states the attacker must first possess a validly signed document from the identity provider, which practically means the attacker needs to already be (or control) a legitimately authenticated principal - a real limiting factor to weigh against the raw score. |
| Exploit ScenarioDerived | An attacker who already holds a legitimately signed SAML response from the IdP (for example, their own valid assertion) modifies the authentication details in the unsigned portion that node-saml actually consumes - such as removing a character from the username to resolve to a different account. The relying party validates the signature against the untouched signed region, the check passes, and node-saml authenticates the attacker as the manipulated identity. No public working exploit code is referenced, but the GHSA advisory describes the technique concretely. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Nov 07, 2026
Node-SAML (published on npm as @node-saml/node-saml) loads the SAML assertion from the raw, unsigned original response document instead of from the region whose signature was actually verified, so anyone holding a genuinely IdP-signed SAML response can rewrite authentication details - for example, deleting characters from the assertion username (NameID) - and still pass the signature check. The assessed CVSS 3.1 vector (AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N) makes this a genuine high-priority authentication-bypass issue rather than a CVSS-inflated one, even though NVD's CVSS 4.0 base of 9.3 with PR:N is more aggressive than the documented prerequisites actually support. Affected are @node-saml/node-saml 5.0.1 and below and the legacy node-saml package at 3.1.2 and below; 5.1.0 contains the fix. No public exploit code and no CISA KEV entry were identified at time of analysis, but the vuln.today decision signal is act_now because a valid signed document is the only real barrier and the tampering itself is trivial.
RemediationAI
Vendor-released patch: @node-saml/node-saml 5.1.0 - upgrade to that version, which pulls in xml-crypto ^6.1.2 and processes assertions only from signature-verified content. Environments pinned to the legacy node-saml package (<= 3.1.2, listed by the advisory as not yet patched) should migrate to @node-saml/node-saml 5.1.0 rather than wait for a backport. The advisory documents no interim workaround and frames the dependency and code change as the complete fix; because the attack reuses a validly signed IdP document, signature-validation failure logging and assertion-signature requirements do not detect the tampering, so patch deployment is the operative control. Verify the resulting dependency tree actually resolves xml-crypto to 6.1.2 or later after upgrading, and treat any SAML service provider built on 5.0.1 or below as exposed until it is confirmed on 5.1.0. Advisory and fix references: https://github.com/node-saml/node-saml/security/advisories/GHSA-m837-g268-mmv7, https://github.com/node-saml/node-saml/releases/tag/v5.1.0, https://github.com/node-saml/node-saml/commit/31ead9411ebc3e2385086fa9149b6c17732bca10.
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 2 packages in npm
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The flaw is an XML signature-verification/consumption mismatch (signature-wrapping class) in a SAML service-provider library. Before 5.1.0, validateSignature(xml, doc.documentElement, pemFiles) and validateSignature(xml, assertions[0], pemFiles) returned only a boolean, and node-saml then handed assertions[0].toString() - the assertion node as parsed from the original, untrusted document - to processValidlySignedAssertionAsync(). The bytes that were cryptographically verified therefore were not the bytes that were consumed, which is exactly the CWE-347 (Improper Verification of Cryptographic Signature) and CWE-287 (Improper Authentication) condition the GitHub advisory also cites alongside the CWE-87 mapping carried on the CVE record. The upstream commit 31ead9411ebc3e2385086fa9149b6c17732bca10 addresses the root cause by bumping the xml-crypto dependency from ^6.1.0 to ^6.1.2 and switching to getVerifiedXml(), which returns the actual canonicalized, signature-validated XML rather than a flag; the library additionally adds a getSignedAssertion() helper that extracts the single Assertion (or decrypts a single EncryptedAssertion using decryptionPvk and re-parses it as an Assertion) from the verified Response, and refuses other root elements. Because the signature on the original document remains validly IdP-signed, ordinary signature-failure monitoring will not surface an attack. The 'Denial Of Service' tag carried in the feed does not correspond to the authentication-bypass impact described in the advisory or to the assessed CIA vector, which shows confidentiality and integrity impact with no availability impact.
Know when the next one hits your stack
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N
Attacker must first obtain a validly signed IdP assertion (PR:L, AC:H) then trivially alter the unsigned identity; impersonation yields high confidentiality and integrity but no availability impact.
Primary rating from Vendor (github).
CVSS VectorVendor: github
DescriptionCVE.org
Node-SAML is a SAML library not dependent on any frameworks that runs in Node. In versions 5.0.1 and below, Node-SAML loads the assertion from the (unsigned) original response document. This is different than the parts that are verified when checking signature. This allows an attacker to modify authentication details within a valid SAML assertion. For example, in one attack it is possible to remove any character from the SAML assertion username. This issue is fixed in version 5.1.0.
Executive ViewAI
A critical authentication bypass vulnerability in the widely-used Node-SAML library (versions 5.0.1 and below, plus legacy 3.1.2 and below) allows an attacker with a valid signed SAML response to modify authentication details-such as the username-and still pass signature verification. This undermines the core identity assurance for any application relying on SAML single sign-on, potentially enabling unauthorized access to sensitive systems and data. Leadership should prioritize remediation because the flaw directly affects access control, and the only barrier to exploitation is obtaining a legitimately signed assertion-a low bar for an insider or anyone who can capture one.
No vendor-released patch identified at time of analysis; interim mitigations include enforcing strict validation of SAML assertions against the original signed XML (e.g., using XML schema validation and canonicalization checks), implementing additional authentication factors or risk-based authentication for affected applications, restricting network access to SAML endpoints, and closely monitoring authentication logs for anomalies such as username tampering or unexpected access patterns.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
NVD
CVE.org
EPSS
GitHub
VulDB
Exploit-DB