CVE-2023-0051
vim: heap-based buffer overflow in msg_puts_printf() in message.c
Severity
LowRed Hat Product Security
CVSS 3.1
Review impact separately from score.
Published · January 3, 2023
Updated · June 26, 2026
Description
A heap-based buffer overflow was found in Vim in the msg_puts_printf function in the message.c file. The issue occurs because of an invalid memory access when calculating the length of a string when a specially crafted input is processed. This flaw allows an attacker who can trick a user into opening a specially crafted file into triggering the heap-based buffer overflow, causing the application to crash.
Statement
Red Hat Product Security has rated this issue as having a Low security impact because the user has to run an untrusted file in script mode.
For additional information, refer to the Issue Severity Classification: https://access.redhat.com/security/updates/classification/ and Red Hat Enterprise Linux Life Cycle & Updates Policy: https://access.redhat.com/support/policy/updates/errata/.
CVSS score applicability
The CVSS score(s) listed for this vulnerability do not reflect the associated product's status, and are included for informational purposes to better understand the severity of this vulnerability.
Mitigation
Do not run untrusted vim scripts as it is not recommended.
CVSS / CWE
CVSS 3.1 · 7.8CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
CWE-805 · Buffer Access with Incorrect Length Value