Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAttacker stages malicious content (file/banner/log)
-
DeliveryVictim's Kitty terminal renders the bytes
-
ExploitCrafted graphics compose escape sequence parsed
-
Execution32-bit offset arithmetic wraps past bounds check
-
Persistcompose_rectangles() performs OOB heap read/write
-
ImpactTerminal crash or memory disclosure/corruption
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Integer overflow checks
MITRE ATT&CK
1 technique across 1 tactic: Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | The victim must be running Kitty version 0.46.2 or earlier with its default graphics protocol support enabled (no opt-in configuration is required), and the attacker must be able to cause at least one stream of bytes - an escape sequence beginning with ESC_G containing a compose action 'a=c' with crafted x_offset/y_offset values - to reach the terminal's stdout. Practical delivery channels named in the advisory are a malicious file rendered by cat/less, an SSH server's pre-auth login banner, or any piped command output. Limiting factors: the user must actually open or connect to attacker-influenced content in Kitty specifically (other terminals are unaffected), and the impact achievable depends on heap layout at the moment of the wrapped offset write, which is non-deterministic. No authentication to Kitty is involved and no user interaction beyond viewing output is needed. |
| Impact | Signals are largely consistent and point to genuine high priority. The CVSS:3.1 vector AV:N/AC:L/PR:N/UI:N is supported by the description: any actor whose output reaches the user's terminal (SSH login banner, malicious file viewed with cat/less, hostile log line, web-served text) can trigger the bug with no authentication or interaction. Scope:Changed and A:H reflect that a corrupted terminal process can crash or be coerced into reading/writing arbitrary heap memory, with C:L/I:L acknowledging that leak/write primitive is constrained rather than full RCE-confirmed. EPSS and CISA KEV data were not provided in the input, so exploitation likelihood and active-exploitation status are unknown - treat the 9.9 base score with that caveat. No public exploit identified at time of analysis, but the upstream commit clearly exposes the root cause, which lowers the bar to weaponization. Overall this is a real priority for any environment where users SSH into untrusted hosts or process untrusted text in Kitty. |
| Exploit ScenarioDerived | An attacker hosts a malicious file, log line, or SSH login banner containing a Kitty graphics protocol compose command with carefully chosen x_offset/y_offset values designed to wrap during the 32-bit bounds check. When the victim cats the file, tails the log, or SSHes to the server from a Kitty terminal, handle_compose_command() accepts the values and compose_rectangles() performs a massive out-of-bounds heap read/write, crashing the terminal or potentially corrupting adjacent heap structures. No public exploit identified at time of analysis, though the upstream patch makes the overflow condition explicit. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – May 19, 2026
Heap memory corruption in Kitty cross-platform GPU terminal emulator (versions 0.46.2 and below) allows remote attackers to trigger out-of-bounds heap reads and writes by emitting crafted graphics protocol escape sequences. The flaw stems from a 32-bit integer overflow in handle_compose_command() that lets malicious x_offset/y_offset values bypass bounds checks. No public exploit identified at time of analysis, but the bug requires no user interaction, no authentication, and works against default configurations whenever attacker-controlled bytes can reach the terminal - including via SSH banners, cat'd files, or piped output.
RemediationAI
Vendor-released patch: upgrade to Kitty 0.47.0 or later, which widens the offset arithmetic to uint64_t (commit https://github.com/kovidgoyal/kitty/commit/e9661f0f3afb4e4dbffa509adfb3df3c9780ad34); the advisory is at https://github.com/kovidgoyal/kitty/security/advisories/GHSA-qfgm-2c64-6x3x. Where immediate upgrade is impossible, compensating controls include avoiding cat/less/tail on untrusted files (pipe through a sanitizer such as cat -v or strings which strips control bytes), disabling automatic display of SSH banners by setting LogLevel QUIET / using ssh -q, and configuring tooling to filter or escape the Kitty graphics-protocol introducer (ESC _G ... ESC \) before content reaches the terminal; the trade-off is loss of legitimate inline-image features (icat, image previews in file managers, terminal-rendered plots) until patched.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Kitty is a widely deployed GPU-accelerated terminal emulator written in C by Kovid Goyal (CPE cpe:2.3:a:kovidgoyal:kitty). The vulnerability is in kitty/graphics.c, specifically the handle_compose_command() routine of Kitty's proprietary graphics protocol that lets terminals render bitmap images via escape sequences. Per CWE-190 (Integer Overflow or Wraparound), the original code declared width, height, dest_x, dest_y, src_x, and src_y as 32-bit unsigned ints and combined them in arithmetic bounds checks. Because each component is itself a full 32-bit value, sums such as dest_x + width wrap around past UINT32_MAX, making the validity check pass even when the resulting region extends far outside the source/destination image buffers. The patched code (commit e9661f0f3afb) widens these locals to uint64_t so the addition cannot overflow during validation before reaching compose_rectangles().
Know when Kitty gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Primary rating from NVD.
CVSS VectorNVD
Lifecycle Timeline
2DescriptionNVD
Kitty is a cross-platform GPU based terminal. In versions 0.46.2 and below, the handle_compose_command() function in kitty/graphics.c performs bounds validation on composition offsets using unsigned 32-bit arithmetic that is subject to integer wrapping, potentially leading to Heap Buffer Over-Read/Write. An attacker who can write escape sequences to a kitty terminal (e.g., via a malicious file, SSH login banner, or piped content) can supply crafted x_offset/y_offset values that pass the bounds check after wrapping but cause massive out-of-bounds heap memory access in compose_rectangles(). No user interaction is required. No non-default configuration is required. The attacker only needs the ability to produce output in a kitty terminal window. This issue has been fixed in version 0.47.0.
Executive ViewAI
Kitty terminal emulator versions 0.46.2 and below contain an unpatched critical vulnerability (CVSS 9.9) that enables unauthenticated remote system compromise through common workflows including SSH connections and file viewing. Any organization using Kitty faces immediate risk with no vendor patch currently available to mitigate this exposure.
No vendor-released patch identified at time of analysis. Interim mitigations: (1) Restrict network access to systems running Kitty via firewall rules; (2) Disable or restrict Kitty graphics protocol processing in configuration, if available; (3) Avoid opening untrusted content (SSH banners, piped scripts, unknown files) in Kitty on vulnerable versions; (4) Deploy alternative terminal emulators as interim replacement on high-risk systems; (5) Implement process monitoring and alerting on Kitty to detect exploitation attempts; (6) Apply principle of least privilege to accounts running Kitty.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.
Integer overflow occurs when an arithmetic operation produces a result that exceeds the maximum value a given integer type can store.
The SSH transport protocol with certain OpenSSH extensions, found in OpenSSH before 9.6 and other products, allows remot
Stack-based buffer overflow in the SCP command-line utility in PuTTY before 0.67 and KiTTY 0.66.6.3 and earlier allows r
The Graphics Protocol feature in graphics.c in kitty before 0.19.3 allows remote attackers to execute arbitrary code bec
KiTTY versions 0.76.1.13 and before is vulnerable to command injection via the filename variable, occurs due to insuffic
KiTTY versions 0.76.1.13 and before is vulnerable to a stack-based buffer overflow via the username, occurs due to insuf
KiTTY versions 0.76.1.13 and before is vulnerable to a stack-based buffer overflow via the hostname, occurs due to insuf
In Kitty before 0.26.2, insufficient validation in the desktop notification escape sequence can lead to arbitrary code e
Heap buffer overflow in Kitty terminal versions 0.46.2 and below allows any process able to write to the terminal's stan
open_actions.py in kitty before 0.41.0 does not ask for user confirmation before running a local executable file that ma
Remote code execution in Kitty terminal emulator versions prior to 0.47.0 allows any process or remote peer that can wri
Command injection in Kitty cross-platform GPU terminal emulator versions prior to 0.47.0 allows remote attackers to exec
Code injection in Kitty terminal emulator versions prior to 0.47.3 allows attacker-controlled bytes - including newline
Same weakness CWE-190 – Integer Overflow or Wraparound
View allSame technique Buffer Overflow
View allVendor StatusVendor
SUSE
Severity: Critical| Product | Status |
|---|---|
| openSUSE Leap 16.0 | Fixed |
EUVD-2026-30968
NVD
CVE.org
EPSS
Vulnrichment
GitHub
Exploit-DB