All reports
Low

vim: use after free in utf_ptr2char

Affected versions

Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported

Exploitation

CVE-2022-1154

Probability of exploitation in the next 30 days: 1.46%

FIRST EPSS · 2026-11-22

Description

Use after free in utf_ptr2char in GitHub repository vim/vim prior to 8.2.4646.

A heap use-after-free vulnerability was found in Vim's utf_ptr2char() function of the src/mbyte.c file. This flaw occurs because vim is using a buffer line after it has been freed in the old regexp engine. This flaw allows an attacker to trick a user into opening a specially crafted file, triggering a heap use-after-free that causes an application to crash, possibly executing code and corrupting memory.