CVE-2022-39260 Details
Description
Git is an open source, scalable, distributed revision control system. `git shell` is a restricted login shell that can be used to implement Git's push/pull functionality via SSH. In versions prior to 2.30.6, 2.31.5, 2.32.4, 2.33.5, 2.34.5, 2.35.5, 2.36.3, and 2.37.4, the function that splits the command arguments into an array improperly uses an `int` to represent the number of entries in the array, allowing a malicious actor to intentionally overflow the return value, leading to arbitrary heap writes. Because the resulting array is then passed to `execv()`, it is possible to leverage this attack to gain remote code execution on a victim machine. Note that a victim must first allow access to `git shell` as a login shell in order to be vulnerable to this attack. This problem is patched in versions 2.30.6, 2.31.5, 2.32.4, 2.33.5, 2.34.5, 2.35.5, 2.36.3, and 2.37.4 and users are advised to upgrade to the latest version. Disabling `git shell` access via remote logins is a viable short-term workaround.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
No SSVC data is available for this CVE.
References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-787 | Out-of-bounds Write | [email protected] |
| CWE-122 | Heap-based Buffer Overflow | [email protected] |
| CWE-787 | Out-of-bounds Write | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| git-scm git | < 2.30.6 >= 2.31.0, < 2.31.5 >= 2.32.0, < 2.32.4 >= 2.33.0, < 2.33.5 >= 2.34.0, < 2.34.5 >= 2.35.0, < 2.35.5 >= 2.36.0, < 2.36.3 >= 2.37.0, < 2.37.4 2.38.0 |
CPE
Remediation
| |
| fedoraproject fedora | 35 36 37 |
CPE
Remediation
| |
| apple xcode | < 14.1 |
CPE
Remediation
| |
| debian debian linux | 10.0 |
CPE
Remediation
| |
Change History
14 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | [email protected] |
| Nov 21, 2024 | CVE Modified | CVE |
| May 14, 2024 | CVE Modified | [email protected] |
| Dec 27, 2023 | CVE Modified | [email protected] |
| Nov 7, 2023 | CVE Modified | [email protected] |
| Feb 16, 2023 | Modified Analysis | [email protected] |
| Dec 14, 2022 | CVE Modified | [email protected] |
| Nov 16, 2022 | Modified Analysis | [email protected] |
| Nov 14, 2022 | CVE Modified | [email protected] |
| Nov 8, 2022 | CVE Modified | [email protected] |
| Nov 2, 2022 | CVE Modified | [email protected] |
| Nov 1, 2022 | CVE Modified | [email protected] |
| Oct 28, 2022 | CVE Modified | [email protected] |
| Oct 21, 2022 | Initial Analysis | [email protected] |