CVE-2026-28291: CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') in steveukx git-js
simple-git enables running native Git commands from JavaScript. Versions up to and including 3.31.1 allow execution of arbitrary commands through Git option manipulation, bypassing safety checks meant to block dangerous options like -u and --upload-pack. The flaw stems from an incomplete fix for CVE-2022-25860, as Git's flexible option parsing allows numerous character combinations (e.g., -vu, -4u, -nu) to circumvent the regular-expression-based blocklist in the unsafe operations plugin. Due to the virtually infinite number of valid option variants that Git accepts, a complete blocklist-based mitigation may be infeasible without fully emulating Git's option parsing behavior. This issue has been fixed in version 3.32.0.
AI Analysis
Technical Summary
The vulnerability in simple-git (git-js) up to and including version 3.31.1 allows attackers to execute arbitrary OS commands by manipulating Git command options. The root cause is that Git's option parsing accepts many character combinations (e.g., -vu, -4u, -nu) that bypass the regular-expression-based blocklist designed to prevent dangerous options like -u and --upload-pack. This incomplete mitigation from a previous CVE (CVE-2022-25860) means that attackers can craft options to circumvent safety checks. The complexity of Git's option parsing makes a comprehensive blocklist approach ineffective without fully emulating Git's parsing logic. The issue is resolved in version 3.32.0.
Potential Impact
Successful exploitation allows remote attackers to execute arbitrary OS commands without privileges or user interaction, leading to full confidentiality, integrity, and availability compromise of the affected system. This can result in unauthorized code execution and potential system takeover.
Mitigation Recommendations
Upgrade simple-git (git-js) to version 3.32.0 or later, where this vulnerability is fixed. Patch status is confirmed by the vendor advisory. No other mitigations are indicated as effective due to the complexity of Git's option parsing and the nature of the vulnerability.
CVE-2026-28291: CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') in steveukx git-js
Description
simple-git enables running native Git commands from JavaScript. Versions up to and including 3.31.1 allow execution of arbitrary commands through Git option manipulation, bypassing safety checks meant to block dangerous options like -u and --upload-pack. The flaw stems from an incomplete fix for CVE-2022-25860, as Git's flexible option parsing allows numerous character combinations (e.g., -vu, -4u, -nu) to circumvent the regular-expression-based blocklist in the unsafe operations plugin. Due to the virtually infinite number of valid option variants that Git accepts, a complete blocklist-based mitigation may be infeasible without fully emulating Git's option parsing behavior. This issue has been fixed in version 3.32.0.
CVSS v3.1
Score 8.1high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability in simple-git (git-js) up to and including version 3.31.1 allows attackers to execute arbitrary OS commands by manipulating Git command options. The root cause is that Git's option parsing accepts many character combinations (e.g., -vu, -4u, -nu) that bypass the regular-expression-based blocklist designed to prevent dangerous options like -u and --upload-pack. This incomplete mitigation from a previous CVE (CVE-2022-25860) means that attackers can craft options to circumvent safety checks. The complexity of Git's option parsing makes a comprehensive blocklist approach ineffective without fully emulating Git's parsing logic. The issue is resolved in version 3.32.0.
Potential Impact
Successful exploitation allows remote attackers to execute arbitrary OS commands without privileges or user interaction, leading to full confidentiality, integrity, and availability compromise of the affected system. This can result in unauthorized code execution and potential system takeover.
Mitigation Recommendations
Upgrade simple-git (git-js) to version 3.32.0 or later, where this vulnerability is fixed. Patch status is confirmed by the vendor advisory. No other mitigations are indicated as effective due to the complexity of Git's option parsing and the nature of the vulnerability.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-02-26T01:52:58.735Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
- Vendor Advisory Urls
- [{"url":"https://access.redhat.com/security/cve/CVE-2026-28291","vendor":"Red Hat"}]
Threat ID: 69de21bb82d89c981f27528a
Added to database: 04/14/2026, 11:15:07 UTC
Last enriched: 07/15/2026, 08:46:08 UTC
Last updated: 07/26/2026, 20:52:04 UTC
Views: 215
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.