Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. vm2
  4. ›
  5. CVE-2026-92951

CVE-2026-92951: vm2 Custom Module Resolver Can Bypass the External Package Allowlist by Loading a Colliding Host Package

October 1, 2026 (updated October 8, 2026)

vm2 is a sandbox library for isolating and executing untrusted JavaScript code inside a Node.js process. It can restrict access to built-in modules and external packages.

When NodeVM enables an external allowlist together with a custom resolve callback, vm2 checks the requested package name with a non-exact match. For example, if the allowlist only permits left-pad, an attacker can still bypass the check with a colliding package name such as evil-left-pad, because it contains the allowlisted name.

If the colliding package already exists in a host path resolvable by the custom resolver, or if the target application’s custom resolver / dependency-management workflow downloads the package and places it in a resolvable path, vm2 loads and executes that package in the host context. This lets sandboxed code bypass the module allowlist and may further lead to host code execution.

References

  • github.com/advisories/GHSA-c48m-32m9-vx93
  • github.com/patriksimek/vm2/commit/ab4ee7d803e8c80155e9eb3672226bddbca4aa9c
  • github.com/patriksimek/vm2/releases/tag/v3.11.7
  • github.com/patriksimek/vm2/security/advisories/GHSA-c48m-32m9-vx93
  • nvd.nist.gov/vuln/detail/CVE-2026-92951
  • www.vulncheck.com/advisories/vm2-before-3.11.7-module-allowlist-bypass-via-custom-resolver

Code Behaviors & Features

Detect and mitigate CVE-2026-92951 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 3.11.7

Fixed versions

  • 3.11.7

Solution

Upgrade to version 3.11.7 or above.

Impact 9.9 CRITICAL

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-706: Use of Incorrectly-Resolved Name or Reference
  • CWE-829: Inclusion of Functionality from Untrusted Control Sphere
  • CWE-863: Incorrect Authorization

Source file

npm/vm2/CVE-2026-92951.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Mon, 12 Oct 2026 00:22:38 +0000.