Dev News Daily ENDE

Git 2.56.1 fixes six flaws, including code execution on recursive clone of a hostile repo

The Git project released new versions on 10 November to fix six security vulnerabilities, described on the GitHub blog by Elijah Newren. The fixes are in Git 2.56.1 and are backported to 2.55.1, 2.54.1, 2.53.1, 2.52.1, 2.51.3 and 2.50.2.

The most serious, CVE-2026-111760, is a code-execution bug during recursive clones. Git checks paths before it writes files into a working tree and refuses paths that would overwrite its own metadata. An integer truncation in the index code means a very long path can pass that check under one name and then be written under a shorter one. An attacker can use the gap to replace a submodule's .git file with a symbolic link to a directory holding malicious configuration or hooks, which Git then uses. The fix rejects such long index paths before their length can be truncated.

A second bug, CVE-2026-113408, involves cloning an empty repository over protocol v2. A server can advertise HEAD as a symbolic reference to a branch with no commits yet, and Git stored that target without checking it, so a name with path-traversal parts could later lead to a write outside the references directory. Git now validates the target, and other reference names received over protocol v2.

The other four are memory and file-access issues. A message with more than two GPG signatures overflowed a fixed stack array when signatures were stripped, for example when merging such a tag. A small compressed binary patch could expand past the roughly 1 GiB limit Git enforces on patches and cause an out-of-bounds read. A size calculation in the merge code could overflow on very large results, including many conflicts combined with a large conflict-marker-size, leading to heap corruption. And three fast-import features, rewrite-submodules-from, rewrite-submodules-to and export-pack-edges, now need --allow-unsafe-features when they arrive in an untrusted stream.

GitHub says github.com and Enterprise Cloud are patched, Enterprise Server fixes are in 3.19.15, 3.20.11, 3.21.9 and 3.22.4, and Desktop, Codespaces and Actions will get patched Git.

Git 2.56.1 fixes six flaws, including code execution on recursive clone of a hostile repo
Git 2.56.1 fixes six flaws, including code execution on recursive clone of a hostile repo — Dev News Daily

Why it matters

Several of these bugs are reachable by services that merge or clone untrusted content for users, not only by developers at a terminal. The advisory's own list of who must update includes applications that bundle their own Git and automation that processes repositories on others' behalf.