Skip to main content

Vim EUVDEUVD-2026-36283

| CVE-2026-52859 MEDIUM
Out-of-bounds Read (CWE-125)
2026-06-11 GitHub_M
6.9
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Attacker crafts Unicode combining-character sequence
  2. Delivery
    Sequence delivered via program running in Vim :terminal
  3. Exploit
    libvterm fills cell.chars[] without NUL terminator
  4. Execution
    update_snapshot() loop reads past six-element array boundary
  5. Persist
    Out-of-bounds bytes appended to scrollback buffer
  6. Impact
    Vim process crashes

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, read limits
MITRE ATT&CK

1 technique across 1 tactic: Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the victim to be running a Vim build compiled with +terminal support and to have an active :terminal window open in which a program is rendering attacker-controlled output. The specific triggering condition is output containing a Unicode base character combined with five combining marks, which causes libvterm to populate all six cell.chars[] slots without a NUL terminator - a condition reproducible with a short, non-scripted byte sequence as confirmed by the test sample added in the patch commit. No Vim scripting knowledge, plugins, authentication, or elevated privileges are required on the attacker's side; the attacker's influence need only extend to the text content displayed by the terminal program (e.g., data returned by a networked service, output of an untrusted binary). Users who do not use Vim's :terminal feature, or who use it exclusively with fully trusted local programs whose output cannot be influenced by external parties, are not at practical risk regardless of Vim version.

Impact

The reporter-assigned CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:L, score 6.9) characterizes this as a zero-friction, network-reachable, unauthenticated crash - a characterization that is technically defensible but contextually optimistic. In practice, an attacker must have influence over the text output rendered by a program running inside the victim's active :terminal window, which implies an intermediate dependency (e.g., an SSH session to a hostile system, a malicious tool whose output Vim is displaying) that the AV:N/UI:N framing does not fully capture. This implicit user-context dependency meaningfully reduces the realistic attacker population. The vulnerability is absent from CISA's KEV catalog, no public exploit code has been identified, and no EPSS data was provided in the input - all signals consistent with low exploitation urgency. The primary impact is process-level denial of service (crash); the confidentiality impact is limited to whatever adjacent memory happens to be read past the array boundary, and there is no integrity impact. The principal risk population is developers and sysadmins who routinely use Vim's :terminal to run tools that process externally sourced data such as SSH clients, log streamers, or IRC/chat clients. For users who do not use :terminal or use it only with fully trusted local programs, effective risk is negligible.

Exploit ScenarioDerived

A developer uses Vim's :terminal to run an SSH session connected to a remote server that an attacker controls or has compromised. The attacker's server outputs a short byte sequence - a base Unicode character followed by five combining marks - which libvterm renders by filling all six cell.chars[] slots without a NUL terminator. When Vim's update_snapshot() processes the cell during scrollback capture, the unguarded loop walks past the array boundary, appending out-of-bounds memory into the scrollback buffer and crashing the Vim process, potentially leaking adjacent stack or heap content in the process.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jun 11, 2026

Out-of-bounds read in Vim's built-in terminal emulator (:terminal feature) prior to version 9.2.0565 allows a program running inside a :terminal window to crash Vim by outputting crafted Unicode combining characters that exhaust all six libvterm cell slots, causing the unguarded loop in update_snapshot() to walk past the fixed-size array and append out-of-bounds memory into the scrollback buffer. The vulnerability is not listed in CISA's Known Exploited Vulnerabilities catalog and no public exploit code has been identified, placing this in the lower-urgency tier despite the CVSS 4.0 score of 6.9. Real-world exploitation is constrained by the requirement that a victim be actively using Vim's :terminal feature to render attacker-influenced program output.

RemediationAI

Upgrade Vim to version 9.2.0565 or later, which is confirmed by the vendor release tag at https://github.com/vim/vim/releases/tag/v9.2.0565 and the specific one-line fix in commit 63680c6d3d52477817b49cd1a66e7aabe8a7aa19. If an immediate upgrade is not feasible, the most effective compensating control is to avoid using Vim's :terminal feature with any program that receives or displays externally sourced data - specifically, refrain from running SSH sessions, IRC or chat clients, log-tail utilities, or untrusted scripts inside :terminal. There is no runtime Vim setting or compile-time flag that disables combining-character processing independently of terminal emulation, so feature-level avoidance is the only practical workaround. Package maintainers on distributions that ship Vim should verify their package has been updated to at least 9.2.0565.

Affected VersionsENISA

vim < 9.2.0565

Affected Packages

euvd vim fix: 9.2.0565

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

The vulnerability resides in the update_snapshot() function within src/terminal.c, which copies the visible terminal screen into Vim's scrollback buffer. Vim's :terminal feature embeds the libvterm library to emulate a terminal and represent each screen cell as a struct containing a chars[] array of up to VTERM_MAX_CHARS_PER_CELL (6) Unicode code points - one base character and up to five combining marks. When all six slots are filled, the bundled libvterm returns the array without appending a NUL terminator. The pre-patch iteration loop for (i = 0; (c = cell.chars[i]) > 0 || i == 0; ++i) relied exclusively on a NUL sentinel to halt, so with no NUL present it reads beyond the six-element boundary - a textbook CWE-125 (Out-of-Bounds Read). The out-of-bounds bytes are appended into a buffer sized for only six characters, creating both a crash condition and a theoretical path for adjacent memory disclosure, consistent with the 'Information Disclosure' and 'Buffer Overflow' tags. The fix (commit 63680c6d) adds an explicit upper-bound guard: i < VTERM_MAX_CHARS_PER_CELL. The CPE cpe:2.3:a:vim:vim:*:*:*:*:*:*:*:* indicates all Vim variants across platforms are affected, limited to builds compiled with +terminal support.

Know when Vim 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

Vendor (GitHub_M) PRIMARY 6.9 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N
vuln.today AI 4.2 MEDIUM

Network delivery is plausible via a networked terminal program, but AC:H and UI:R reflect the required precondition of an active :terminal session rendering attacker-controlled combining characters.

3.1 AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:N/A:L
4.0 AV:N/AC:H/AT:N/PR:N/UI:P/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N
SUSE 5.0 MEDIUM
AV:L/AC:L/PR:L/UI:R/S:U/C:N/I:N/A:H
Red Hat 5.0 MEDIUM

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
None
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

1
Patch available
Jun 11, 2026 - 20:01 EUVD

DescriptionCVE.org

Vim is an open source, command line text editor. Prior to version 9.2.0565, the update_snapshot() function in src/terminal.c copies the visible terminal screen into the scrollback buffer when a snapshot is taken. For each screen cell it walks the cell's chars[] array with no upper bound, stopping only when it encounters a NUL terminator. When a cell legitimately fills all VTERM_MAX_CHARS_PER_CELL (6) slots - a base character plus five combining marks - the bundled libvterm returns the array without a terminating NUL, so the loop reads past the fixed six-element array and appends the out-of-bounds values to a buffer reserved for only six characters. A program whose output is rendered inside a :terminal window can trigger this with a short byte sequence and no Vim scripting, leading to a crash. This issue has been patched in version 9.2.0565.

Threat Intelligence Overview

EPSS Score
0.0%
Top 88% exploitable
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment MSRC Vendor GitHub VulDB

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.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

34
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +34
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

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.

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

More in Vim

View all
CVE-2022-3520 CRITICAL POC
9.8 Dec 02

Heap-based Buffer Overflow in GitHub repository vim/vim prior to 9.0.0765. Rated critical severity (CVSS 9.8), this vuln

CVE-2022-0729 HIGH POC
8.8 Feb 23

Use of Out-of-range Pointer Offset in GitHub repository vim/vim prior to 8.2.4440. Rated high severity (CVSS 8.8), this

CVE-2026-34714 HIGH POC
8.6 Mar 30

Code execution vulnerability in Vim before 9.2.0272 allows attackers to gain immediate arbitrary command execution upon

CVE-2019-12735 HIGH POC
8.6 Jun 05

getchar.c in Vim before 8.1.1365 and Neovim before 0.3.6 allows remote attackers to execute arbitrary OS commands via th

CVE-2021-3968 HIGH POC
8.0 Nov 19

vim is vulnerable to Heap-based Buffer Overflow. Rated high severity (CVSS 8.0), this vulnerability is remotely exploita

CVE-2022-1616 HIGH POC
7.8 May 07

Use after free in append_command in GitHub repository vim/vim prior to 8.2.4895. Rated high severity (CVSS 7.8), this vu

CVE-2022-1619 HIGH POC
7.8 May 08

Heap-based Buffer Overflow in function cmdline_erase_chars in GitHub repository vim/vim prior to 8.2.4899. Rated high se

CVE-2021-4136 HIGH POC
7.8 Dec 19

vim is vulnerable to Heap-based Buffer Overflow. Rated high severity (CVSS 7.8), this vulnerability is no authentication

CVE-2021-3973 HIGH POC
7.8 Nov 19

vim is vulnerable to Heap-based Buffer Overflow. Rated high severity (CVSS 7.8), this vulnerability is no authentication

CVE-2021-3927 HIGH POC
7.8 Nov 05

vim is vulnerable to Heap-based Buffer Overflow. Rated high severity (CVSS 7.8), this vulnerability is no authentication

CVE-2022-2125 HIGH POC
7.8 Jun 19

Heap-based Buffer Overflow in GitHub repository vim/vim prior to 8.2. Rated high severity (CVSS 7.8), this vulnerability

CVE-2022-2126 HIGH POC
7.8 Jun 19

Out-of-bounds Read in GitHub repository vim/vim prior to 8.2. Rated high severity (CVSS 7.8), this vulnerability is no a

Vendor StatusVendor

SUSE

Severity: Moderate
Product Status
SLES15-SP5-CHOST-BYOS-SAP-CCloud Affected
SLES15-SP6-CHOST-BYOS Affected
SLES15-SP6-CHOST-BYOS-Aliyun Affected
SLES15-SP6-CHOST-BYOS-Azure Affected
SLES15-SP6-CHOST-BYOS-EC2 Affected

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy