CVE-2021-21237: Git LFS can execute a Git binary from the current directory on Windows
Vulnerability summary
CVE-2021-21237 is a high (CVSS 7.8) Untrusted Search Path vulnerability in git_large_file_storage_project git_large_file_storage. EPSS estimates a 0.45% chance of exploitation in the next 30 days, higher than 41% of scored vulnerabilities.
Not severe (CVSS 7.2, local access); no exploitation reported by the 5 checked sources
Source freshness unavailable
How is this decided?Timeline
- 15-01-2021PublishedVulnerability first disclosed.
- 03-08-2024Last modifiedVulnerability information updated.
Description
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.
CVSS metrics
5 scores · 4 sources · 2 versions- CVE.orgCNA7.2HighCVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:NDiffers
- OSV · UbuntuEcosystem advisory · calculated7.8HighCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- OSV · GoEcosystem advisory · calculated7.2HighCVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:NDiffers
EPSS trend
Probability
0.45%
Chance of exploitation in the next 30 days
Percentile
41%
Versus all other CVEs
30-day change
No change 0.00 pp
From 0.45% on 04-11-2026
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Known conditions: local access, low-privilege account, user interaction (CVSS vector). Other conditions: not stated in public data.
Git_large_file_storage_project1 product
- git_large_file_storage< 2.13.2
Git-lfs1 product
- git-lfs< 2.13.2
Github.com/git-lfs1 product
- git-lfs< 2.13.2 | < 1.5.1-0.20210113180018-fc664697ed2c
Ubuntu1 product
- git-lfsAll versions (No fix recorded)
4 vendors · 4 products
References
9 links- github.com/git-lfs/git-lfs/security/advisories/GHSA-cx3w-xqmc-84g5X Refsource CONFIRMREPORTWEBThird Party Advisory
- github.com/git-lfs/git-lfs/commit/fc664697ed2c2081ee9633010de0a7f9debea72aX Refsource MISCREPORTWEBFIXPatchThird Party Advisory
- github.com/git-lfs/git-lfsPACKAGE