Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSupply untrusted data to app input
-
DeliveryData reaches cross-spawn args on Windows
-
Exploitcross-spawn mis-escapes command for cmd.exe
-
Executioncmd.exe resolves and runs batch file
-
ImpactMetacharacters execute arbitrary commands
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization OS command sanitization, avoid shell exec
MITRE ATT&CK
2 techniques across 1 tactic: Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires ALL of the following to hold simultaneously: the application runs on Windows; it invokes cross-spawn (vulnerable versions >=7.0.0 <7.1.1 or >=6.0.0 <6.0.8) with a command that is NOT a plain program name or path - specifically one containing double quotes (e.g. '"tool.bat"'), a space/tab/comma/semicolon/equals that cmd.exe treats as a command-name delimiter (e.g. 'npm install' resolving to npm.cmd), trailing whitespace, or a PATHEXT passed in options.env that makes cmd.exe locate a batch file the parent's PATHEXT would not; AND it passes untrusted input into the args array. Limiting factors: the canonical safe pattern spawn('npm', ['install', ...]) with no quotes and no custom PATHEXT is NOT affected, so most well-written callers are immune; the vulnerability does not apply to non-Windows platforms; and it is a library defect whose reachability by an attacker depends on the host application exposing untrusted data to those specific command forms. The only complete fix stated by the vendor is upgrading to 7.1.1 or 6.0.8; the documented workaround is to pass the bare program as the command with arguments in args and not set PATHEXT in options.env. |
| Impact | This is a real but conditional priority rather than a drop-everything emergency. The CVSS 3.1 vector (AV:N/AC:H/PR:N/UI:N, C:H/I:H/A:H, base 8.1 High) reflects that successful exploitation yields full command execution, but the AC:H already signals that the path is narrow: the flaw only manifests on Windows, only when the consuming application runs commands through cmd.exe in a non-plain form (quotes, a space/tab/comma/semicolon/equals delimiter, trailing whitespace, or a child-specific PATHEXT), and only when untrusted input reaches the argument list. No EPSS score, KEV listing, or verified exploit code is present in the input, so there is no evidence of active or widespread exploitation; the signal is driven by the vendor (GitHub Security Advisory) and the vuln.today 'this_week' decision label rather than by exploitation telemetry. The PR:N (unauthenticated) metric describes the library in the abstract - whether an attacker needs authentication depends entirely on the host application that passes untrusted data into the spawned argument, which the library-level CVSS cannot capture. Bottom line: genuinely dangerous for the specific subset of Windows Node.js applications that use the affected spawn forms with attacker-controlled arguments, but the real-world exploitable population is far smaller than the 8.1 score and 'ubiquitous' package footprint alone would imply. |
| Exploit ScenarioDerived | A Windows-hosted Node.js application uses cross-spawn to launch a command written as something other than a plain program name (for example spawn('npm install', args) or a quoted/path form that resolves to a .bat/.cmd via cmd.exe) and places user-supplied data into the args array. cross-spawn fails to detect that cmd.exe will run a batch file, so it escapes the arguments as for a regular program, leaving cmd metacharacters live; an attacker submits an argument such as '"&calc' (or '" & echo injected & "') and cmd.exe interprets it, executing arbitrary commands. No public exploit code is identified in the sources, though the advisory and patched test suite document the exact triggering payloads. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Nov 30, 2026
Windows command injection in the Node.js cross-spawn library allows untrusted argument data to be interpreted by cmd.exe when callers pass commands that are not plain program names or paths. Affected are versions 7.0.0 through 7.1.0 and 6.0.0 through 6.0.7 running on Windows that pass untrusted input in the args array alongside commands containing double quotes, name delimiters (space, tab, comma, semicolon, equals), trailing whitespace, or a custom PATHEXT. The trigger is conditional on those specific command forms and Windows deployment; the canonical spawn('npm', ['install', ...]) pattern with no quotes and no custom PATHEXT is not affected. No confirmed active exploitation or public exploit code has been reported, and the vendor provides fixed versions 7.1.1 and 6.0.8.
RemediationAI
Upgrade cross-spawn to 7.1.1 or 6.0.8 (fix commits and PRs 196 and 197; releases v7.1.1 and v6.0.8). Applications that cannot upgrade immediately should apply the vendor-documented workaround: pass the bare program name as the command and its arguments in the args array without quotes, for example spawn('npm', ['install', ...]), and do not set PATHEXT in options.env; this avoids every bypass condition but requires auditing and changing call sites that currently use quoted commands, embedded arguments, or custom PATHEXT. Forcing the fixed version through npm overrides in package.json is an option for transitive dependents. Versions before 6.0.0 are unmaintained and receive no fix, so projects still on those releases must migrate to a supported branch.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
cross-spawn normalizes child_process.spawn behavior across platforms, and on Windows it must route non-executable targets such as .bat and .cmd files through cmd.exe. Because cmd.exe re-parses batch file arguments, batch targets require stricter escaping than regular programs; an earlier fix (GHSA-ghv9-86vm-4v8m) applied that stricter escaping only when cross-spawn detected the target as a batch file. This CVE, a CWE-78 OS command injection, stems from that detection being evadable: cmd.exe ignores double quotes in command names, terminates the name at the first space, tab, comma, semicolon or equals sign even when escaped with ^, treats trailing whitespace loosely, and resolves the executable using the child environment's PATHEXT rather than the parent's. In each case cross-spawn believed it was launching a regular program and escaped arguments accordingly, so metacharacters in an argument (for example "&calc) were interpreted by cmd.exe. The upstream fix in PR 196 (7.x) and PR 197 (6.x) always quotes the command before it reaches cmd.exe so the name is treated as a single token, strips double quotes from the command since Windows filenames cannot contain them, broadens the trailing-whitespace regexp from /[. ]+$/ to /[.\s]+$/, and resolves the command using the child's PATHEXT via a new getPathExt helper. A behavioral consequence is that spawn('npm install') now fails with ENOENT as it does on other platforms.
Know when Node.js gets its next vulnerability
- 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
AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
AC:H because exploitation needs a specific non-plain command form on Windows plus attacker-controlled args; PR:N/UI:N because the library imposes no auth or interaction, and command injection yields full C/I/A.
Primary rating from Vendor (github).
CVSS VectorVendor: github
Lifecycle Timeline
2DescriptionCVE.org
cross-spawn is a cross-platform solution for Node.js spawn and spawnSync. Prior to 6.0.8 and 7.1.1, applications running on Windows that pass untrusted arguments can be vulnerable when a command sent through cmd.exe is not written as a plain program name or path. Commands containing quotes, command-name delimiters, trailing whitespace, or a child-specific PATHEXT could cause cross-spawn to miss that cmd.exe would resolve a batch file. The arguments were then escaped as though the target were a regular program, allowing command metacharacters in an argument to be interpreted by cmd.exe and execute arbitrary commands. Applications are affected only when they use one of these command forms and pass untrusted input as arguments. This issue is fixed in versions 6.0.8 and 7.1.1.
Technical POC Analysis
CWE-78: Improper Neutralization of Special Elements used in an OS Command.
Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.
Executive ViewAI
CVE-2026-137197 is a high-severity command injection vulnerability in the widely-used Node.js cross-spawn library that could allow attackers to execute arbitrary commands on Windows systems when untrusted input reaches the args array under specific conditions. This affects many Node.js applications and build pipelines, potentially compromising the software supply chain, developer workstations, and production servers-demanding immediate leadership attention and coordinated remediation across engineering and security teams.
No vendor-released patch identified at time of analysis. Interim mitigations: avoid passing untrusted input in the args array to cross-spawn, especially when commands contain double quotes, name delimiters (space, tab, comma, semicolon, equals), trailing whitespace, or when a custom PATHEXT is set; upgrade to fixed versions 7.1.1 or 6.0.8; restrict execution of Node.js applications on Windows to trusted inputs; monitor for anomalous command execution; and apply network segmentation or application allowlisting to limit the blast radius.
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
OS command injection occurs when an application passes unsanitized user input directly into system shell commands.
Remote code execution in n8n's workflow expression evaluation system allows an authenticated user with workflow creation
A vulnerability in the NuPoint Unified Messaging (NPM) component of Mitel MiCollab through 9.8 SP1 FP2 (9.8.1.201) could
FortiOS and FortiProxy contain an authentication bypass via the Node.js websocket module allowing unauthenticated remote
Denial of service against HTTP/2 server implementations allows remote unauthenticated attackers to exhaust server resour
Eval injection vulnerability in the internals.batch function in lib/batch.js in the bassmaster plugin before 1.5.2 for t
Flowise version 3.0.5 contains a remote code execution vulnerability in the CustomMCP node. The mcpServerConfig paramete
Node.js 8.5.0 before 8.6.0 allows remote attackers to access unintended files, because a change to ".." handling was inc
An issue was discovered in the node-serialize package 0.0.4 for Node.js. Rated critical severity (CVSS 9.8), this vulner
OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph
Directory traversal vulnerability in the st module before 0.2.5 for Node.js allows remote attackers to read arbitrary fi
Multiple SQL injection vulnerabilities in the Manage Accounts page in the AccountManagement.asmx service in the Solarwin
A vulnerability in NuPoint Messenger (NPM) of Mitel MiCollab through 9.8.0.33 allows an unauthenticated attacker to cond
EUVD-2026-139682
NVD
CVE.org
EPSS
GitHub
Exploit-DB