{"id":"CVE-2023-32313","published":"2023-05-15T19:45:13Z","modified":"2025-01-22T21:42:56Z","title":"Inspect method manipulation in vm2","vendor":"patriksimek","product":"vm2","tier":"tail","description":{"text":"vm2 is a sandbox that can run untrusted code with Node's built-in modules. In versions 3.9.17 and lower of vm2 it was possible to get a read-write reference to the node `inspect` method and edit options for `console.log`. As a result a threat actor can edit options for the `console.log` command. This vulnerability was patched in the release of version `3.9.18` of `vm2`. Users are advised to upgrade. Users unable to upgrade may make the `inspect` method readonly with `vm.readonly(inspect)` after creating a vm.","provenance":"source","from":"CVE.org"},"cvss":{"score":5.3,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.0079,"percentile":0.56229,"provenance":"source"},"cwes":[{"id":"CWE-74","name":"Improper Neutralization of Special Elements in Output Used by a Downstream Component"}],"references":[{"url":"https://github.com/patriksimek/vm2/security/advisories/GHSA-p5gc-c584-jj6v","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/patriksimek/vm2/commit/5206ba25afd86ef547a2c9d48d46ca7a9e6ec238","tags":["x_refsource_MISC"]},{"url":"https://gist.github.com/arkark/c1c57eaf3e0a649af1a70c2b93b17550","tags":["x_refsource_MISC"]},{"url":"https://github.com/patriksimek/vm2/releases/tag/3.9.18","tags":["x_refsource_MISC"]}],"priority":{"score":15.0,"factors":[{"name":"EPSS percentile","points":11.25},{"name":"CVSS severity","points":3.71}]},"vendorSlug":"patriksimek","affectedVersions":[{"vendor":"patriksimek","product":"vm2","versions":["< 3.9.18"]}],"affected":[{"ecosystem":"npm","package":"vm2","vulnerableRanges":["<3.9.18"],"patched":["3.9.18"],"from":["GHSA-p5gc-c584-jj6v"],"provenance":"source"}],"euvd":{"id":"EUVD-2023-1591","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-patriksimek-vm2-cve-2021-23449","parents":[{"from":"CVE-2021-23555","to":"CVE-2023-32313","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["lib/vm.js"],"commits":["https://github.com/patriksimek/vm2/commit/532120d5cdec7da8225fc6242e154ebabc63fe4d","https://github.com/patriksimek/vm2/commit/5206ba25afd86ef547a2c9d48d46ca7a9e6ec238"],"basis":"rarely changed file"}]}],"packageHistory":[{"cve":"CVE-2023-29017","published":"2023-04-06","fixed":"3.9.15","kev":false},{"cve":"CVE-2023-29199","published":"2023-04-14","fixed":"3.9.16","kev":false},{"cve":"CVE-2023-30547","published":"2023-04-17","fixed":"3.9.17","kev":false,"link":{"from":"CVE-2023-30547","to":"CVE-2023-32313","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"npm:vm2","fromFixed":"3.9.17","toFixed":"3.9.18","daysApart":28}]}},{"cve":"CVE-2023-32313","published":"2023-05-15","fixed":"3.9.18","kev":false},{"cve":"CVE-2023-32314","published":"2023-05-15","fixed":"3.9.18","kev":false},{"cve":"CVE-2023-37466","published":"2023-07-13","fixed":"3.10.0","kev":false},{"cve":"CVE-2026-22709","published":"2026-01-26","fixed":"3.10.2","kev":false}],"package":"npm:vm2"}}