CVE-2025-32965: Xrpl Compromised Xrpl.js Versions 4.2.1, 4.2.2, Vulnerability

CRITICAL
Advisory Identifier: GHSA-33qr-m49q-rxfx
CWE-506
Published
Advisory Summary

CVE-2025-32965 is a CRITICAL compromised xrpl.js versions 4.2.1, 4.2.2, vulnerability (CWE-506: Embedded Malicious Code) affecting Xrpl libraries in the npm ecosystem. The issue involves compromised xrpl.js versions 4.2.1, 4.2.2, 4.2.3, 4.2.4, and 2.14.2. Remediation is available by upgrading affected packages to version 4.2.5, 2.14.3.

CVE-2025-32965 at a Glance

CVE Identifier CVE-2025-32965
GHSA Identifier GHSA-33qr-m49q-rxfx
Severity CRITICAL
CVSS v3.1 Base Score N/A
CWE Classification CWE-506: Embedded Malicious Code
Affected Product Xrpl
Package Ecosystem npm
Published Date
Last Updated

How to Fix CVE-2025-32965

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

xrpl fixed: 4.2.5
npm install xrpl@4.2.5
xrpl fixed: 2.14.3
npm install xrpl@2.14.3
Verify Direct and Transitive Dependencies

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

npm ls xrpl

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2025-32965, inspect your project dependencies using npm:

npm ls xrpl

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

Note: The npm ls xrpl command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-506: Embedded Malicious Code, where the product contains code that appears to be malicious in nature. In Xrpl, 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

### Impact Versions 4.2.1, 4.2.2, 4.2.3, and 4.2.4 of xrpl.js were compromised and contained malicious code designed to exfiltrate private keys. If you are using one of these versions, stop immediately and rotate any private keys or secrets used with affected systems. Version 2.14.2 is also malicious, though it is less likely to lead to exploitation as it is not compatible with other 2.x versions. ### Patches Upgrade to version 4.2.5 or 2.14.3. ### Required Actions To secure funds, think carefully about whether any keys may have been compromised by this supply chain attack, and mitigate by sending funds to secure wallets, and/or rotating keys: The XRP Ledger supports key rotation: https://xrpl.org/docs/tutorials/how-tos/manage-account-settings/assign-a-regular-key-pair If any account's master key is potentially compromised, you should disable it: https://xrpl.org/docs/tutorials/how-tos/manage-account-settings/disable-master-key-pair ### References https://www.aikido.dev/blog/xrp-supplychain-attack-official-npm-package-infected-with-crypto-stealing-backdoor

CVE-2025-32965 Affected Xrpl Versions

2 component(s)
Fixed Versions:
4.2.52.14.3
Product / Package Ecosystem Affected Versions Fixed Version
xrpl
npm
≥ 4.2.1
< 4.2.5
4.2.5
xrpl
npm
≥ 2.14.2
< 2.14.3
All 1 versions
2.14.2
2.14.3

References

Frequently Asked Questions

What is CVE-2025-32965?
CVE-2025-32965 is a security vulnerability in Xrpl involving Compromised xrpl.js versions 4.2.1, 4.2.2, 4.2.3, 4.2.4, and 2.14.2 under CWE-506: Embedded Malicious Code.
Which Xrpl versions are affected?
Affected versions include releases prior to 4.2.5, 2.14.3 across affected packages: xrpl.
What version fixes CVE-2025-32965?
Upgrading to 4.2.5, 2.14.3 (or the latest patched release for your respective branch) resolves the vulnerability.
Is xrpl affected?
Yes, xrpl is affected in releases prior to 4.2.5, 2.14.3. Upgrade your dependency to 4.2.5, 2.14.3 or later.
What CWE is associated with CVE-2025-32965?
CVE-2025-32965 is classified under CWE-506: Embedded Malicious Code (The product contains code that appears to be malicious in nature.).
How can I check npm dependencies for CVE-2025-32965?
Run the dependency tree command: 'npm ls xrpl'. 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-33qr-m49q-rxfx",
  "modified" : "2025-04-22T23:53:56Z",
  "published" : "2025-04-22T18:57:48Z",
  "aliases" : [ "CVE-2025-32965" ],
  "summary" : "Compromised xrpl.js versions 4.2.1, 4.2.2, 4.2.3, 4.2.4, and 2.14.2",
  "details" : "### Impact\nVersions 4.2.1, 4.2.2, 4.2.3, and 4.2.4 of xrpl.js were compromised and contained malicious code designed to exfiltrate private keys. If you are using one of these versions, stop immediately and rotate any private keys or secrets used with affected systems.\n\nVersion 2.14.2 is also malicious, though it is less likely to lead to exploitation as it is not compatible with other 2.x versions.\n\n### Patches\nUpgrade to version 4.2.5 or 2.14.3.\n\n### Required Actions\nTo secure funds, think carefully about whether any keys may have been compromised by this supply chain attack, and mitigate by sending funds to secure wallets, and/or rotating keys:\n\nThe XRP Ledger supports key rotation: https://xrpl.org/docs/tutorials/how-tos/manage-account-settings/assign-a-regular-key-pair\n\nIf any account's master key is potentially compromised, you should disable it: https://xrpl.org/docs/tutorials/how-tos/manage-account-settings/disable-master-key-pair\n\n### References\nhttps://www.aikido.dev/blog/xrp-supplychain-attack-official-npm-package-infected-with-crypto-stealing-backdoor",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "xrpl"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "4.2.1"
      }, {
        "fixed" : "4.2.5"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "npm",
      "name" : "xrpl"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.14.2"
      }, {
        "fixed" : "2.14.3"
      } ]
    } ],
    "versions" : [ "2.14.2" ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/XRPLF/xrpl.js/security/advisories/GHSA-33qr-m49q-rxfx"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-32965"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/XRPLF/xrpl.js"
  }, {
    "type" : "WEB",
    "url" : "https://www.aikido.dev/blog/xrp-supplychain-attack-official-npm-package-infected-with-crypto-stealing-backdoor"
  }, {
    "type" : "WEB",
    "url" : "https://xrpl.org/docs/tutorials/how-tos/manage-account-settings/assign-a-regular-key-pair"
  }, {
    "type" : "WEB",
    "url" : "https://xrpl.org/docs/tutorials/how-tos/manage-account-settings/disable-master-key-pair"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-506" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-04-22T18:57:48Z",
    "nvd_published_at" : "2025-04-22T21:15:45Z"
  }
}