CVE-2021-21237
What it is
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.
At a glance
- Exploitability
- Can be exploited locally on the machine with a low-privilege account, but needs a user to act. High risk of data exposure, data tampering.
- Exploit odds
- 0.5% chance of exploitation in the next 30 days (EPSS).
- Fix
- A patch, advisory or fixed version is referenced. Upgrade or apply it.
Timeline
- PublishedDisclosed publicly on CVE.org and NVD
- Last updatedMost recent change to the record
Why it ranks here
- Exploited in the wild: no, CISA does not list it.
- Exploit odds: 0.5% in the next 30 days (EPSS).
- Severity: 7.2 HIGH (CVSS).
- Fix: a patch or advisory is linked.
Details
- Published
- Last modified
- Exploit probability
- 0.5% · EPSS, next 30 days
- Weakness
- CWE-426
- Record status
- Modified
Affected
- Git Large File Storage Project Git Large File Storage < 2.13.2
Attack profile CVSS 3.1 · 7.2
- Attack vector
- Local
- Complexity
- High
- Privileges needed
- Low
- User interaction
- Required
- Scope
- Changed
- Confidentiality
- High
- Integrity
- High
- Availability
- None
Raw vector
CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:N
Is it in your code?
Hand this to your coding agent. It searches your project for the affected products and checks versions. Nothing leaves your machine.
Read https://cve-list.com/agent/cve/CVE-2021-21237.md and follow it. Check whether this project is affected by CVE-2021-21237. Read only. Don't change anything and don't upload my code. Tell me yes, no or not sure, with the file as proof.
Fix and advisories
- https://github.com/git-lfs/git-lfs/commit/fc664697ed2c2081ee9633010de0a7f9debea72a
- https://github.com/git-lfs/git-lfs/releases/tag/v2.13.2
- https://github.com/git-lfs/git-lfs/security/advisories/GHSA-cx3w-xqmc-84g5
- https://github.com/git-lfs/git-lfs/commit/fc664697ed2c2081ee9633010de0a7f9debea72a
- https://github.com/git-lfs/git-lfs/releases/tag/v2.13.2
- https://github.com/git-lfs/git-lfs/security/advisories/GHSA-cx3w-xqmc-84g5
References
- https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-27955
- https://github.com/git-lfs/git-lfs/commit/fc664697ed2c2081ee9633010de0a7f9debea72a
- https://github.com/git-lfs/git-lfs/releases/tag/v2.13.2
- https://github.com/git-lfs/git-lfs/security/advisories/GHSA-cx3w-xqmc-84g5
- https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-27955
- https://github.com/git-lfs/git-lfs/commit/fc664697ed2c2081ee9633010de0a7f9debea72a
- https://github.com/git-lfs/git-lfs/releases/tag/v2.13.2
- https://github.com/git-lfs/git-lfs/security/advisories/GHSA-cx3w-xqmc-84g5