Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessPass untrusted archivePath/targetDir to extract()
-
ExploitInject shell metacharacters into unquoted shelljs exec() string
-
ExecutionShell spawns attacker-controlled OS commands
-
ImpactExecute code with Node.js process privileges
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 that the application embedding @mborne/extract (versions before 0.2.1) passes attacker-controlled values as the archivePath or targetDir options to extract(), and that one of the affected code paths runs - the unzip, 7z, tar-bz2, or gz extractor (the 7z path additionally requires the 7z binary to be installed). The injected commands execute in the Node.js process's current working directory with its privileges. The key LIMITING factor is that this is a library with no standalone attack surface: if the integrating application only ever passes trusted, application-generated paths, the flaw is not reachable. There is no required user interaction or authentication within the library itself, but the vector depends entirely on the host application's input handling. |
| Impact | This is a textbook CWE-78 OS command injection in a Node.js library, scored 9.3 (CVSS 4.0: AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H). The source diff confirms the root cause: user-supplied archivePath/targetDir values were concatenated directly into unquoted shelljs exec() command strings across four extractors (unzip, 7z, tar-bz2, gz), so shell metacharacters and leading-dash option injection both work. The technical impact is high across confidentiality, integrity and availability because injected commands run with full Node.js process privileges. However, the raw CVSS signals OVERSTATE universal remote risk: this is a LIBRARY, not a network service. Exploitation requires the CONSUMING application to pass attacker-controlled values into extract(), so real-world severity is entirely dependent on how downstream apps wire user input (e.g., uploaded filenames) into these options. No EPSS score, KEV listing, or SSVC decision data was provided, and the product is an obscure individually-maintained npm package with a small deployment footprint - so despite the critical technical score, this is more likely a targeted/supply-chain concern than a mass-exploited internet-wide issue. The injection technique is fully disclosed in the public patch diff and committed security test, even though no separate exploit-availability flag was provided. |
| Exploit ScenarioDerived | A web application uses @mborne/extract to unpack user-uploaded archives and passes the uploaded filename or a user-chosen destination directly as archivePath or targetDir. An attacker uploads (or names) an archive like '-o a b;touch pwned;$(id)' so that when extract() builds the unquoted shelljs exec() string, the shell interprets the metacharacters and executes arbitrary commands with the Node.js process's privileges. The exact injection payloads are publicly demonstrated in the fix's committed security test, lowering the effort to reproduce. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Oct 14, 2026
OS command injection in @mborne/extract versions before 0.2.1 lets an attacker execute arbitrary shell commands with the Node.js process's privileges by supplying shell metacharacters in the archivePath or targetDir options passed to extract(). The flaw is unauthenticated (CVSS 4.0 vector AV:N/AC:L/AT:N/PR:N/UI:N) and scored 9.3, with full confidentiality, integrity, and availability impact to the host process, though it is a library with no standalone attack surface - it is only reachable when the integrating application forwards attacker-controlled values into one of the affected extractor paths (unzip, 7z, tar-bz2, or gz; the 7z path additionally requires the 7z binary). No public exploit code was identified at time of analysis, so exploitation is contingent on the host application's input handling rather than on any inherently exposed service.
RemediationAI
Vendor-released patch: upgrade @mborne/extract to 0.2.1, the first release containing the fix (see https://github.com/mborne/node-extract/releases/tag/v0.2.1). The change is available as GitHub PR https://github.com/mborne/node-extract/pull/8 and commit 585e5b29657379e73c04f6f950ea8dc5319f8ae1; the fix switches the unzip, 7z, tar-bz2, and gz extractors from shelljs exec() string concatenation to child_process.execFileSync with argument arrays, pipes gz output through a file descriptor instead of a shell redirect, and applies path.resolve() to archivePath and targetDir so values cannot be interpreted as command-line options. If an immediate upgrade is not possible, the actionable compensating controls are: validate and reject archivePath/targetDir values containing shell metacharacters or leading dashes, and force them to absolute, allowlisted paths inside a dedicated extraction directory before calling extract() - the trade-off is that overly strict rejection can break legitimate archives whose filenames contain spaces or special characters, so prefer an allowlist over a blocklist; never forward raw user input (HTTP parameters, uploaded metadata, filenames from untrusted manifests) directly into the options object; and run the embedding Node.js process with the least privilege and in a restricted working directory, since injected commands execute in that process's current working directory with its privileges. Disabling the affected extractor paths (for example, restricting to a single trusted extractor binary, or refusing the 7z path where the 7z binary is installed) reduces reachable attack surface at the cost of reduced archive-format coverage. Note there is no evidence of active exploitation in CISA KEV and no public exploit code identified at time of analysis, so patching cadence can follow normal library-dependency hygiene rather than emergency response.
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
The root cause is CWE-78 (OS Command Injection): the library's extractors built shell command strings by concatenating the caller-supplied archivePath and targetDir values into unquoted shelljs exec() invocations - for example 'unzip -o -d '+targetDir+' '+archivePath, '7z x -y '+archivePath+' -o'+targetDir, 'tar xf '+archivePath+' -C '+targetDir, and 'gunzip < '+archivePath+' > '+targetPath. Because the values were never quoted or escaped, shell metacharacters in either option were interpreted by the shell, and leading-dash values could also be misread as CLI options by the underlying tools. This is a Node.js/shelljs pattern issue rather than a flaw in unzip, 7z, tar, or gzip themselves; the affected code lives in src/extractor/unzip.js, 7z.js, tar-bz2.js, and gz.js, with the vulnerable string construction visible in the v0.2.0 source (unzip.js lines 17-19). The upstream fix replaces shell string interpolation with execFileSync plus argument arrays, routes gz output through a file descriptor instead of a shell redirection, and normalizes inputs with path.resolve() in ExtractParams.js so relative paths cannot be interpreted as command-line options; regression tests in test/security.js exercise filenames and targets containing metacharacters such as backticks, $( ) and semicolons.
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
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
Assuming a typical web app feeds untrusted upload filenames/paths into extract(), the vector is remote (AV:N) and low-complexity (AC:L); injection runs commands at the Node process level (C/I/A:H), with no CVSS scope change (S:U).
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
@mborne/extract before 0.2.1 contains an OS command injection vulnerability that allows attackers to execute commands by supplying shell metacharacters in archivePath or targetDir options. Attackers controlling these values passed to extract() can inject commands into unquoted shelljs exec() strings in the unzip, 7z, tar-bz2 and gz extractors, running them with Node.js process privileges.
Articles & Coverage 1
Executive ViewAI
The @mborne/extract library, used in Node.js applications for archive extraction, contains a critical OS command injection vulnerability that can allow unauthenticated attackers to execute arbitrary commands on the host server, potentially leading to full system compromise. Organizations using this library in their applications are at risk, particularly those that pass user-supplied input to extraction functions. This could result in data breaches, service disruption, or lateral movement within the network, and while no public exploit identified at time of analysis, the severity warrants immediate remediation.
Apply vendor patch.
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
The JS-YAML module before 2.0.5 for Node.js parses input without properly considering the unsafe !!js/function tag, whic
EUVD-2026-101267
GHSA-chf7-hjrj-qwh8
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB