CVE-2026-49859: Deno `fetch()` API Sandbox Bypass Vulnerability
MODERATECVE-2026-49859 is a MODERATE (CVSS 5.2) `fetch()` api sandbox bypass vulnerability (CWE-693: Protection Mechanism Failure) affecting Deno libraries in the crates.io ecosystem. The issue involves `fetch()` api sandbox bypass via missing dns resolution check. Remediation is available by upgrading affected packages to version 2.8.1.
CVE-2026-49859 at a Glance
Security Impact
CVSS: 5.2
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N).
How to Fix CVE-2026-49859
To remediate this vulnerability, upgrade all affected Deno dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade deno to 2.8.1
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for deno
How to Check if You Are Affected
To determine whether your application is affected by CVE-2026-49859, inspect your project dependencies for Deno:
inspect dependencies for deno
Analyze the terminal output to locate any version of Deno in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.8.1), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-693: Protection Mechanism Failure, where the product does not use or incorrectly uses a protection mechanism that provides sufficient defense against directed attacks against the product. In Deno, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2026-49859 Affected Deno Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
deno
|
crates.io |
< 2.8.1
|
2.8.1
|
References
Frequently Asked Questions
What is CVE-2026-49859?
Which Deno versions are affected?
What version fixes CVE-2026-49859?
Is deno affected?
What is the CVSS score of CVE-2026-49859?
What CWE is associated with CVE-2026-49859?
How can I check crates.io dependencies for CVE-2026-49859?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-cpgj-f7g3-2pp2",
"modified" : "2026-07-20T21:01:14Z",
"published" : "2026-06-16T19:02:55Z",
"aliases" : [ "CVE-2026-49859" ],
"summary" : "Deno: `fetch()` API sandbox bypass via missing DNS resolution check",
"details" : "## Summary\n\nWhen `fetch()` was called, Deno checked the destination hostname against\n`--deny-net` rules but did not re-check the IP addresses that hostname\nresolved to. An attacker-controlled script could use a specially crafted domain\nname that passes the hostname check yet resolves to a denied IP, bypassing the\nnetwork restriction entirely.\n\n## Impact\n\nCode running under `--deny-net` could reach hosts that the user intended to\nblock. In practice this means network isolation rules — for example, blocking\naccess to `localhost` or internal services — could be silently circumvented by\na malicious or compromised dependency.\n\nA companion advisory covers the same class of issue in the WebSocket API.\n\n## Who is affected\n\nUsers who:\n\n- run untrusted or third-party code with `deno run`, and\n- rely on `--deny-net` to restrict which hosts that code can reach.\n\nIf you do not use `--deny-net`, or if you only run fully trusted code, you are\nnot affected.\n\n## Workaround\n\nNo workaround is available short of upgrading. If upgrading immediately is not\npossible, avoid granting `--allow-net` to untrusted code that also has\n`--deny-net` restrictions you depend on for security.\n\n## Fix\n\nThe `fetch()` DNS resolver now performs a post-resolution check on every IP\naddress before passing it to the HTTP connector, consistent with how\n`Deno.connect` already behaved.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "crates.io",
"name" : "deno"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.8.1"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "<= 2.8.0"
}
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/denoland/deno/security/advisories/GHSA-cpgj-f7g3-2pp2"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-49859"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/denoland/deno"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-693", "CWE-918" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2026-06-16T19:02:55Z",
"nvd_published_at" : "2026-06-23T18:18:03Z"
}
}