Get a Demo

Let's Patch It!

Book a short call with one our specialists, we'll walk you through how Endor Patches work, and ask you a few questions about your environment (like your primary programming languages and repository management). We'll also send you an email right after you fill out the form, feel free to reply with any questions you have in advance!

CVE

CVE-2025-13437

zx Uses Incorrectly-Resolved Name or Reference
Back to all
CVE

CVE-2025-13437

zx Uses Incorrectly-Resolved Name or Reference

When zx is invoked with --prefer-local=<path>, the CLI creates a symlink named ./nodemodules pointing to <path>/nodemodules. Due to a logic error in src/cli.ts (linkNodeModules / cleanup), the function returns the target path instead of the alias (symlink path). The later cleanup routine removes what it received, which deletes the target directory itself. Result: zx can delete an external <path>/node_modules outside the current working directory.

Package Versions Affected

Package Version
patch Availability
No items found.

Automatically patch vulnerabilities without upgrading

Fix Without Upgrading
Detect compatible fix
Apply safe remediation
Fix with a single pull request

CVSS Version

Severity
Base Score
CVSS Version
Score Vector
C
H
U
5.6
-
4.0
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:A/VC:N/VI:H/VA:H/SC:N/SI:H/SA:H/E:U/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
C
H
U
0
-
C
H
U
8.2
-
3.1
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:H

Related Resources

No items found.

References

https://nvd.nist.gov/vuln/detail/CVE-2025-13437, https://github.com/google/zx/issues/1348, https://github.com/google/zx/pull/1349, https://github.com/google/zx/pull/1355, https://github.com/google/zx/commit/9ef6d3c9962c4ba01e3fb8075855570c192b4681, https://github.com/google/zx/commit/a4d1bc2467f305f1c91d62506e215f307dc1fbeb, https://github.com/google/zx

Severity

8.2

CVSS Score
0
10

Basic Information

Ecosystem
Base CVSS
8.2
EPSS Probability
0.00008%
EPSS Percentile
0.00498%
Introduced Version
0,8.7.2,8.4.0-dev.539130a
Fix Available
8.8.5

Fix Critical Vulnerabilities Instantly

Secure your app without upgrading.
Fix Without Upgrading