Critical Buffer Overflow Vulnerability in vim Package

vim Updated 02 Oct 2025

Summary

10/02/2017
N/A
Yes i
Critical
9.8

ALPINE-CVE-2017-5953: vim before patch 8.0.0322 does not properly validate values for tree length when handling a spell file, which may result in an integer overflow at a memory allocation site and a resultant buffer overflow. Affects vim versions < 8.0.0329-r0. Fixed in 8.0.0329-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 MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

Vim is a highly configurable text editor built to enable efficient text editing. It is widely used by developers and system administrators for its powerful features, including syntax highlighting, multi-level undo, and extensive plugin support. However, certain versions of vim are vulnerable to a critical buffer overflow due to improper validation of tree length values when handling spell files, which can lead to severe security risks.

Vulnerability Detail

The vulnerability identified as CVE-2017-5953 affects vim versions prior to patch 8.0.0322. It arises from a failure to properly validate values for tree length when processing spell files. This oversight can result in an integer overflow at a memory allocation site, potentially leading to a buffer overflow. Such vulnerabilities can be exploited by attackers to execute arbitrary code, compromise system integrity, or cause application crashes.

How To Fix

Minimum fixed version

8.0.0329-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

As a temporary workaround, users can avoid opening spell files until the package is updated to a secure version. Additionally, disabling spell checking in vim can mitigate the risk until the patch is applied.

Conclusion

The CVE-2017-5953 vulnerability in vim poses a significant risk due to its potential for buffer overflow and arbitrary code execution. Users are strongly advised to update to the patched version 8.0.0329-r0 or later to mitigate this risk. Regular monitoring for vulnerabilities using tools like Vulert can help maintain the security of your applications.

See every vulnerability recorded for vim →

Share this vulnerability

FAQ

CVE-2017-5953 is a critical vulnerability in the vim text editor that can lead to buffer overflow due to improper validation of tree length values in spell files.

You can check your version of vim by running vim --version in your terminal. If it is below 8.0.0322, it is vulnerable.

Exploitation of this vulnerability can lead to arbitrary code execution, system crashes, or unauthorized access to sensitive data.

Yes, you can use Vulert, which monitors and alerts in real-time for open-source vulnerabilities using just a manifest file like package-lock.json.

You can use the Vulert playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.

Related vulnerabilities

Recent vulnerabilities recorded for vim.

How To Fix

Minimum fixed version

8.0.0329-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