{"id":"CVE-2026-22864","aliases":["CVE-2026-22864","GHSA-m3c4-prhw-mrx6"],"related":[],"kind":"vulnerability","state":"published","title":"Deno has an incomplete fix for command-injection prevention on Windows — case-insensitive extension bypass","summary":"Deno is a JavaScript, TypeScript, and WebAssembly runtime. Before 2.5.6, a prior patch aimed to block spawning Windows batch/shell files by returning an error when a spawned path’s extension matched .bat or .cmd. That check performs a case-sensitive comparison against lowercase literals and therefore can be bypassed when the extension uses alternate casing (for example .BAT, .Bat, etc.). This vulnerability is fixed in 2.5.6.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Deno is a JavaScript, TypeScript, and WebAssembly runtime. Before 2.5.6, a prior patch aimed to block spawning Windows batch/shell files by returning an error when a spawned path’s extension matched .bat or .cmd. That check performs a case-sensitive comparison against lowercase literals and therefore can be bypassed when the extension uses alternate casing (for example .BAT, .Bat, etc.). This vulnerability is fixed in 2.5.6.","source":"cvelist"},{"lang":"en","text":"### Summary\nA prior patch aimed to block spawning Windows batch/shell files by returning an error when a spawned path’s extension matched `.bat` or `.cmd`. That check performs a case-sensitive comparison against lowercase literals and therefore can be bypassed when the extension uses alternate casing (for example `.BAT, .Bat`, etc.).\n\n### POC\n```javascript\nconst command = new Deno.Command('./test.BAT', {\n  args: ['&calc.exe'],\n});\nconst child = command.spawn();\n```\nThis causes `calc.exe` to be launched; see the attached screenshot for evidence.\n\n**Patched in `CVE-2025-61787` — prevents execution of `.bat` and `.cmd` files:**\n![photo_2025-10-10 02 27 23](https://github.com/user-attachments/assets/43df25e2-e2e1-48aa-8060-cb0a22637f1f)\n\n**Bypass of the patched vulnerability:**\n![photo_2025-10-10 02 27 25](https://github.com/user-attachments/assets/2be1afb4-84a1-4883-8e18-6a174fdd3615)\n\n\n### Impact\nThe script launches calc.exe on Windows, demonstrating that passing user-controlled arguments to a spawned batch script can result in command-line injection.\n\n### Mitigation\n\nUsers should update to Deno v2.5.6 or newer.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Deno es un entorno de ejecución de JavaScript, TypeScript y WebAssembly. Antes de 2.5.6, un parche anterior tenía como objetivo bloquear la ejecución de archivos batch/shell de Windows devolviendo un error cuando la extensión de una ruta ejecutada coincidía con .bat o .cmd. Esa verificación realiza una comparación que distingue entre mayúsculas y minúsculas contra literales en minúsculas y por lo tanto puede ser eludida cuando la extensión utiliza un uso de mayúsculas y minúsculas alternativo (por ejemplo, .BAT, .Bat, etc.). Esta vulnerabilidad está corregida en 2.5.6.","source":"nvd"}],"published":"2026-01-15T22:58:52.463Z","modified":"2026-06-17T10:20:31.700Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H","score":8.1,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H","score":8.1,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H","score":8.1,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"}],"cwes":["CWE-77"],"affected":[{"ranges":[{"version":"< 2.5.6","status":"affected"}],"vendor":"denoland","product":"deno","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"2.5.6"}],"ecosystem":"crates.io","package":"deno","purl":"pkg:cargo/deno","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"2.5.6"}],"vendor":"deno","product":"deno","cpe":"cpe:2.3:a:deno:deno:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/denoland/deno/security/advisories/GHSA-m3c4-prhw-mrx6","tags":["exploit","vendor-advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/denoland/deno/releases/tag/v2.5.6","tags":["release-notes","web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-22864","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/denoland/deno","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2026-01-16T17:15:35.078Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-22864","url":"https://www.cve.org/CVERecord?id=CVE-2026-22864","licence":"CVE Terms of Use","modified":"2026-01-16T17:16:02.143Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-m3c4-prhw-mrx6","url":"https://github.com/advisories/GHSA-m3c4-prhw-mrx6","licence":"CC-BY-4.0","modified":"2026-02-03T03:17:23.271Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-22864","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-22864","licence":"Public domain","modified":"2026-06-17T10:20:31.700Z"}],"updatedAt":"2026-11-25T22:59:12.876Z","epss":{"score":0.00678,"percentile":0.53586,"date":"2026-12-01T12:00:22.000Z"}}