← Terug naar overzicht

A vulnerability in libgit2 prior to versions 1.8.6 and 1.9.5 allows a malicious Git server to crash a client via a heap out-of-bounds read. The flaw resides in the set_data function in src/libgit2/transports/smart_pkt.c, where a fixed-size strncmp is performed without verifying that the smart-protocol pkt-line capability buffer contains at least 14 bytes. An attacker-controlled Git server can craft a pkt-line that causes format_str to advance beyond the buffer boundary, leading to an integer underflow in a subsequent memchr length calculation. This results in a heap out-of-bounds walk that can crash the client during the first refs-advertisement packet. The vulnerability affects clients using HTTP, HTTPS, SSH, or the Git protocol. Fixes are available in libgit2 versions 1.8.6 and 1.9.5.

Affected products

  • libgit2

Related CVE's

  • CVE-2026-53587

Categories

  • Supply Chain & Dependencies
  • Web Technologies