Description
Git is a revision control system. Prior to versions 2.45.1, 2.44.1, 2.43.4, 2.42.2, 2.41.1, 2.40.2, and 2.39.4, repositories with submodules can be crafted in a way that exploits a bug in Git whereby it can be fooled into writing files not into the submodule's worktree but into a `.git/` directory. This allows writing a hook that will be executed while the clone operation is still running, giving the user no opportunity to inspect the code that is being executed. The problem has been patched in versions 2.45.1, 2.44.1, 2.43.4, 2.42.2, 2.41.1, 2.40.2, and 2.39.4. If symbolic link support is disabled in Git (e.g. via `git config --global core.symlinks false`), the described attack won't work. As always, it is best to avoid cloning repositories from untrusted sources.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| git | git | = 2.45.0, = 2.44.0, >= 2.43.0, < 2.43.4, >= 2.42.0, < 2.42.2, = 2.41.0, >= 2.40.0, < 2.40.2, < 2.39.4 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | git | 1:2.45.1-1 | — |
| Debian 13 | git | 1:2.45.1-1 | — |
| Debian 12 | git | 1:2.39.5-0+deb12u1 | DSA-5769-1 |
| Debian 11 | git | 1:2.30.2-1+deb11u3 | DLA-3867-1 |
| Debian 10 | git | 1:2.20.1-2+deb10u9 | DLA-3844-1 |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 24.04 LTS | git | 1:2.43.0-1ubuntu7.1 | USN-6793-1 |
| Ubuntu 22.04 LTS | git | 1:2.34.1-1ubuntu1.11 | USN-6793-1 |
| Ubuntu 20.04 LTS | git | 1:2.25.1-1ubuntu3.13 | USN-6793-2, USN-6793-1 |
Show 2 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu Pro 18.04 LTS | git | 1:2.17.1-1ubuntu0.18+esm1 | USN-7023-1 |
| Ubuntu Pro 16.04 LTS | git | 1:2.7.4-0ubuntu1.10+esm8 | USN-7023-1 |
Red Hat
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 9 | git +14 | 2.43.5-1.el9_4 | RHSA-2024:4083 |
| RHEL 8 | git +14 | 2.43.5-1.el8_10 | RHSA-2024:4084 |
Show 9 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 9.2 EUS | git +14 | 2.39.5-1.el9_2 | RHSA-2024:4368 |
| RHEL 9.0 E4S | git +14 | 2.31.1-6.el9_0 | RHSA-2024:6610 |
| RHEL 8.8 EUS | git +14 | 2.39.5-1.el8_8 | RHSA-2024:4579 |
| RHEL 8.6 TUS | git +14 | 2.31.8-3.el8_6 | RHSA-2024:6027 |
| RHEL 8.6 E4S | git +14 | 2.31.8-3.el8_6 | RHSA-2024:6027 |
| RHEL 8.6 AUS | git +14 | 2.31.8-3.el8_6 | RHSA-2024:6027 |
| RHEL 8.4 TUS | git +14 | 2.27.0-5.el8_4 | RHSA-2024:6028 |
| RHEL 8.4 E4S | git +14 | 2.27.0-5.el8_4 | RHSA-2024:6028 |
| RHEL 8.4 AUS | git +14 | 2.27.0-5.el8_4 | RHSA-2024:6028 |
AlmaLinux
Errata ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| AlmaLinux 9 | git +14 | 2.43.5-1.el9_4 | ALSA-2024:4083 |
| AlmaLinux 8 | git +14 | 2.43.5-1.el8_10 | ALSA-2024:4084 |
Rocky Linux
Errata ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Rocky Linux 9 | git | 2.43.5-1.el9_4 | RLSA-2024:4083 |
| Rocky Linux 8 | git | 2.43.5-1.el8_10 | RLSA-2024:4084 |
SUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES 15 SP6 | git | 2.43.0-150600.3.3.1 | SUSE-SU-2024:2277-1 |
| SLES 15 SP5 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SLES 15 SP4 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SLES 15 SP3 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SLES 15 SP2 | git | 2.26.2-150000.56.1 | SUSE-SU-2024:1854-1 |
Show 12 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES 12 SP5 | git | 2.26.2-27.78.1 | SUSE-SU-2025:0197-1 |
| SLES for SAP 15 SP4 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SLES for SAP 15 SP3 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SLES for SAP 15 SP2 | git | 2.26.2-150000.56.1 | SUSE-SU-2024:1854-1 |
| SLE Micro 6.0 | git | 2.45.1-1.1 | SUSE-SU-2025:20049-1 |
| SLE Micro 5.5 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-2, SUSE-SU-2024:1807-1 |
| SLE HPC 15 SP4 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SLE HPC 15 SP3 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SLE HPC 15 SP2 | git | 2.26.2-150000.56.1 | SUSE-SU-2024:1854-1 |
| SUSE Manager Server 4.3 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SUSE Manager Proxy 4.3 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
| SUSE Enterprise Storage 7.1 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Tumbleweed | git | 2.45.1-1.1 | openSUSE-SU-2024:13968-1 |
| openSUSE Leap 15.6 | git | 2.43.0-150600.3.3.1 | SUSE-SU-2024:2277-1 |
| openSUSE Leap 15.5 | git | 2.35.3-150300.10.39.1 | SUSE-SU-2024:1807-1 |
Alpine
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine v3.24 | git | 2.45.1-r0 | — |
| Alpine v3.23 | git | 2.45.1-r0 | — |
| Alpine v3.22 | git | 2.45.1-r0 | — |
| Alpine v3.21 | git | 2.45.1-r0 | — |
| Alpine v3.20 | git | 2.45.1-r0 | — |
Show 3 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine v3.19 | git | 2.43.4-r0 | — |
| Alpine v3.18 | git | 2.40.3-r0 | — |
| Alpine v3.17 | git | 2.39.5-r0 | — |
Amazon Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Amazon Linux 2023 | git +16 | 2.40.1-1.amzn2023.0.3 | ALAS2023-2024-623 |
| Amazon Linux 2 | git +16 | 2.40.1-1.amzn2.0.3 | ALAS2-2024-2548 |
Azure Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Azure Linux 3 | git | 2.45.2-1 | — |
| Azure Linux 2 (CBL-Mariner) | git | 2.39.4-1 | — |
Oracle Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Oracle Linux 9 | git +14 | 2.43.5-1.el9_4 | ELSA-2024-4083 |
| Oracle Linux 8 | git +14 | 2.43.5-1.el8_10 | ELSA-2024-4084 |
Wolfi
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Wolfi rolling | git | 2.45.1-r0 | — |
Public exploits
Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.
GitHub 65 repositories · most starred shown
-
amalmurali47/git_rce ★ 533 · May 17, 2024
Exploit PoC for CVE-2024-32002
-
safebuffer/CVE-2024-32002 ★ 108 · May 18, 2024
CVE-2024-32002 RCE PoC
-
amalmurali47/hook ★ 18 · May 17, 2024
Hook for the PoC for exploiting CVE-2024-32002
-
M507/CVE-2024-32002 ★ 10 · May 18, 2024
local poc for CVE-2024-32002
-
YukaFake/CVE-2024-32002-Reverse-Shell ★ 6 · May 21, 2024
Este script demuestra cómo explotar la vulnerabilidad CVE-2024-32002 para obtener una reverse shell, proporcionando acceso remoto al sistema afectado. Úselo con precaución en entornos controlados y s…
-
NishanthAnand21/CVE-2024-32002-PoC ★ 3 · Jul 30, 2024
PoC of CVE-2024-32002 - Remote Code Execution while cloning special-crafted local repositories
-
jweny/CVE-2024-32002_EXP ★ 3 · May 20, 2024
-
jweny/CVE-2024-32002_HOOK ★ 3 · May 20, 2024
-
bfengj/CVE-2024-32002-Exploit ★ 2 · May 22, 2024
-
markuta/CVE-2024-32002 ★ 2 · May 17, 2024
A proof of concept for the git vulnerability CVE-2024-32002
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
Advisories 32
- ALSA-2024:4083 Important: git security update AlmaLinux Security Advisories · Oct 29, 2026
- ALSA-2024:4084 Important: git security update AlmaLinux Security Advisories · Oct 29, 2026
- RHSA-2024:6610 Red Hat Security Advisory: git security update Red Hat Security Advisories (RHSA) · Aug 5, 2026
- RHSA-2024:6027 Red Hat Security Advisory: git security update Red Hat Security Advisories (RHSA) · Aug 5, 2026
- RHSA-2024:6028 Red Hat Security Advisory: git security update Red Hat Security Advisories (RHSA) · Aug 5, 2026
- RHSA-2024:4579 Red Hat Security Advisory: git security update Red Hat Security Advisories (RHSA) · Aug 5, 2026
- RHSA-2024:4368 Red Hat Security Advisory: git security update Red Hat Security Advisories (RHSA) · Aug 5, 2026
- RHSA-2024:4084 Red Hat Security Advisory: git security update Red Hat Security Advisories (RHSA) · Aug 5, 2026
- RHSA-2024:4083 Red Hat Security Advisory: git security update Red Hat Security Advisories (RHSA) · Aug 5, 2026
- USN-7023-1 git vulnerabilities Ubuntu Security Notices (USN) · Jun 25, 2026
- SUSE-SU-2025:20049-1 Security update for git SUSE / openSUSE Security Updates · Mar 23, 2026
- DSA-5769-1 git - security update Debian Security (DSA / DLA) · Mar 9, 2026
- DLA-3844-1 git - security update Debian Security (DSA / DLA) · Mar 9, 2026
- DLA-3867-1 git - security update Debian Security (DSA / DLA) · Mar 9, 2026
- USN-6793-1 git vulnerabilities Ubuntu Security Notices (USN) · Feb 10, 2026
- USN-6793-2 git vulnerability Ubuntu Security Notices (USN) · Feb 10, 2026
- RLSA-2024:4084 Important: git security update Rocky Linux Security Advisories · Feb 5, 2026
- RLSA-2024:4083 Important: git security update Rocky Linux Security Advisories · Feb 4, 2026
- SUSE-SU-2024:1807-2 Security update for git SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2024:1854-1 Security update for git SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2024:2277-1 Security update for git SUSE / openSUSE Security Updates · Feb 4, 2026
- openSUSE-SU-2024:13968-1 git-2.45.1-1.1 on GA media SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2025:0197-1 Security update for git SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2024:1807-1 Security update for git SUSE / openSUSE Security Updates · Feb 4, 2026
- WID-SEC-2025-0794 Juniper Junos Space: Mehrere Schwachstellen BSI CERT-Bund (WID) · Sep 4, 2025
- WID-SEC-2024-1125 git: Mehrere Schwachstellen BSI CERT-Bund (WID) · Jun 4, 2025
- VDE-2024-071 Phoenix Contact: Multiple Vulnerabilities in PLCnext Firmware CERT@VDE · May 22, 2025
- ELSA-2024-4084 Important: git security update (Oracle Linux 8) Oracle Linux Security Advisories (ELSA) · Jun 25, 2024
- ELSA-2024-4083 Important: git security update (Oracle Linux 9) Oracle Linux Security Advisories (ELSA) · Jun 25, 2024
- WID-SEC-2024-1115 Microsoft Developer Tools: Mehrere Schwachstellen BSI CERT-Bund (WID) · May 30, 2024
- ALAS2-2024-2548 Important: git security update (Amazon Linux 2) Amazon Linux Security Center (ALAS) · May 29, 2024
- ALAS2023-2024-623 Important: git security update (Amazon Linux 2023) Amazon Linux Security Center (ALAS) · May 28, 2024
References
- https://github.com/git/git/security/advisories/GHSA-8h77-4q3w-gfgv
- https://github.com/git/git/commit/97065761333fd62db1912d81b489db938d8c991d
- https://git-scm.com/docs/git-clone#Documentation/git-clone.txt---recurse-submodulesltpathspecgt
- https://git-scm.com/docs/git-config#Documentation/git-config.txt-coresymlinks
- https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/S4CK4IYTXEOBZTEM5K3T6LWOIZ3S44AR/
- http://www.openwall.com/lists/oss-security/2024/05/14/2
- https://lists.debian.org/debian-lts-announce/2024/06/msg00018.html