CVE-2022-3278
vim: null pointer dereference in eval_next_non_blank() in eval.c
Severity
LowRed Hat Product Security
CVSS 3.1
Review impact separately from score.
Published · September 24, 2022
Updated · November 22, 2025
Description
A NULL pointer dereference vulnerability was found in Vim's eval_next_non_blank() function of the src/eval.c file. The flaw occurs when using NUL in buffer uses :source. This flaw allows an attacker to trick a user into opening a specially crafted file, triggering a NULL pointer dereference that causes a denial of service.
Statement
Red Hat Enterprise Linux 6, 7, and 8 are not affected, as versions of VIM shipped does not contain vulnerable function/code.
Red Hat Product Security has rated this issue as having a Low security impact, because the "victim" has to run an untrusted file IN SCRIPT MODE. Running untrusted files in script mode is equivalent to running random python script.
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
Untrusted vim scripts with -s [scriptin] are not recommended to run.
CVSS / CWE
CVSS 3.1 · 5.5CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
CWE-476 · NULL Pointer Dereference