go-git: Maliciously crafted idx file can cause asymmetric memory consumption
Package
Affected versions
>= 5.0.0, <= 5.17.0
Patched versions
5.17.1
Description
Published to the GitHub Advisory Database
Mar 30, 2026
Reviewed
Mar 30, 2026
Published by the National Vulnerability Database
Mar 31, 2026
Last updated
Mar 31, 2026
Impact
A vulnerability has been identified in which a maliciously crafted
.idxfile can cause asymmetric memory consumption, potentially exhausting available memory and resulting in a Denial of Service (DoS) condition.Exploitation requires write access to the local repository's
.gitdirectory, it order to create or alter existing.idxfiles.Patches
Users should upgrade to
v5.17.1, or the latestv6pseudo-version, in order to mitigate this vulnerability.Credit
The go-git maintainers thank @kq5y for finding and reporting this issue privately to the
go-gitproject.References