CVE-2024-32465 – Git's protections for cloning untrusted repositories can be bypassed
https://notcve.org/view.php?id=CVE-2024-32465
Git is a revision control system. The Git project recommends to avoid working in untrusted repositories, and instead to clone it first with `git clone --no-local` to obtain a clean copy. Git has specific protections to make that a safe operation even with an untrusted source repository, but vulnerabilities allow those protections to be bypassed. In the context of cloning local repositories owned by other users, this vulnerability has been covered in CVE-2024-32004. But there are circumstances where the fixes for CVE-2024-32004 are not enough: For example, when obtaining a `.zip` file containing a full copy of a Git repository, it should not be trusted by default to be safe, as e.g. hooks could be configured to run within the context of that repository. • http://www.openwall.com/lists/oss-security/2024/05/14/2 https://git-scm.com/docs/git#_security https://git-scm.com/docs/git-clone https://github.com/git/git/commit/7b70e9efb18c2cc3f219af399bd384c5801ba1d7 https://github.com/git/git/security/advisories/GHSA-vm9j-46j9-qvq4 https://lists.debian.org/debian-lts-announce/2024/06/msg00018.html https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/S4CK4IYTXEOBZTEM5K3T6LWOIZ3S44AR https://access.redhat.com/security • CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') •
CVE-2024-32021 – Local Git clone may hardlink arbitrary user-readable files into the new repository's "objects/" directory
https://notcve.org/view.php?id=CVE-2024-32021
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, when cloning a local source repository that contains symlinks via the filesystem, Git may create hardlinks to arbitrary user-readable files on the same filesystem as the target repository in the `objects/` directory. Cloning a local repository over the filesystem may creating hardlinks to arbitrary user-owned files on the same filesystem in the target Git repository's `objects/` directory. When cloning a repository over the filesystem (without explicitly specifying the `file://` protocol or `--no-local`), the optimizations for local cloning will be used, which include attempting to hard link the object files instead of copying them. While the code includes checks against symbolic links in the source repository, which were added during the fix for CVE-2022-39253, these checks can still be raced because the hard link operation ultimately follows symlinks. • http://www.openwall.com/lists/oss-security/2024/05/14/2 https://github.com/git/git/security/advisories/GHSA-mvxm-9j2h-qjx7 https://lists.debian.org/debian-lts-announce/2024/06/msg00018.html https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/S4CK4IYTXEOBZTEM5K3T6LWOIZ3S44AR https://access.redhat.com/security/cve/CVE-2024-32021 https://bugzilla.redhat.com/show_bug.cgi?id=2280484 • CWE-61: UNIX Symbolic Link (Symlink) Following CWE-547: Use of Hard-coded, Security-relevant Constants •
CVE-2024-32020 – Cloning local Git repository by untrusted user allows the untrusted user to modify objects in the cloned repository at will
https://notcve.org/view.php?id=CVE-2024-32020
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, local clones may end up hardlinking files into the target repository's object database when source and target repository reside on the same disk. If the source repository is owned by a different user, then those hardlinked files may be rewritten at any point in time by the untrusted user. Cloning local repositories will cause Git to either copy or hardlink files of the source repository into the target repository. This significantly speeds up such local clones compared to doing a "proper" clone and saves both disk space and compute time. • http://www.openwall.com/lists/oss-security/2024/05/14/2 https://github.com/git/git/commit/1204e1a824c34071019fe106348eaa6d88f9528d https://github.com/git/git/commit/9e65df5eab274bf74c7b570107aacd1303a1e703 https://github.com/git/git/security/advisories/GHSA-5rfh-556j-fhgj https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/S4CK4IYTXEOBZTEM5K3T6LWOIZ3S44AR https://access.redhat.com/security/cve/CVE-2024-32020 https://bugzilla.redhat.com/show_bug.cgi?id=2280466 • CWE-62: UNIX Hard Link CWE-281: Improper Preservation of Permissions •
CVE-2024-32004 – Git vulnerable to Remote Code Execution while cloning special-crafted local repositories
https://notcve.org/view.php?id=CVE-2024-32004
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, an attacker can prepare a local repository in such a way that, when cloned, will execute arbitrary code during the operation. 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. As a workaround, avoid cloning repositories from untrusted sources. Git es un sistema de control de revisiones. • https://github.com/Wadewfsssss/CVE-2024-32004 https://github.com/10cks/CVE-2024-32004-POC http://www.openwall.com/lists/oss-security/2024/05/14/2 https://git-scm.com/docs/git-clone https://github.com/git/git/commit/f4aa8c8bb11dae6e769cd930565173808cbb69c8 https://github.com/git/git/security/advisories/GHSA-xfc6-vwr8-r389 https://lists.debian.org/debian-lts-announce/2024/06/msg00018.html https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/S4CK4IYTX • CWE-114: Process Control •
CVE-2024-32002 – Git's recursive clones on case-insensitive filesystems that support symlinks are susceptible to Remote Code Execution
https://notcve.org/view.php?id=CVE-2024-32002
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. • https://github.com/amalmurali47/git_rce https://github.com/amalmurali47/hook https://github.com/bonnettheo/CVE-2024-32002 https://github.com/WOOOOONG/CVE-2024-32002 https://github.com/WOOOOONG/hook https://github.com/markuta/hooky https://github.com/markuta/CVE-2024-32002 https://github.com/bfengj/CVE-2024-32002-Exploit https://github.com/bfengj/CVE-2024-32002-hook https://github.com/tiyeume25112004/CVE-2024-32002 https://github.com/charlesgargasson/CVE-2024-32002 https:& • CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') CWE-59: Improper Link Resolution Before File Access ('Link Following') CWE-434: Unrestricted Upload of File with Dangerous Type •