Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessStage malicious OSC 21 payload in file/banner/log
-
DeliveryTrick victim into rendering content in Kitty
-
ExploitTerminal reflects attacker bytes with newline into pty
-
ExecutionShell parses injected line as command
-
ImpactCommand executes at victim's privilege level
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
MITRE ATT&CK
2 techniques across 2 tactics: Execution, Initial Access The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Victim must be running Kitty terminal emulator at a version below 0.47.3 with an interactive shell at the prompt, and must cause attacker-controlled bytes containing a crafted OSC 21 (color-control) query sequence to be written to the terminal - typical delivery paths are |
| Impact | The CVSS 4.0 vector (AV:L/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H) accurately captures the trade-offs: impact is high (full shell command execution as the user) but the attack requires local delivery of bytes to the terminal (AV:L), an attack requirement (AT:P, the victim must be using a vulnerable Kitty version with a shell that processes the injected line), and passive user interaction (UI:P - simply viewing/cat-ing malicious content or connecting to a hostile SSH host is enough). There is no CISA KEV listing, no EPSS data supplied, and no public exploit identified at time of analysis, but the bug is trivially weaponizable and the GitHub Security Advisory (GHSA-5gmr-9gwg-hhq6) confirms the issue. Real-world risk is moderate-to-high for users who routinely view untrusted output (log files, downloaded files, remote shells, web-fetched content) - this is precisely the workflow of developers and sysadmins who form Kitty's user base - so prioritization should be elevated despite the local attack vector. |
| Exploit ScenarioDerived | An attacker hosts a text file (or controls an SSH login banner, a log line written by a network service, or a web response viewed via |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jun 12, 2026
Code injection in Kitty terminal emulator versions prior to 0.47.3 allows attacker-controlled bytes - including newline characters - to be reflected back into the user's shell input via the OSC 21 (color-control) escape sequence query reply. An attacker who can cause arbitrary bytes to be written to the terminal (malicious file contents, SSH banner, log entry, web page) can inject and execute shell commands at the victim's privilege level. No public exploit identified at time of analysis, but the underlying class of terminal-escape-injection bugs is well documented and exploitation is straightforward once the unsanitized reply path is known.
RemediationAI
Vendor-released patch: upgrade Kitty to version 0.47.3 or later, which sanitizes OSC 21 reply bytes; the fix and details are documented in the upstream advisory at https://github.com/kovidgoyal/kitty/security/advisories/GHSA-5gmr-9gwg-hhq6. If immediate patching is not possible, compensating controls include avoiding direct output of untrusted data to the terminal - pipe suspect files through a sanitizer such as cat -v, less -R with control-character filtering, or strings before viewing (trade-off: loses legitimate color/formatting); refusing to cat arbitrary log files, downloaded artifacts, or unknown SSH MOTD/banners; and disabling shell auto-execution on Enter where supported (e.g., zsh setopt NO_FLOW_CONTROL plus bracketed-paste-mode hardening, though this does not fully mitigate newline injection into a live prompt). The cleanest mitigation remains the upgrade.
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 cross-platform, GPU-accelerated terminal emulator written by Kovid Goyal (CPE cpe:2.3:a:kovidgoyal:kitty). OSC (Operating System Command) sequences are part of the ANSI/ECMA-48 control protocol; OSC 21 is Kitty's color-control extension that lets applications query and set palette colors, with the terminal writing its reply back onto the pty as if the user had typed it. The flaw is a classic CWE-94 (Improper Control of Generation of Code) problem: the reply path echoes attacker-supplied bytes from the original query payload without stripping or escaping control characters such as CR/LF, so a newline injected into the query causes the shell to treat any following bytes as a fresh command line. This is the same vulnerability class as the historical iTerm2 and various xterm DCS/OSC injection bugs.
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
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Local delivery of bytes to the terminal (AV:L), low complexity, no privileges on Kitty, requires user to view content and be at shell prompt (UI:R), full shell command execution yields C/I/A:H.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
1DescriptionCVE.org
Kitty is a cross-platform GPU based terminal. In versions prior to 0.47.3, kitty's OSC 21 (color-control) query reply reflects attacker-controlled bytes, including newlines, into the shell's input without sanitization. Version 0.47.3 fixes the issue.
Executive ViewAI
Kitty terminal emulator versions before 0.47.3 contain a code injection vulnerability allowing attackers who control terminal output (SSH banners, log files, displayed content) to execute arbitrary commands at the user's privilege level. Organizations using Kitty should prioritize patching to prevent unauthorized command execution and potential system compromise.
Apply vendor patch.
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
Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
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 memory corruption in Kitty cross-platform GPU terminal emulator (versions 0.46.2 and below) allows remote attackers
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
Same weakness CWE-94 – Code Injection
View allVendor StatusVendor
SUSE
Severity: Important| Product | Status |
|---|---|
| openSUSE Tumbleweed | Fixed |
EUVD-2026-36579
NVD
CVE.org
EPSS
Vulnrichment
GitHub
VulDB
Exploit-DB