CVE-2026-52859
Vim: Out-of-bounds Read in Terminal Screen Snapshot
Reported by github_m · Published June 11, 2026
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.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| vim-enhanced | errata.rockylinux.org | 9.1.083-9.el10 |
| vim-common | errata.rockylinux.org | 8.0.1763-31.el8 |
| vim-filesystem | errata.rockylinux.org | 9.1.083-9.el10 |
| vim-X11 | Amazon Linux | 2:9.0.2153-1.amzn2.0.11 |
| vim-data | errata.rockylinux.org | 9.1.083-9.el10 |
| vim-debugsource | errata.rockylinux.org | 8.0.1763-31.el8 |
| vim | errata.rockylinux.org | 8.2.2637-26.el9 |
| vim-X11-debuginfo | errata.rockylinux.org | 9.1.083-9.el10 |
| vim-common-debuginfo | errata.rockylinux.org | 8.2.2637-26.el9 |
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| vim | vim | < 9.2.0565 |
| amazon:2 | vim-X11 | 0 |
| vim | vim | 0 |
| amazon:2023 | xxd | 0 |
| amazon:2 | xxd | 0 |
| amazon:2023 | vim-enhanced | 0 |
| amazon:2023 | vim-data | 0 |
| amazon:2 | vim-data | 0 |
| amazon:2 | vim-common | 0 |
| amazon:2023 | vim-minimal | 0 |
| amazon:2023 | vim-filesystem | 0 |
| amazon:2 | vim-enhanced | 0 |
| amazon:2023 | vim-common | 0 |
| amazon:2 | vim-filesystem | 0 |
| alpine | vim | 0 |
| amazon:2023 | vim-default-editor | 0 |
| amazon:2 | vim-minimal | 0 |
Timeline
- Jun 11, 2026 CVE Published
- Jun 12, 2026 Coalition ESS Score
- Jun 14, 2026 Security Advisory (7 in total, the first dated here)
- Jun 17, 2026 CVE Updated
- Aug 7, 2026 EPSS Score (27 in total, the first dated here)
- Aug 11, 2026 Distribution Patch (9 in total, the first dated here)
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2026-52859
vulnetix vdb fixes CVE-2026-52859
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2026-52859/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart
References
- https://github.com/vim/vim/security/advisories/GHSA-47gw-8gc3-mgcm x_refsource_CONFIRM
- https://github.com/vim/vim/commit/63680c6d3d52477817b49cd1a66e7aabe8a7aa19 x_refsource_MISC
- https://github.com/vim/vim/releases/tag/v9.2.0565 x_refsource_MISC