CVE-2026-52860: Vim: Arbitrary Code Execution via Python Omni-Completion

Published Jun 11, 2026
·
Updated

Last updated 19 June 2026

Other sources

Vim is an open source, command line text editor. Prior to version 9.2.0597, Vim's Python omni-completion executes reconstructed function and class definitions from the current buffer with exec() as part of populating the completion dictionary. Python evaluates function default values, parameter annotations, and class base expressions at definition time, so a hostile buffer can execute attacker-controlled Python expressions during omni-completion. The existing g:pythoncompleteallowimport mitigation (GHSA-52mc-rq6p-rc7c) does not cover this path, because the attacker-controlled code is not a harvested import/from statement. This issue has been patched in version 9.2.0597.

MITRE

Vim: Arbitrary Code Execution via Python Omni-Completion

Microsoft

Affected Software

4 affected componentsFixes available
vim Vim<9.2.0597
vim Vim<9.2.0597
debian/vim<=2:8.2.2434-3+deb11u1, <=2:8.2.2434-3+deb11u3, <=2:9.0.1378-2+deb12u2, <=2:9.1.1230-2, <=2:9.2.0524-1
Microsoft azl3 vim 9.2.0488-1<9.2.0620-1
9.2.0620-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 9.2.0620-1
  2. Upgrade

    Upgrade Vim to a version that resolves this vulnerability.

    Fixed in 9.2.0597

Event History

Jun 11, 2026
CVE Published
via MITRE·06:33 PM
Data Sourced
via MITRE·06:33 PM
DescriptionWeakness
Data Sourced
via Red Hat·07:02 PM
DescriptionSeverityAffected Software
Data Sourced
via NVD·07:16 PM
RemedyDescriptionSeverityWeaknessAffected Software
Jun 13, 2026
Data Sourced
via Microsoft·08:01 AM
DescriptionSeverityWeakness
Data Sourced
via Microsoft·08:01 AM
Affected Software
Updated
via Microsoft·08:01 AM
DescriptionSeverity
Jun 18, 2026
Data Sourced
via Debian·06:48 PM
DescriptionAffected Software
Data Sourced
via Launchpad·06:48 PM
Description
Jun 20, 2026
Data Sourced
via Ubuntu·06:50 PM
RemedyDescriptionSeverityAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2026-52860?

CVE-2026-52860 has a high severity rating of 7.5 according to the CVSS.

2

How do I fix CVE-2026-52860?

To mitigate CVE-2026-52860, upgrade to Vim version 9.2.0597 or later.

3

What type of vulnerability is CVE-2026-52860?

CVE-2026-52860 is classified as a Code Injection vulnerability.

4

What does CVE-2026-52860 affect?

CVE-2026-52860 affects versions of Vim prior to 9.2.0597 that utilize Python omni-completion.

5

What is the potential impact of CVE-2026-52860?

The potential impact of CVE-2026-52860 is arbitrary code execution due to the improper handling of Python function definitions.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203