Quick answers
- Is CVE-2024-32962 exploited in the wild?
- No. Junglewise Threat Intelligence has no report of CVE-2024-32962 being exploited in the wild.
- How severe is CVE-2024-32962?
- Low severity, with a CVSS score of 3.1, published 1 May 2024.
- Which products and versions are affected?
- xml-crypto (npm) SEMVER:introduced=4.0.0,fixed=6.0.0.
- Is there a fix for CVE-2024-32962?
- Yes. xml-crypto (npm): upgrade to 6.0.0 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
- How is CVE-2024-32962 attacked?
- It is attacked over the network, in a software library.
- Am I affected by CVE-2024-32962?
- Check whether you run xml-crypto (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.
How to fix
- xml-crypto (npm): upgrade to 6.0.0 or later
npm install xml-crypto@6.0.0
Technical details
The vulnerability exists in xml-crypto versions 4.x and 5.x due to the default behavior of the getCertFromKeyInfo method. By default, the library extracts and trusts any X509Certificate found in the <KeyInfo /> element of a signed XML document, even if a specific publicCert was explicitly configured for verification. An attacker can exploit this by re-signing a document with a malicious private key and attaching the corresponding certificate to the XML. The library will prefer the attacker-supplied certificate over the trusted one, resulting in a successful signature validation of a spoofed payload. This was addressed in version 6.0.0 by disabling the implicit usage of the default certificate extraction logic.
Affected products
- node-saml xml-crypto >= 4.0.0, < 6.0.0
Identifiers
- CVE-2024-32962
- GHSA-2xp3-57p7-qf4v
Timeline
- 2023-06-17: other: Vulnerability introduced in version 4.0.0 via PR 301
- 2024-05-01: advisory: GitHub Security Advisory published
- 2024-05-01: patched: Fixed in version 6.0.0
References
- https://github.com/node-saml/xml-crypto/security/advisories/GHSA-2xp3-57p7-qf4v
- https://github.com/node-saml/xml-crypto/pull/301
- https://github.com/node-saml/xml-crypto/pull/445
- https://github.com/node-saml/xml-crypto/commit/21201723d2ca9bc11288f62cf72552b7d659b000
- https://github.com/node-saml/xml-crypto/commit/c2b83f984049edb68ad1d7c6ad0739ec92af11ca
- https://github.com/node-saml/xml-crypto