{"id":"CVE-2024-32002","published":"2024-05-14T18:40:46Z","modified":"2025-11-04T16:12:09Z","title":"Git's recursive clones on case-insensitive filesystems that support symlinks are susceptible to Remote Code Execution","vendor":"git","product":"git","tier":"tail","description":{"text":"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.","provenance":"source","from":"CVE.org"},"cvss":{"score":9.1,"severity":"CRITICAL","version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.29234,"percentile":0.98217,"provenance":"source"},"cwes":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"},{"id":"CWE-434","name":"Unrestricted Upload of File with Dangerous Type"}],"references":[{"url":"https://github.com/git/git/security/advisories/GHSA-8h77-4q3w-gfgv","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/git/git/commit/97065761333fd62db1912d81b489db938d8c991d","tags":["x_refsource_MISC"]},{"url":"https://git-scm.com/docs/git-clone#Documentation/git-clone.txt---recurse-submodulesltpathspecgt","tags":["x_refsource_MISC"]},{"url":"https://git-scm.com/docs/git-config#Documentation/git-config.txt-coresymlinks","tags":["x_refsource_MISC"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/S4CK4IYTXEOBZTEM5K3T6LWOIZ3S44AR/","tags":[]},{"url":"http://www.openwall.com/lists/oss-security/2024/05/14/2","tags":[]},{"url":"https://lists.debian.org/debian-lts-announce/2024/06/msg00018.html","tags":[]},{"url":"https://lists.debian.org/debian-lts-announce/2024/09/msg00009.html","tags":[]}],"priority":{"score":31.0,"factors":[{"name":"EPSS percentile","points":19.64},{"name":"Public exploit code","points":5.0},{"name":"CVSS severity","points":6.37}]},"exploitSources":{"pocGithub":{"count":48,"skipped":17,"earliest":"2024-05-17","earliestUrl":"https://github.com/markuta/CVE-2024-32002","repos":[{"name":"amalmurali47/git_rce","url":"https://github.com/amalmurali47/git_rce","stars":531,"created":"2024-05-17"},{"name":"safebuffer/CVE-2024-32002","url":"https://github.com/safebuffer/CVE-2024-32002","stars":107,"created":"2024-05-18"},{"name":"amalmurali47/hook","url":"https://github.com/amalmurali47/hook","stars":18,"created":"2024-05-17"},{"name":"M507/CVE-2024-32002","url":"https://github.com/M507/CVE-2024-32002","stars":10,"created":"2024-05-18"},{"name":"YukaFake/CVE-2024-32002-Reverse-Shell","url":"https://github.com/YukaFake/CVE-2024-32002-Reverse-Shell","stars":6,"created":"2024-05-21"}]},"first":{"date":"2024-05-17","source":"PoC-in-GitHub","url":"https://github.com/markuta/CVE-2024-32002"},"provenance":"source"},"vendorSlug":"git","affectedVersions":[{"vendor":"git","product":"git","versions":["= 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"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total","timestamp":"2024-05-29T14:18:00.384488Z","from":"CISA ADP","provenance":"source"},"summary":{"text":"Git (git) has a flaw in its handling of recursive clones of repositories with submodules on case-insensitive filesystems that support symlinks, where crafted repositories can cause files to be written into a .git/ directory instead of the submodule's worktree. An attacker who supplies a crafted repository can place a hook there that executes during the clone operation, requiring only network access to a repository the user clones, with no authentication and no further interaction beyond cloning; disabling symbolic link support in Git (core.symlinks set to false) prevents the attack.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-21T00:17:51Z"},"euvd":{"id":"EUVD-2024-29843","exploited":false,"provenance":"source"}}