CVE-2021-3903 Heap-based Buffer Overflow in vim/vim
A heap-based buffer overflow in Vim allows attackers to execute arbitrary code or cause a denial of service via crafted input.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Local or same network only
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2021-3903?
CVE-2021-3903 is a high-severity memory corruption vulnerability in Debian Debian Linux, published on 27 Oct 2021. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.
Official description
vim is vulnerable to Heap-based Buffer Overflow
Which versions are affected by CVE-2021-3903?
It affects 3 products.
Linux distribution packages (24)
vim-X11 AlmaLinux:9 | All versions | 2:8.2.2637-21.el9 |
vim-common AlmaLinux:9 | All versions | 2:8.2.2637-21.el9 |
vim-enhanced AlmaLinux:9 | All versions | 2:8.2.2637-21.el9 |
vim-filesystem AlmaLinux:9 | All versions | 2:8.2.2637-21.el9 |
vim-minimal AlmaLinux:9 | All versions | 2:8.2.2637-21.el9 |
vim-X11 Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim-X11-debuginfo Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim-common Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim-common-debuginfo Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim-debuginfo Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim-debugsource Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim-enhanced Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim-enhanced-debuginfo Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim-minimal-debuginfo Red Hat:enterprise_linux:9::appstream | All versions | 2:8.2.2637-21.el9 |
vim Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim-X11-debuginfo Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim-common-debuginfo Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim-debuginfo Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim-debugsource Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim-enhanced-debuginfo Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim-filesystem Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim-minimal Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim-minimal-debuginfo Red Hat:enterprise_linux:9::baseos | All versions | 2:8.2.2637-21.el9 |
vim Rocky Linux:9 | All versions | 2:8.2.2637-21.el9 |
Products include Debian Debian Linux, Fedoraproject Fedora, Vim Vim.
How do I fix CVE-2021-3903?
Apply the vendor's patch.
Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.
Is CVE-2021-3903 being exploited?
There is no known exploitation of CVE-2021-3903 in the wild and no public exploit code.
Other vulnerabilities in Debian Debian Linux
Sources
Also known as ALPINE-CVE-2021-3903, ALSA-2024:9405, CLSA-2025-1737024110, DEBIAN-CVE-2021-3903, GHSA-xc29-p9xx-c3j9, OESA-2021-1421 and 3 more.