{"id":"CVE-2026-32304","published":"2026-03-12T21:24:51Z","modified":"2026-07-15T01:08:07Z","title":"Locutus: RCE via unsanitized input in create_function()","vendor":"locutusjs","product":"locutus","tier":"tail","description":{"text":"Locutus brings stdlibs of other programming languages to JavaScript for educational purposes. Prior to 3.0.14, the create_function(args, code) function passes both parameters directly to the Function constructor without any sanitization, allowing arbitrary code execution. This is distinct from CVE-2026-29091 which was call_user_func_array using eval() in v2.x. This finding affects create_function using new Function() in v3.x. This vulnerability is fixed in 3.0.14.","provenance":"source","from":"CVE.org"},"cvss":{"score":9.8,"severity":"CRITICAL","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00647,"percentile":0.51954,"provenance":"source"},"cwes":[{"id":"CWE-94","name":"Improper Control of Generation of Code"},{"id":"CWE-88","name":"Improper Neutralization of Argument Delimiters in a Command"}],"references":[{"url":"https://github.com/locutusjs/locutus/security/advisories/GHSA-vh9h-29pq-r5m8","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/locutusjs/locutus/releases/tag/v3.0.14","tags":["x_refsource_MISC"]},{"url":"https://access.redhat.com/security/cve/CVE-2026-32304","tags":["vdb-entry","x_refsource_REDHAT"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2447200","tags":["issue-tracking","x_refsource_REDHAT"]},{"url":"https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-32304.json","tags":["x_sadp-csaf-vex"]}],"priority":{"score":17.3,"factors":[{"name":"EPSS percentile","points":10.39},{"name":"CVSS severity","points":6.86}]},"vendorSlug":"locutusjs","affectedVersions":[{"vendor":"locutusjs","product":"locutus","versions":["< 3.0.14"]}],"ssvc":{"exploitation":"poc","automatable":"yes","technicalImpact":"total","timestamp":"2026-03-13T13:12:02.296127Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"npm","package":"locutus","vulnerableRanges":["<3.0.14"],"patched":["3.0.14"],"from":["GHSA-vh9h-29pq-r5m8"],"provenance":"source"}],"summary":{"text":"The flaw is in the create_function(args, code) function of the Locutus JavaScript stdlib library (product \"locutus\", vendor locutusjs), in versions before 3.0.14, where both parameters are passed straight to the Function constructor without sanitization. An attacker who can supply input to create_function can execute arbitrary code.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T20:50:12Z"},"euvd":{"id":"EUVD-2026-11718","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2021-23392","published":"2021-06-08","fixed":"2.0.15","kev":false},{"cve":"CVE-2026-25521","published":"2026-02-04","fixed":"2.0.39","kev":false},{"cve":"CVE-2026-29091","published":"2026-03-06","fixed":"3.0.0","kev":false,"link":{"from":"CVE-2026-29091","to":"CVE-2026-32304","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"npm:locutus","fromFixed":"3.0.0","toFixed":"3.0.14","daysApart":6}]}},{"cve":"CVE-2026-32304","published":"2026-03-12","fixed":"3.0.14","kev":false},{"cve":"CVE-2026-33993","published":"2026-03-27","fixed":"3.0.25","kev":false,"link":{"from":"CVE-2026-32304","to":"CVE-2026-33993","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"npm:locutus","fromFixed":"3.0.14","toFixed":"3.0.25","daysApart":15}]}},{"cve":"CVE-2026-33994","published":"2026-03-27","fixed":"3.0.25","kev":false,"link":{"from":"CVE-2026-32304","to":"CVE-2026-33994","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"npm:locutus","fromFixed":"3.0.14","toFixed":"3.0.25","daysApart":15}]}}],"package":"npm:locutus"}}