CVE-2026-137198

cross-spawn: Argument injection on Windows via backslashes before a double quote

Published Nov 30, 2026 CVSS 4.0 · 8.3 High EPSS n/a KEV · Not listed
Description
cross-spawn is a cross-platform solution for Node.js spawn and spawnSync. From 6.0.6 until 6.0.7 and from 7.0.4 until 7.1.0, Windows applications that pass untrusted arguments to commands routed through cmd.exe can be vulnerable because cross-spawn did not correctly double runs of backslashes before a double quote or at the end of an argument. Two or more backslashes could escape the argument's closing quote, allowing attacker-controlled text to become extra arguments or consume following arguments. The caller may not detect the injection when the target accepts the resulting arguments and exits successfully, while a target that rejects an unexpected argument can fail instead. The affected command class includes npm cmd-shims in node_modules/.bin. This can change a target program's operation, although it does not by itself execute a second command and does not affect other platforms. This issue is fixed in versions 6.0.7 and 7.1.0.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Description cross-spawn is a cross-platform solution for Node.js spawn and spawnSync. From 6.0.6 until 6.0.7 and from 7.0.4 until 7.1.0, Windows applications that pass untrusted arguments to commands routed through cmd.exe can be vulnerable because cross-spawn did not correctly double runs of backslashes before a double quote or at the end of an argument. Two or more backslashes could escape the argument's closing quote, allowing attacker-controlled text to become extra arguments or consume following arguments. The caller may not detect the injection when the target accepts the resulting arguments and exits successfully, while a target that rejects an unexpected argument can fail instead. The affected command class includes npm cmd-shims in node_modules/.bin. This can change a target program's operation, although it does not by itself execute a second command and does not affect other platforms. This issue is fixed in versions 6.0.7 and 7.1.0.
Title cross-spawn: Argument injection on Windows via backslashes before a double quote
Weaknesses CWE-88
References
Metrics cvssV4_0

{'score': 8.3, 'vector': 'CVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:H/VA:L/SC:N/SI:N/SA:N'}

Subscriptions

No data.

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Nov 30, 2026, 8:36 PM
Reserved
Nov 25, 2026, 9:33 PM
Status
Received
Published
Nov 30, 2026, 9:17 PM
Modified
Nov 30, 2026, 9:17 PM