CVE-2024-43374

Name
CVE-2024-43374
Description
The UNIX editor Vim prior to version 9.1.0678 has a use-after-free error in argument list handling. When adding a new file to the argument list, this triggers `Buf*` autocommands. If in such an autocommand the buffer that was just opened is closed (including the window where it is shown), this causes the window structure to be freed which contains a reference to the argument list that we are actually modifying. Once the autocommands are completed, the references to the window and argument list are no longer valid and as such cause an use-after-free. Impact is low since the user must either intentionally add some unusual autocommands that wipe a buffer during creation (either manually or by sourcing a malicious plugin), but it will crash Vim. The issue has been fixed as of Vim patch v9.1.0678.
NVD Severity
medium
Other trackers
Mailing lists
Exploits
Forges
GitHub (code, issues), Aports (code, issues)

References

Type URI
CONFIRM https://github.com/vim/vim/security/advisories/GHSA-2w8m-443v-cgvw
MISC https://github.com/vim/vim/commit/0a6e57b09bc8c76691b367a5babfb79b31b770e8

Match rules

CPE URI Source package Min version Max version
vim >= 0 < 9.1.0678

Vulnerable and fixed packages

Source package Branch Version Maintainer Status
vim 3.19-main 9.0.2127-r0 Natanael Copa <ncopa@alpinelinux.org> possibly vulnerable
vim 3.18-main 9.0.2073-r0 Natanael Copa <ncopa@alpinelinux.org> possibly vulnerable
vim 3.17-main 9.0.0999-r0 Natanael Copa <ncopa@alpinelinux.org> possibly vulnerable