CVE-2022-1851
NixOS vulnerability analysis and mitigation

Overview

CVE-2022-1851 is an out-of-bounds read vulnerability discovered in the Vim text editor prior to version 8.2. The vulnerability was identified in the gchar_cursor() function in misc1.c and was fixed in patch 8.2.5013 (VIM Commit). The issue affects multiple versions of Vim across various operating systems and distributions (Debian LTS, Ubuntu Security).

Technical details

The vulnerability is characterized by an out-of-bounds read condition that occurs when the cursor position becomes invalid after text formatting operations. The issue was addressed by implementing a fix that corrects the cursor position after formatting operations through the addition of a check_cursor() function call (VIM Commit). The vulnerability has been assigned a CVSS 3.1 score of 7.8 (High), with attack vector being Local, attack complexity Low, and requiring user interaction (Ubuntu Security).

Impact

If exploited, this vulnerability could lead to a denial-of-service condition through application crash or potentially allow arbitrary code execution when processing specially crafted files. The vulnerability affects multiple operating systems and distributions including Ubuntu, Debian, and Fedora (Debian LTS, Fedora Update).

Mitigation and workarounds

The vulnerability has been fixed in Vim version 8.2.5013 and later. Users are advised to upgrade to the patched versions available through their respective distribution channels. Multiple distributions have released security updates: Ubuntu has fixed versions for multiple releases, Debian has addressed it in version 2:8.0.0197-4+deb9u7 for Stretch and 2:8.1.0875-5+deb10u3 for Buster, and Fedora has released version 8.2.5046-1 (Debian LTS, Ubuntu Security, Fedora Update).

Additional resources


SourceThis report was generated using AI

Related NixOS vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-68120MEDIUM5.4
  • NixOSNixOS
  • go
NoYesDec 30, 2025
CVE-2025-69413MEDIUM5.3
  • NixOSNixOS
  • code.gitea.io/gitea
NoYesJan 01, 2026
CVE-2025-15412MEDIUM4.8
  • NixOSNixOS
  • wabt
NoNoJan 01, 2026
CVE-2025-15411MEDIUM4.8
  • NixOSNixOS
  • wabt
NoNoJan 01, 2026
CVE-2025-68932LOW2.9
  • NixOSNixOS
  • freshrss
NoYesDec 27, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management