CVE-2026-33718 json
OpenHands is Vulnerable to Command Injection through its Git Diff Handler
published 7mo ago modified 4mo ago also GHSA-7h8w-hj9j-8rjw , PYSEC-2026-106 , EUVD-2026-16500
- cvss
- 7.6
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 2.0%
- EPSS 2.0% chance of exploitation in 30 days, percentile 80%
- public exploits
- 0
- none known
Summary
OpenHands is software for AI-driven development. Starting in version 1.5.0, a Command Injection vulnerability exists in the `get_git_diff()` method at `openhands/runtime/utils/git_handler.py:134`. The `path` parameter from the `/api/conversations/{conversation_id}/git/diff` API endpoint is passed unsanitized to a shell command, allowing authenticated attackers to execute arbitrary commands in the agent sandbox. The user is already allowed to instruct the agent to execute commands, but this bypasses the normal channels. Version 1.5.0 fixes the issue.
Patch / fix
Is CVE-2026-33718 in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.
Check with FencerCISA SSVC
- Exploitation
- none
- Automatable
- no
- Technical impact
- partial
- Assessed
- 7mo ago
Exploit prediction
2.01% chance of exploitation in the next 30 days, higher than 80% of all scored CVEs (FIRST EPSS, 2026-11-09).
Exploits and checks
- github.com https://github.com/OpenHands/OpenHands/security/advisories/GHSA-7h8w-hj9j-8rjw referenced PoC, tagged "exploit" by a source, unverified
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 7.6 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:L |
| NVD | 3.1 | 9.9 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H |
| OSV | 3.1 | 9.9 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H |
| GitHub | 3.1 | 7.6 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:L |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| pypi | openhands-ai | <1.5.0 |
1.5.0 |
Affected products
- OpenHands OpenHands
Classification
- Weakness
-
- CWE-78 Improper Neutralization of Special Elements used in an OS Command
References
-
github.com
/OpenHands/OpenHands/pull/13051
web, issue-tracking, patch
-
github.com
/OpenHands/OpenHands/security/advisories/GHSA-7h8w-hj9j-8rjw
web, exploit, mitigation, vendor-advisory, evidence
-
docs.python.org
/3/library/shlex.html#shlex.quote
web, technical-description, article
-
docs.python.org
/3/library/subprocess.html#security-considerations
web, technical-description, article
-
owasp.org
/www-community/attacks/Command_Injection
web, technical-description, article
-
nvd.nist.gov
/vuln/detail/CVE-2026-33718
advisory
-
github.com
/OpenHands/OpenHands
package
-
github.com
/pypa/advisory-database/tree/main/vulns/openhands-ai/PYSEC-2026-106.yaml
web
Sources
- CVE List CVE-2026-33718
- GitHub Advisory GHSA-7h8w-hj9j-8rjw
- NVD CVE-2026-33718
- OSV PYSEC-2026-106
Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.