CVE-2026-105437: Heap Buffer Overflow in Git xdiff Three-Way Merging
- Vendor
- Git-Scm
CVE-2026-105437 is a heap-based buffer overflow in Git's xdiff textual three-way merge machinery. The xdl_fill_merge_buffer() sizing pass accumulates the required merge-output size in a 32-bit signed integer before allocating the output buffer. An attacker-controlled repository can combine an extremely large positive conflict-marker-size attribute with many separate merge conflicts, generating output exceeding 4 GiB from relatively small inputs. When the size wraps to a small positive value, Git allocates an undersized buffer and writes largely attacker-controlled output outside its bounds, corrupting the heap. Exposed commands include git merge, git rebase, git cherry-pick, and git merge-tree. Git hosting services performing automated mergeability checks are particularly exposed when they obtain attributes from untrusted repository trees.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Successful exploitation can crash Git and disrupt local merge operations or server-side mergeability processing. Out-of-bounds writes can occur both beyond the allocation and before its beginning. Because the overflow contents are largely attacker-controlled, more serious memory corruption and potentially code execution in the Git process are possible, including processes spawned by GitLab Gitaly. Reliable code execution is not established.
Mitigation
If you can’t patch tonight, do this now.
If upgrading is temporarily impossible, add '* conflict-marker-size=7' to each repository's $GIT_DIR/info/attributes to override attacker-controlled in-tree attributes. Alternatively, disable server-side mergeability checks for untrusted repositories. Avoid textual three-way merges of untrusted repository content until a fix or effective attribute override is deployed. These workarounds do not repair the underlying arithmetic flaw.
Remediation
Patch, then assume compromise.
Upgrade to Git 2.56.1 or a patched release for the installed maintenance line: 2.50.2, 2.51.3, 2.52.1, 2.53.1, 2.54.1, or 2.55.1. Vendor-maintained packages may contain backported fixes, so verify the distribution's security update rather than relying solely on the upstream version number. Update applications and automation services that bundle Git. For affected GitLab installations, install 19.3.8, 19.4.6, or 19.5.4, as appropriate for the release branch. The upstream fix uses size_t for merge-output calculations, checks sizing additions for overflow, and rejects results exceeding the representable output-size limit.
Exploits
1 exploit validated by Mallory's analysis. Hidden: 1 rejected by Mallory's analysis as not a working exploit.
Affected products & vendors
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
References
Frequently asked questions
- Is CVE-2026-105437 exploited in the wild?
- As of Nov 17, 2026, Mallory has no reports of CVE-2026-105437 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2026-105437?
- Yes. Mallory tracks 1 public exploit or proof of concept for CVE-2026-105437, the earliest disclosed Nov 11, 2026.
- Is there a patch for CVE-2026-105437?
- Upgrade to Git 2.56.1 or a patched release for the installed maintenance line: 2.50.2, 2.51.3, 2.52.1, 2.53.1, 2.54.1, or 2.55.1. Vendor-maintained packages may contain backported fixes, so verify the distribution's security update rather than relying solely on the upstream version number.
- What products are affected by CVE-2026-105437?
- Git-Scm Git.
- How severe is CVE-2026-105437?
- CVE-2026-105437 has a CVSS v3.1 score of 7.5 (High) and an EPSS score of 0.40% (35th percentile) as of Nov 17, 2026.
Recent activity
45 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.