Skip to content
Heist/ feed
Back to feed
High

vm2: NodeVM require.root bypass via symlink traversal allows sandbox escape

Type: advisorySources: OSV

vm2 is an open source vm/sandbox for Node.js. In 3.10.5, NodeVM's require.root path restriction can be bypassed using filesystem symlinks, allowing sandboxed code to load modules from outside the allowed root directory in host context. Because path validation uses path.resolve() (which does not dereference symlinks) but module loading uses Node's native require() (which does), an attacker can load arbitrary host-realm modules and achieve remote code execution. This vulnerability is fixed in 3.11.0.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2026-43998
Confirmed fixed CVEs
Not specified
Updated in this feed
4 Nov 2026, 17:18 UTC · Revision 1

Source evidence

vm2: NodeVM require.root bypass via symlink traversal allows sandbox escape

core-osv · Original source

Published 13 May 2026, 17:19 UTC

vm2 is an open source vm/sandbox for Node.js. In 3.10.5, NodeVM's require.root path restriction can be bypassed using filesystem symlinks, allowing sandboxed code to load modules from outside the allowed root directory in host context. Because path validation uses path.resolve() (which does not dereference symlinks) but module loading uses Node's native require() (which does), an attacker can load arbitrary host-realm modules and achieve remote code execution. This vulnerability is fixed in 3.11.0.

osv:CVE-2026-43998
Complete source record
{
  "id": "791a59999f90f15ee5d5cea73ef60dde196cb2560eff4d816a56a9b46929c053",
  "url": "https://osv.dev/vulnerability/CVE-2026-43998",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "vm2: NodeVM require.root bypass via symlink traversal allows sandbox escape",
    "summary": "vm2 is an open source vm/sandbox for Node.js. In 3.10.5, NodeVM's require.root path restriction can be bypassed using filesystem symlinks, allowing sandboxed code to load modules from outside the allowed root directory in host context. Because path validation uses path.resolve() (which does not dereference symlinks) but module loading uses Node's native require() (which does), an attacker can load arbitrary host-realm modules and achieve remote code execution. This vulnerability is fixed in 3.11.0.",
    "evidence": "osv:CVE-2026-43998",
    "products": [],
    "severity": "high",
    "structured": {
      "id": "CVE-2026-43998",
      "aliases": [
        "CVE-2026-43998",
        "GHSA-cp6g-6699-wx9c"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/patriksimek/vm2",
              "type": "GIT",
              "events": [
                {
                  "introduced": "408fc855f1cc1bbc2985b029465ee0e732ada433"
                },
                {
                  "last_affected": "408fc855f1cc1bbc2985b029465ee0e732ada433"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "range": [
                      {
                        "introduced": "3.10.5"
                      },
                      {
                        "last_affected": "3.10.5"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "StandaloneSingleVersion"
                  },
                  {
                    "cpe": "cpe:2.3:a:vm2_project:vm2:3.10.5:*:*:*:*:node.js:*:*",
                    "range": [
                      {
                        "introduced": "3.10.5"
                      },
                      {
                        "last_affected": "3.10.5"
                      }
                    ],
                    "source": "CPE_STRING"
                  }
                ]
              }
            }
          ],
          "versions": [
            "3.10.5",
            "v3.10.5"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-43998.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:37.958057307Z",
      "provider": "osv",
      "references": [
        "https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-43998.json",
        "https://access.redhat.com/errata/RHSA-2026:50850",
        "https://access.redhat.com/security/cve/CVE-2026-43998",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/43xxx/CVE-2026-43998.json",
        "https://github.com/patriksimek/vm2/security/advisories/GHSA-cp6g-6699-wx9c",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-43998",
        "https://bugzilla.redhat.com/show_bug.cgi?id=2477206"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-59"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/43xxx/CVE-2026-43998.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-43998",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 505243,
  "published_at": "2026-05-13T17:19:44.406+00:00"
}