Skip to main content
Live Webinar with SANS (June 25)— Agentic CTI Automation for Fun & ProfitRegister Free
Mallory
Back to intelligence

Vim Cucumber Plugin Code Injection Lets Malicious Repos Execute Ruby

Updated 29d agoFirst seen May 17, 20263 sources

Vim disclosed a medium-severity code injection flaw in its Cucumber filetype plugin that affects versions earlier than 9.2.0496 when compiled with +ruby support. The bug is in s:stepmatch() in runtime/ftplugin/cucumber.vim, where attacker-controlled step-definition regex patterns from repository .rb files were inserted into Ruby Kernel.eval() without sufficient escaping, allowing arbitrary Ruby execution and potentially shell command execution. The issue is tracked in GitHub Security Advisory GHSA-4473-94jm-w5x9 and mapped to CWE-94 and CWE-95.

Exploitation requires a user to open a malicious cucumber-style repository and trigger the step-jump mappings [d] or ]d on a matching feature line; the vulnerability does not fire through omni-completion alone because CucumberComplete() does not call the vulnerable path. Vim fixed the bug in patch 9.2.0496 by replacing Kernel.eval() with Regexp.new(), keeping the regex as untrusted data rather than executable code, and added a regression test using a proof-of-concept payload that attempted to invoke system("touch ..."). The project credited Aisle Research for reporting and analyzing the flaw.

Share:
Stay ahead

Get ahead of threats like this

Mallory correlates global threat intelligence with your attack surface — know if you’re exposed before adversaries strike.

EVENT TIMELINE

How this story unfolded

4 events from the most recent confirmed update back to the earliest known activity.

4 EVENTS
May 17, 20261mo ago

oss-sec notice publishes details of the Vim code injection issue

An oss-sec mailing list post announced the Vimscript code injection vulnerability in the cucumber filetype plugin, including affected versions, exploitation requirements, and the availability of patch 9.2.0496. The notice also credited Aisle Research for reporting and analysis.

GitHub advisory GHSA-4473-94jm-w5x9 discloses the Vim flaw

A GitHub Security Advisory publicly disclosed the medium-severity vulnerability affecting Vim versions earlier than 9.2.0496 and described the exploitation conditions, affected component, and impact. The advisory noted that a CVE had been requested but was not yet assigned.

Vim releases patch 9.2.0496 to fix the vulnerability

Vim fixed the cucumber plugin vulnerability in patch v9.2.0496 by replacing the unsafe Kernel.eval() usage with Regexp.new(), preventing untrusted regex data from being executed as code. The patch also added a regression test with a proof-of-concept payload to verify the exploit no longer works.

Aisle Research reports Vim cucumber plugin code injection flaw

Aisle Research identified and reported a code injection vulnerability in Vim's cucumber filetype plugin, where attacker-controlled step-definition regex patterns could reach Ruby's Kernel.eval() in s:stepmatch(). The issue affected Vim builds with +ruby support and could lead to arbitrary Ruby and shell command execution when users invoked step-jump mappings in a malicious repository.

LINKED ENTITIES

Related entities

Vulnerabilities, threat actors, malware, products, organizations, and breaches Mallory has linked to this story.

3 LINKEDOpen in app
Affected products
1 linked
Vim
Organizations
2 linked
GitHubAisle Research
The operational view lives in Mallory

See the full picture, correlated to your attack surface.

This page covers what’s public. Mallory adds the parts that aren’t — which of your assets are affected, which threat actors are using it right now, which detections to deploy, and what to do next.
Exposure mapping

Map indicators from this story to your assets and identify affected systems in minutes.

Threat actor evidence

Every observed campaign, victim, and pivot linked to actors named in this story.

Associated malware

Malware, exploits, and IOCs connected to the activity described here.

Detection signatures

YARA, Sigma, and Snort rules deployed to your SIEM as soon as they’re published.

Scheduled alerts

Get matching new stories delivered to your team as they break — not the next morning.

AI threads

Ask questions about this story and take action on the answers.

Vim Cucumber Plugin Code Injection Lets Malicious Repos Execute Ruby | Mallory