{"id":"CVE-2023-40582","aliases":["CVE-2023-40582","GHSA-95rp-6gqp-6622"],"related":[],"kind":"vulnerability","state":"published","title":"Command Injection Vulnerability in find-exec","summary":"find-exec is a utility to discover available shell commands. Versions prior to 1.0.3 did not properly escape user input and are vulnerable to Command Injection via an attacker controlled parameter. As a result, attackers may run malicious shell commands in the context of the running process. This issue has been addressed in version 1.0.3. users are advised to upgrade. Users unable to upgrade should ensure that all input passed to find-exec comes from a trusted source.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"find-exec is a utility to discover available shell commands. Versions prior to 1.0.3 did not properly escape user input and are vulnerable to Command Injection via an attacker controlled parameter. As a result, attackers may run malicious shell commands in the context of the running process. This issue has been addressed in version 1.0.3. users are advised to upgrade. Users unable to upgrade should ensure that all input passed to find-exec comes from a trusted source.","source":"cvelist"},{"lang":"en","text":"Older versions of the package are vulnerable to Command Injection as an attacker controlled parameter. As a result, attackers may run malicious commands.\n\nFor example:\n\n```\nconst find = require(\"find-exec\");\nfind(\"mplayer; touch hacked\")\n```\n\nThis creates a file named \"hacked\" on the filesystem.\n\nYou should never allow users to control commands to find, since this package attempts to run every command provided.\n\nThanks to @miguelafmonteiro for reporting.","format":"markdown","source":"ghsa"},{"lang":"es","text":"find-exec es una utilidad para descubrir comandos de shell disponibles. Las versiones anteriores a la 1.0.3 no escapaban correctamente la entrada del usuario y son vulnerables a la inyección de comandos a través de un parámetro controlado por un atacante. Como resultado, los atacantes pueden ejecutar comandos de shell maliciosos en el contexto del proceso en ejecución. Este problema ha sido abordado en la versión 1.0.3. Se aconseja a los usuarios actualizar. Los usuarios que no puedan actualizar deben asegurarse de que toda la entrada pasada a find-exec provenga de una fuente confiable.","source":"nvd"}],"published":"2023-08-30T17:39:20.849Z","modified":"2026-06-17T06:18:34.207Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"}],"cwes":["CWE-78"],"affected":[{"ranges":[{"version":"< 1.0.3","status":"affected"}],"vendor":"shime","product":"find-exec","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"1.0.3"}],"ecosystem":"npm","package":"find-exec","purl":"pkg:npm/find-exec","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"1.0.3"}],"vendor":"find-exec_project","product":"find-exec","cpe":"cpe:2.3:a:find-exec_project:find-exec:*:*:*:*:*:node.js:*:*","source":"nvd"}],"references":[{"url":"https://github.com/shime/find-exec/security/advisories/GHSA-95rp-6gqp-6622","tags":["vendor-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/shime/find-exec/commit/74fb108097c229b03d6dba4cce81e36aa364b51c","tags":["patch","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2023-40582","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/shime/find-exec","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"total","date":"2024-10-01T18:13:32.639Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2023-40582","url":"https://www.cve.org/CVERecord?id=CVE-2023-40582","licence":"CVE Terms of Use","modified":"2024-10-01T18:13:41.300Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-95rp-6gqp-6622","url":"https://github.com/advisories/GHSA-95rp-6gqp-6622","licence":"CC-BY-4.0","modified":"2023-11-08T04:13:22.108Z"},{"source":"nvd","name":"NVD","id":"CVE-2023-40582","url":"https://nvd.nist.gov/vuln/detail/CVE-2023-40582","licence":"Public domain","modified":"2026-06-17T06:18:34.207Z"}],"updatedAt":"2026-11-25T22:58:27.452Z","epss":{"score":0.01801,"percentile":0.79144,"date":"2026-12-01T12:00:22.000Z"}}