CVE-2025-21613

Critical

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.

SeverityCritical
CVSS9.8
Exploit probability—
ProductGo-git
PublishedJan 6, 2025
First seenJan 6, 2025
Weakness typeCWE-88CWE-88

How to fix

Update
  • go-git_project go-git5.13.0 or later
  • github.com/go-git/go-git/v55.13.0 or later

Affected products

ProductAffected versionsFixed in
go-git_project go-gitv < 5.13.05.13.0
gopkg.in/src-d/go-git.v4Go4.0.0 ≤ v ≤ 4.13.1, 4.0.0 ≤ v—
github.com/go-git/go-git/v5Gov < 5.13.05.13.0
github.com/go-git/go-git/v4Go4.0.0 ≤ v—

Check your version

Choose the product and enter the version you run to see whether it falls in the affected range.

In the Intelligence 360 plan

Attack Surface Management

See the assets tied to your domains, the technologies they run and known vulnerabilities in one list.