CVE-2024-21488: Network Network Arbitrary Command Injection Vulnerability Vulnerability
HIGHCVE-2024-21488 is a HIGH (CVSS 7.3) network arbitrary command injection vulnerability vulnerability (CWE-77: Improper Neutralization of Special Elements used in a Command ('Command Injection')) affecting Network libraries in the npm ecosystem. The issue involves network arbitrary command injection vulnerability. Remediation is available by upgrading affected packages to version 0.7.0.
CVE-2024-21488 at a Glance
Security Impact
CVSS: 7.3
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L).
How to Fix CVE-2024-21488
To remediate this vulnerability, upgrade all affected Network dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install network@0.7.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls network
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2024-21488, inspect your project dependencies using npm:
npm ls network
Analyze the terminal output to locate any version of Network in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.7.0), your application is affected.
Note: The npm ls network 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-77: Improper Neutralization of Special Elements used in a Command ('Command Injection'), where the product constructs all or part of a command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended command when it is sent to a downstream component. In Network, 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
CVE-2024-21488 Affected Network Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
network
|
npm |
< 0.7.0
|
0.7.0
|
References
Frequently Asked Questions
What is CVE-2024-21488?
Which Network versions are affected?
What version fixes CVE-2024-21488?
Is network affected?
What is the CVSS score of CVE-2024-21488?
What CWE is associated with CVE-2024-21488?
How can I check npm dependencies for CVE-2024-21488?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-vvh2-82c7-ppfg",
"modified" : "2024-01-30T18:43:05Z",
"published" : "2024-01-30T06:30:23Z",
"aliases" : [ "CVE-2024-21488" ],
"summary" : "network Arbitrary Command Injection vulnerability",
"details" : "Versions of the package network before 0.7.0 are vulnerable to Arbitrary Command Injection due to use of the `child_process` exec function without input sanitization. If (attacker-controlled) user input is given to the `mac_address_for` function of the package, it is possible for an attacker to execute arbitrary commands on the operating system that this package is being run on.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "network"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.7.0"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-21488"
}, {
"type" : "WEB",
"url" : "https://github.com/tomas/network/commit/5599ed6d6ff1571a5ccadea775430c131f381de7"
}, {
"type" : "WEB",
"url" : "https://github.com/tomas/network/commit/6ec8713580938ab4666df2f2d0f3399891ed2ad7"
}, {
"type" : "WEB",
"url" : "https://github.com/tomas/network/commit/72c523265940fe279eb0050d441522628f8988e5"
}, {
"type" : "WEB",
"url" : "https://gist.github.com/icemonster/282ab98fb68fc22aac7c576538f6369c"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/tomas/network"
}, {
"type" : "WEB",
"url" : "https://security.snyk.io/vuln/SNYK-JS-NETWORK-6184371"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-77" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2024-01-30T18:43:05Z",
"nvd_published_at" : "2024-01-30T05:15:09Z"
}
}