Skip to main content
← All vulnerabilities
CVE-2026-45022GO-2026-5074GHSA-389R-GV7P-R3RP

go-git: Improper parsing of specially crafted objects may lead to inconsistent interpretation compared to upstream Git

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 5.19.0, 6.0.0-alpha.3
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: none
  • Automatable: no
  • Technical impact: partial

Summary

go-git is an extensible git implementation library written in pure Go. Prior to 5.19.0 and 6.0.0-alpha.3, go-git may parse malformed Git objects in a way that differs from upstream Git. When commit or tag objects contain ambiguous or malformed headers, go-git’s decoded representation may expose values differently from how Git itself would interpret or reject the same object. Additionally, go-git’s commit signing and verification logic operates over commit data reconstructed from go-git’s parsed representation rather than the original raw object bytes. As a result, go-git may sign or verify a commit payload that is not byte-for-byte equivalent to the object stored in the repository. This can cause a signature to appear valid for a commit whose displayed or effective metadata differs from the object that was intended to be signed. This vulnerability is fixed in 5.19.0 and 6.0.0-alpha.3.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: none · Automatable: no · Technical impact: partial

  3. Record last updated

Affected versions

  • go-git go-git

    fixed in 5.19.0; From 6.0.0-alpha.1 · fixed in 6.0.0-alpha.3

  • github.com/go-git/go-git/v5Go

    fixed in 5.19.0

  • github.com/go-git/go-git/v6Go

    From 6.0.0-alpha.1 · fixed in 6.0.0-alpha.3

References 1

GitHub · go-git/go-git