CVE-2026-5917
Last modified
CVE-2026-5917 is a high-severity vulnerability rated 8.8/10 on the CVSS scale. libgit2 versions before 1.8.7 and 1.9.0 before 1.9.7 built with the libssh2 SSH backend (USE_SSH=libssh2) contain a shell command injection vulnerability that allows remote attackers to execute arbitrary commands on an SSH server by supplying a repository path containing unescaped shell metacharacters such as single quotes, semicolons, or pipes. The gen_proto() function in ssh_libssh2.c inserts the repository path directly into a shell command string without escaping special characters before passing it to libssh2_channel_exec(), enabling an attacker to craft a malicious submodule URL in a .gitmodules file that, when processed during a recursive clone, causes the remote server's shell to interpret injected commands under the victim's SSH user account.. EPSS estimates a 1.43% chance of exploitation in the next 30 days.
Description
libgit2 versions before 1.8.7 and 1.9.0 before 1.9.7 built with the libssh2 SSH backend (USE_SSH=libssh2) contain a shell command injection vulnerability that allows remote attackers to execute arbitrary commands on an SSH server by supplying a repository path containing unescaped shell metacharacters such as single quotes, semicolons, or pipes. The gen_proto() function in ssh_libssh2.c inserts the repository path directly into a shell command string without escaping special characters before passing it to libssh2_channel_exec(), enabling an attacker to craft a malicious submodule URL in a .gitmodules file that, when processed during a recursive clone, causes the remote server's shell to interpret injected commands under the victim's SSH user account.
Metrics
Weakness Enumeration
Affected Software
Source: CNA advisory (CVE.org). NVD analysis pending.
| Vendor | Product | Versions |
|---|---|---|
| libgit2 | libgit2 | < 1.8.7; >= 1.9.0, < 1.9.7 |
References
Timeline
- Published
- Last Modified
- Status
- Deferred
Frequently Asked Questions
What is CVE-2026-5917?
How severe is CVE-2026-5917?
How do I fix CVE-2026-5917?
How Strix Helps
- How Strix found a critical auth bypass in etcdStrix autonomously discovered a critical authentication bypass in etcd, later designated CVE-2026-33413.
- Autonomous PentestingAI agents that find and validate exploitable vulnerabilities like this one across your applications.
- PR ReviewsPentest every pull request so vulnerable code is caught before it ships to production.
- AI Penetration TestingHow AI-driven penetration testing continuously covers your attack surface.
Related CVEs from 2026
- CVE-2026-59161Excelize is a Go language library for reading and writing Mi…7.5
- CVE-2026-59162Excelize is a Go language library for reading and writing Mi…7.5
- CVE-2026-59163Mnemosyne is a memory layer for artificial intelligence agen…9.1
- CVE-2026-59164NORA is a self-hosted artifact registry and pull-through cac…7.1
- CVE-2026-59167SunEditor is a lightweight and powerful WYSIWYG editor in va…10
- CVE-2026-59168Dasel is a command-line tool and library for querying, modif…6.2
- CVE-2026-59171JSON-java is a reference implementation of a JSON package in…5.9
- CVE-2026-59172Joker is a small Clojure interpreter, linter and formatter w…7.8
- CVE-2026-59173Uncontrolled Resource Consumption vulnerability in Apache Tr…7.5
- CVE-2026-59176Functype is a family of TypeScript functional programming li…7.8
- CVE-2026-59177ESPHome Device Builder Dashboard is a dashboard for the ESPH…8.8
- CVE-2026-59178ESPHome Device Builder Dashboard is a dashboard for the ESPH…9.8
Are you affected by CVE-2026-5917?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
