Integer Overflow in :history command in Vim
Summary
| CVE | CVE-2023-46246 |
|---|---|
| State | PUBLISHED |
| Assigner | GitHub_M |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2023-10-27 19:15:41 UTC |
| Updated | 2026-06-23 18:17:34 UTC |
| Description | Vim is an improved version of the good old UNIX editor Vi. Heap-use-after-free in memory allocated in the function `ga_grow_inner` in in the file `src/alloc.c` at line 748, which is freed in the file `src/ex_docmd.c` in the function `do_cmdline` at line 1010 and then used again in `src/cmdhist.c` at line 759. When using the `:history` command, it's possible that the provided argument overflows the accepted value. Causing an Integer Overflow and potentially later an use-after-free. This vulnerability has been patched in version 9.0.2068. |
Risk And Classification
Primary CVSS: v3.1 5.5 MEDIUM from [email protected]
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
EPSS: 0.003660000 probability, percentile 0.285180000 (date 2026-06-28)
Problem Types: CWE-190 | CWE-416 | CWE-416 CWE-416: Use After Free | CWE-190 CWE-190: Integer Overflow or Wraparound
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 3.1 | [email protected] | Primary | 5.5 | MEDIUM | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
| 3.1 | [email protected] | Secondary | 4 | MEDIUM | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
| 3.1 | CNA | DECLARED | 4 | MEDIUM | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
CVSS v3.1 Breakdown
Attack Vector
LocalAttack Complexity
LowPrivileges Required
LowUser Interaction
NoneScope
UnchangedConfidentiality
NoneIntegrity
NoneAvailability
HighCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
NVD Known Affected Configurations (CPE 2.3)
Vendor Declared Affected Products
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| security.netapp.com/advisory/ntap-20231208-0006 | af854a3a-2127-422b-91ae-364da2661108 | security.netapp.com | |
| lists.fedoraproject.org/archives/list/[email protected]/messag... | af854a3a-2127-422b-91ae-364da2661108 | lists.fedoraproject.org | |
| lists.fedoraproject.org/archives/list/[email protected]/messag... | af854a3a-2127-422b-91ae-364da2661108 | lists.fedoraproject.org | |
| patch 9.0.2068: [security] overflow in :history · vim/vim@9198c1f · GitHub | af854a3a-2127-422b-91ae-364da2661108 | github.com | Patch |
| Integer Overflow in :history command · Advisory · vim/vim · GitHub | af854a3a-2127-422b-91ae-364da2661108 | github.com | Exploit, Third Party Advisory |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
No vendor comments have been submitted for this CVE.
Legacy QID Mappings
- 200016 Ubuntu Security Notification for Vim Vulnerabilities (USN-6557-1)
- 284816 Fedora Security Update for vim (FEDORA-2023-ca6c3651fe)
- 285093 Fedora Security Update for vim (FEDORA-2023-3fbd936b15)
- 296107 Oracle Solaris 11.4 Support Repository Update (SRU) 65.157.1 Missing (CPUJAN2024)
- 356740 Amazon Linux Security Advisory for vim : ALAS2-2023-2338
- 356783 Amazon Linux Security Advisory for vim : ALAS-2023-1893
- 356913 Amazon Linux Security Advisory for vim : ALAS2023-2023-431
- 357186 Amazon Linux Security Advisory for vim : AL2012-2024-485
- 673345 EulerOS Security Update for vim (EulerOS-SA-2024-1130)
- 673421 EulerOS Security Update for vim (EulerOS-SA-2024-1306)
- 673552 EulerOS Security Update for vim (EulerOS-SA-2024-1099)
- 673740 EulerOS Security Update for vim (EulerOS-SA-2024-1075)
- 673930 EulerOS Security Update for vim (EulerOS-SA-2024-1189)
- 673976 EulerOS Security Update for vim (EulerOS-SA-2024-1209)
- 674064 EulerOS Security Update for vim (EulerOS-SA-2024-1114)
- 907695 Common Base Linux Mariner (CBL-Mariner) Security Update for vim (31702-1)