PT-2026-70930 · Libssh2+1 · Libssh2+1

·

CVE-2026-5917

·

Published

2026-08-11

·

Updated

2026-08-26

CVSS v3.1

8.8

High

VectorAV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
Name of the Vulnerable Software and Affected Versions libgit2 versions 0.27.0 through 1.9.0
Description Remote attackers can execute arbitrary commands on an SSH server when the software is built with the libssh2 SSH backend (USE SSH=libssh2). The issue occurs because 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(). An attacker can exploit this by crafting a malicious submodule URL in a .gitmodules file; when processed during a recursive clone, the remote server's shell interprets the injected shell metacharacters, such as single quotes, semicolons, or pipes, executing commands under the victim's SSH user account.
Recommendations At the moment, there is no information about a newer version that contains a fix for this vulnerability.

Exploit

OS Command Injection

Found an issue in the description? Have something to add? Feel free to write us 👾

Weakness Enumeration

Related Identifiers

CVE-2026-5917
ECHO-25C0-43EF-F653
GHSA-XQJ4-2J5V-RR75
JLSEC-2026-1275
OPENSUSE-SU-2026:11521-1

Affected Products

Libgit2
Libssh2