CVE-2026-49406CWE-22

Deno: BYONM module resolution allows `package.json` main path traversal to bypass `--allow-read` restrictions

Medium · published June 23, 2026

CVSS v3.1
5.5
EPSS
0%
Percentile
6.7
In the wild
Unconfirmed
What it is

Deno is a JavaScript, TypeScript, and WebAssembly runtime. Prior to 2.7.12, when Deno was run in BYONM mode (nodeModulesDir: "manual"), the module resolver did not validate that a package's resolved entrypoint stayed within its node_modules/<pkg>/ directory. A malicious package.json whose main field contained .. segments was able to resolve to an arbitrary path on disk, and the resolver then read that file without consulting the --allow-read allowlist. This let a require("evil-pkg") call return the contents of a file that a direct Deno.readTextFileSync(...) call would have been blocked from reading. This vulnerability is fixed in 2.7.12.

The record
Technical detail
CVSS v3.1
5.5 · MEDIUM
Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
CVSS v4.0
Not supplied
EPSS
0.00176 · 6.7th percentile
Weakness
CWE-22 · Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
Published
2026-06-23T17:19Z
EPSS history
Timeline
  • 23 JUN 17:19Z
    Deno: BYONM module resolution allows `package.json` main path traversal to bypass `--allow-read` restrictions
    cvelistv5