What’s Vulnerable › Vulnerabilities
CVE-2021-3872: Heap-based Buffer Overflow in vim/vim
- Severity: high (CVSS 7.8 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 1.5% probability of exploitation in the next 30 days
- Public exploit or detection template: yes
- Published: 2021-10-19 · updated 2026-06-17
- Weakness: CWE-122
Description
vim is vulnerable to Heap-based Buffer Overflow
Affected products
- Debian Linux: 9.0
- Fedoraproject Fedora: 33, 35
- vim/vim: before 8.2.3487 — fixed in 8.2.3487
How to fix
Upgrade to a fixed version: vim/vim 8.2.3487. Check the vendor advisory for mitigations.
References
- https://github.com/vim/vim/commit/826bfe4bbd7594188e3d74d2539d9707b1c6a14b
- https://huntr.dev/bounties/c958013b-1c09-4939-92ca-92f50aa169e8
- https://lists.debian.org/debian-lts-announce/2022/03/msg00018.html
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/7K4JJBIH3OQSZRVTWKCJCDLGMFGQ5DOH/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/S42L4Z4DTW4LHLQ4FJ33VEOXRCBE7WN4/
- https://security.gentoo.org/glsa/202208-32
- https://github.com/vim/vim/commit/826bfe4bbd7594188e3d74d2539d9707b1c6a14b
- https://huntr.dev/bounties/c958013b-1c09-4939-92ca-92f50aa169e8
- https://lists.debian.org/debian-lts-announce/2022/03/msg00018.html
- https://lists.debian.org/debian-lts-announce/2025/03/msg00023.html
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/7K4JJBIH3OQSZRVTWKCJCDLGMFGQ5DOH/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/S42L4Z4DTW4LHLQ4FJ33VEOXRCBE7WN4/
Get alerted when CVE-2021-3872 or the next vulnerability affects your stack