CVE-2021-21237
Git LFS can execute a Git binary from the current directory on Windows
Reported by github_m · Published January 15, 2021
Git LFS is a command line extension for managing large files with Git. On Windows, if Git LFS operates on a malicious repository with a git.bat or git.exe file in the current directory, that program would be executed, permitting the attacker to execute arbitrary code. This does not affect Unix systems. This is the result of an incomplete fix for CVE-2020-27955. This issue occurs because on Windows, Go includes (and prefers) the current directory when the name of a command run does not contain a directory separator. Other than avoiding untrusted repositories or using a different operating system, there is no workaround. This is fixed in v2.13.2.
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| git-lfs | git-lfs | < 2.13.2 |
| git-lfs | git-lfs | 0 |
Timeline
- Jan 15, 2021 CVE Published
- Apr 14, 2021 EPSS Score (30 in total, the first dated here)
- Nov 21, 2024 CVE Updated
- Jun 1, 2026 Security Advisory
- Aug 26, 2026 Coalition ESS Score
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2021-21237
vulnetix vdb fixes CVE-2021-21237
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2021-21237/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart