CVE-2025-9390
BaseFortify
Publication date: 2025-08-24
Last updated on: 2026-04-29
Assigner: VulDB
Description
Description
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| vim | vim | From 9.1.1459 (inc) to 9.1.1616 (exc) |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-119 | The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data. |
| CWE-120 | The product copies an input buffer to an output buffer without verifying that the size of the input buffer is less than the size of the output buffer. |
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?
CVE-2025-9390 is a buffer overflow vulnerability in the xxd utility of the Vim text editor, specifically when using bitwise output mode (-b flag) and sometimes combined with the EBCDIC encoding flag (-E). The vulnerability arises because the program incorrectly calculates the maximum output buffer size, allowing it to write beyond the allocated buffer boundaries during binary-to-EBCDIC conversion or bitwise output operations. This leads to a buffer overflow that can cause the program to abort or potentially be exploited. The flaw exists in the main function of src/xxd/xxd.c and affects Vim versions up to 9.1.1615. The issue was fixed by correctly adjusting the buffer size calculation in patch 9.1.1616. [1, 3, 5]
How can this vulnerability impact me? :
This vulnerability can impact you by allowing a local attacker to exploit the buffer overflow in the xxd utility of Vim, potentially leading to a crash (program abort) or other unintended behavior. Since the vulnerability affects confidentiality, integrity, and availability, exploitation could allow an attacker to compromise the affected system's security. The exploit requires local access and proof-of-concept code is publicly available, making exploitation easier. The impact severity is moderate with CVSSv3 base score of 5.3. Mitigation involves upgrading Vim to version 9.1.1616. [2]
How can this vulnerability be detected on my network or system? Can you suggest some commands?
This vulnerability can be detected by running the vulnerable xxd utility with specific flags that trigger the buffer overflow, causing the program to abort with a 'buffer overflow detected' message. A known command to reproduce the issue is: `xxd -b -E -c 128 -g 256 <crafted_input_file>`. This command uses the binary output mode (-b) combined with the EBCDIC encoding flag (-E), large column size (-c 128), and group size (-g 256) on a specially crafted input file that triggers the overflow. Detection can also be aided by compiling xxd with GCC's Fortify Source protection enabled, which will cause the program to abort on overflow. Debugging tools like AddressSanitizer and GDB can be used to observe the buffer overflow and program termination with SIGABRT. [3, 5]
What immediate steps should I take to mitigate this vulnerability?
The immediate mitigation step is to upgrade Vim to version 9.1.1616 or later, which includes a patch that fixes the buffer overflow vulnerability in the xxd utility. The patch corrects the buffer size calculations to prevent overflow during bitwise output mode. Avoid running the vulnerable xxd utility with the -b and -E flags on untrusted input until the upgrade is applied. Additionally, enabling compiler sanitizers during builds can help detect similar issues. [2, 4]