Advisory

UBUNTU-CVE-2026-5917

Also known as: CVE-2026-5917

Summary

The record has no summary.

Details

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.

Severity

High Basis: CVSS v3 score 8.8, vector CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Dates

Published
2026-08-11 22:17 UTC
Modified
2026-09-24 07:30 UTC

Affected packages and fixes

libgit2

Debian packages (deb) · Ubuntu 24.04

Affected

  • introduced 0, fixed 1.7.2+ds-1ubuntu3.2 (ecosystem)

Fixed versions

1.7.2+ds-1ubuntu3.2

Fix

  • Fixed version 1.7.2+ds-1ubuntu3.2
    sudo apt-get update && sudo apt-get upgrade

This command upgrades the distribution's packages. Compare the fixed version with the version you have installed.

libgit2

Debian packages (deb) · Ubuntu 26.04

Affected

  • introduced 0, fixed 1.9.1+ds-1ubuntu1.2 (ecosystem)

Fixed versions

1.9.1+ds-1ubuntu1.2

Fix

  • Fixed version 1.9.1+ds-1ubuntu1.2
    sudo apt-get update && sudo apt-get upgrade

This command upgrades the distribution's packages. Compare the fixed version with the version you have installed.

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: Ubuntu Security Notices · CC BY-SA 4.0

Sources & licences