JLSEC-2026-1850: Buffer Overflow
Vim is an open source, command line text editor. Prior to 9.1.2148, a stack buffer overflow vulnerability exists in Vim's NetBeans integration when processing the specialKeys command, affecting Vim builds that enable and use the NetBeans feature. The Stack buffer overflow exists in specialkeys() (in src/netbeans.c). The while (tok) loop writes two bytes per iteration into a 64-byte stack buffer (keybuf) with no bounds check. A malicious NetBeans server can overflow keybuf with a single specialKeys command. The issue has been fixed as of Vim patch v9.1.2148.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 9.1.2148
Event History
Frequently Asked Questions
Which deployments are exposed to this issue?
The issue affects Vim builds that enable and use the NetBeans feature. A vulnerable build must process a specialKeys command from a NetBeans server.
What does an attacker need to exploit it?
An attacker needs to operate or control a malicious NetBeans server that the vulnerable Vim instance communicates with. The overflow can be triggered with a single specialKeys command.
What should be done to remediate the issue?
Update to Vim patch v9.1.2148 or later, where the issue is fixed. If updating is not immediately possible, avoid using the NetBeans feature with untrusted or potentially malicious NetBeans servers.