Use After Free Vulnerability in vim

vim Updated 02 Oct 2025

Summary

31/12/2021
N/A
Yes i
High
7.8

CVE-2021-4192: vim is vulnerable to Use After Free. Affects vim versions < 8.2.4173-r0. Fixed in 8.2.4173-r0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

Background

vim is a highly popular text editor known for its extensive features and customization options. It is widely used by developers and system administrators for editing code and text files. However, the vim package is vulnerable to a Use After Free vulnerability, which can lead to serious security issues.

Vulnerability Detail

The Use After Free vulnerability in vim occurs when the program continues to reference memory after it has been freed. This can result in the execution of arbitrary code or a crash, potentially allowing an attacker to gain unauthorized access or cause a denial of service. The vulnerability has a CVSS score of 7.8, indicating a high severity level.

How To Fix

Minimum fixed version

8.2.4173-r0

This is the first release that contains the fix.

sudo apk add --upgrade vim

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

There is no known workaround for this vulnerability. It is essential to update the vim package to the fixed version to address the issue effectively.

Conclusion

The Use After Free vulnerability in vim poses a significant security risk and should be addressed promptly. By updating to the fixed version, users can mitigate the vulnerability and ensure the security of their systems. For additional support, contact DevNack.com.

See every vulnerability recorded for vim →

Share this vulnerability

FAQ

The Use After Free vulnerability in vim can allow an attacker to execute arbitrary code or cause a denial of service. This can lead to unauthorized access, data breaches, or system crashes.

You can use the Vulert Playground at Vulert Scanner to check if your vim installation is affected by this vulnerability. Simply upload your package-lock.json file, and Vulert will analyze it for any open-source vulnerabilities, including this Use After Free vulnerability.

At the time of this report, there is no known exploit publicly available for this vulnerability. However, it is crucial to update your vim installation to the fixed version to prevent any potential exploitation.

Yes, all versions of vim prior to 8.2.4173-r0 are vulnerable to this Use After Free issue. It is recommended to update to the fixed version to ensure the security of your vim installation.

For further support and assistance in vulnerability remediation, you can contact info@devnack.com. They can provide guidance and help you address the Use After Free vulnerability in your vim installation.

Related vulnerabilities

Recent vulnerabilities recorded for vim.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

How To Fix

Minimum fixed version

8.2.4173-r0

This is the first release that contains the fix.

sudo apk add --upgrade vim

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback