CVE-2025-21613
Description
go-git is a highly extensible git implementation library written in pure Go. An argument injection vulnerability was discovered in go-git versions prior to v5.13. Successful exploitation of this vulnerability could allow an attacker to set arbitrary values to git-upload-pack flags. This only happens when the file transport protocol is being used, as that is the only protocol that shells out to git binaries. This vulnerability is fixed in 5.13.0.
How to fix
- go-git_project go-git5.13.0 or later
- github.com/go-git/go-git/v55.13.0 or later
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| go-git_project go-git | v < 5.13.0 | 5.13.0 |
| gopkg.in/src-d/go-git.v4Go | 4.0.0 ≤ v ≤ 4.13.1, 4.0.0 ≤ v | — |
| github.com/go-git/go-git/v5Go | v < 5.13.0 | 5.13.0 |
| github.com/go-git/go-git/v4Go | 4.0.0 ≤ v | — |
Check your version
Choose the product and enter the version you run to see whether it falls in the affected range.
Attack Surface Management
See the assets tied to your domains, the technologies they run and known vulnerabilities in one list.