{"id":"CVE-2021-23348","aliases":["CVE-2021-23348","GHSA-vm67-7vmg-66vm","SNYK-JS-PORTPROCESSES-1078536"],"related":[],"kind":"vulnerability","state":"published","title":"Arbitrary Command Injection","summary":"This affects the package portprocesses before 1.0.5. If (attacker-controlled) user input is given to the killProcess function, it is possible for an attacker to execute arbitrary commands. This is due to use of the child_process exec function without input sanitization.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"This affects the package portprocesses before 1.0.5. If (attacker-controlled) user input is given to the killProcess function, it is possible for an attacker to execute arbitrary commands. This is due to use of the child_process exec function without input sanitization.","source":"cvelist"},{"lang":"en","text":"### Impact\n\nAn Arbitrary Command Injection vulnerability was reported in `portprocesses` impacting versions <= 1.0.4.\n\n### Example (Proof of Concept)\n\nThe following example demonstrates the vulnerability and will run `touch success` therefore creating a file named `success`.\n\n```js\nconst portprocesses = require(\"portprocesses\");\n\nportprocesses.killProcess(\"$(touch success)\");\n```","format":"markdown","source":"ghsa"},{"lang":"es","text":"Esto afecta a los paquetes portprocesses versiones anteriores a 1.0.5.&#xa0;Si es proporcionada una entrada del usuario (controlada por el atacante) para la función killProcess, es posible para un atacante ejecutar comandos arbitrarios.&#xa0;Esto es debido al uso de la función exec child_process sin un saneamiento de la entrada.","source":"nvd"}],"published":"2021-03-31T14:25:17.671Z","modified":"2026-09-10T03:49:04.006Z","severity":{"scorer":"snyk","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L/E:P","score":6.3,"rating":"MEDIUM"},"severities":[{"scorer":"snyk","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L/E:P","score":6.3,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N","score":6.4,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:L/Au:S/C:P/I:P/A:P","score":6.5,"rating":"MEDIUM"}],"cwes":["CWE-77","CWE-78"],"affected":[{"ranges":[{"type":"custom","introduced":"unspecified","fixed":"1.0.5","status":"affected"}],"product":"portprocesses","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"1.0.5"}],"ecosystem":"npm","package":"portprocesses","purl":"pkg:npm/portprocesses","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"1.0.5"}],"vendor":"portprocesses_project","product":"portprocesses","cpe":"cpe:2.3:a:portprocesses_project:portprocesses:*:*:*:*:*:node.js:*:*","source":"nvd"}],"references":[{"url":"https://snyk.io/vuln/SNYK-JS-PORTPROCESSES-1078536","tags":["exploit","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/rrainn/PortProcesses/blob/fffceb09aff7180afbd0bd172e820404b33c8299/index.js%23L23","tags":["broken-link","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/rrainn/PortProcesses/security/advisories/GHSA-vm67-7vmg-66vm","tags":["exploit","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/rrainn/PortProcesses/commit/86811216c9b97b01b5722f879f8c88a7aa4214e1","tags":["patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-23348","tags":["advisory"],"sources":["ghsa"]}],"credits":["OmniTaint"],"assigner":"snyk","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2021-23348","url":"https://www.cve.org/CVERecord?id=CVE-2021-23348","licence":"CVE Terms of Use","modified":"2024-09-16T20:52:54.111Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-vm67-7vmg-66vm","url":"https://github.com/advisories/GHSA-vm67-7vmg-66vm","licence":"CC-BY-4.0","modified":"2026-09-10T03:49:04.006Z"},{"source":"nvd","name":"NVD","id":"CVE-2021-23348","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-23348","licence":"Public domain","modified":"2026-06-17T03:38:36.100Z"}],"updatedAt":"2026-11-25T22:58:00.520Z","epss":{"score":0.0182,"percentile":0.79376,"date":"2026-12-01T12:00:22.000Z"}}