Katalog CVE

CVE-2026-93603

KrytyczneCVSS 10.0
Opublikowano: Zaktualizowano: Przetłumaczono: NVD NIST

Streszczenie

Podatność w vm2 do wersji 3.12.0 (naprawiona w 3.12.1) dotyczy nieprawidłowej obsługi odbiorcy `this` o wartości null w pułapce apply mostka. Gdy kod w sandboxie wywołuje funkcję hosta w trybie nieścisłym bez odbiorcy, niezdefiniowany odbiorca jest przekazywany do hosta, a V8 podstawia globalny obiekt domeny hosta. vm2 zwraca ten obiekt do sandboxa, co umożliwia pełną ucieczkę i dostęp do procesu. Wymaga to, aby aplikacja udostępniała co najmniej jedną funkcję hosta w trybie nieścisłym.

Ocena ryzyka

Atakujący może uzyskać dostęp do globalnego obiektu hosta i wykonać dowolny kod, co grozi przejęciem systemu.

Rekomendacja

Zaktualizuj vm2 do wersji 3.12.1 lub nowszej. Jeśli to niemożliwe, nie udostępniaj funkcji hosta w trybie nieścisłym.

Inne podatności w vm2

Zobacz wszystkie
Oryginalny opis (angielski, źródło NVD)

vm2 through 3.12.0 (fixed in 3.12.1) does not correctly handle a nullish `this` receiver in the apply trap of its bridge (lib/bridge.js): when sandboxed code calls a host-provided non-strict (sloppy-mode) function without a receiver — e.g. `fn()`, a detached method, `fn.call()`, `fn.apply(undefined)`, `Reflect.apply(fn, undefined, [])`, or `fn.bind()()` — the undefined receiver is passed straight through to the host call, and V8 substitutes the host realm's global object for `this`. vm2 then wraps and returns that object to the sandbox, giving sandboxed script a live proxy of the host global. This allows a complete sandbox escape: untrusted script can reach `process` and execute arbitrary code/commands on the host (for example via `process.getBuiltinModule('child_process').execSync`). Exploitation requires that the embedding application expose at least one non-strict host function to the sandbox; strict-mode and ES module host functions are not affected.

Dane podatności pochodzą z NVD (NIST) · CISA KEV · EPSS