CVE-2026-105437Git heap-based buffer overflow
CVE-2026-105437 is a heap-based buffer overflow in Git, rated high (7.5 on CVSS 3.1).
Why this priority: High severity, with no exploitation signal yet.
Published · Updated · NVD status: Received
What it is
A buffer on the heap overflows and corrupts neighbouring data structures.
How it is reached
An attacker can exploit it over the network, without an account, but someone has to act first, such as opening a file or following a link. Success also depends on conditions the attacker does not fully control.
What an attacker gains
A successful attack can read the data it protects, change data or behaviour and take it offline. In practice, this kind of flaw lets an attacker crash the process, read memory, or in the worst case run code.
Is it being exploited?
There is no public report of exploitation yet.
What to do
- Upgrade Git to a fixed version for your release line (2.49.1, 2.50.2, 2.51.3).
- Until it is patched, keep it off the internet or behind a VPN, allowlist or authenticating proxy.
- Warn the people who use it, and filter files and links on the way in.
Description from NVD
Affected versions of Git have a heap buffer overflow in the three-way merge code (xdiff), which an attacker can trigger through a repository they control.
When Git merges a file, it first adds up the size of the merged output, allocates a buffer of that size, and then writes the output into it. That total was kept in a 32-bit signed integer. The conflict-marker-size attribute, which can be set from a committed .gitattributes file, accepts any positive integer, and the markers are written several times for every conflict. A small file with a huge marker size and many separate conflicts can therefore push the total past 4 GiB, so the integer wraps to a small value and Git writes attacker-controlled merge output past the end of a buffer that is too small. At minimum this crashes Git, and because the overflow is large and its contents are largely attacker-controlled, worse heap corruption is possible.
Any command that does a textual three-way merge can trigger it, such as git-merge(1), git-rebase(1), git-cherry-pick(1), and git-merge-tree(1). The latter is most likely a target for Git forges, which might use git-merge-tree(1) on the server-side to check mergeability. When the server reads attributes from trees in the repository (for example through attr.tree or --attr-source), any user who can push branches and request that they be merged (for example by opening a pull or merge request) can trigger the overflow without anyone else doing anything, and the data they push is small because the oversized output only appears during the merge.
The problem has been patched by computing the size as size_t and checking every addition for overflow, so Git stops with an error instead of overflowing.
Servers that cannot upgrade right away can add
* conflict-marker-size=7
to each repository's info/attributes as a workaround, which overrides any in-tree .gitattributes, or turn off server-side mergeability checks for untrusted repositories.
What this means for your architecture.
A CVE names a product. Whether it matters depends on where that product sits in your systems: what reaches it, which trust boundary it guards and what it can reach once compromised. Veriom maps your components, their relationships and your trust boundaries from your code, cloud and delivery evidence, so you can see where a component like this sits. The radar itself does not look at your systems.
Components it touches
- Native code: operating systems, browsers and firmware. The flaw sits wherever native code reads untrusted data.
- Network appliances and media or file parsers. The flaw sits wherever native code reads untrusted data.
Trust boundaries in play
- Internet-facing entry points. No account is needed. Any instance reachable from outside your perimeter, through a load balancer, gateway, VPN or exposed admin port, is in scope.
- People who open files and links. Mail, chat and browsers are the delivery path.
- Wherever native code reads untrusted data. An attacker who crosses it can crash the process, read memory, or in the worst case run code.
Questions to answer about your own systems
- Where does Git run in your systems, and at which version?
- Which of those instances can be reached from the internet or partner networks?
- What can it reach once compromised: which data stores, secrets and services?
Sources
- CVE records and CVSS scores from the NVD CVE API. This product uses the NVD API but is not endorsed or certified by the NVD.
- Exploitation status from CISA’s Known Exploited Vulnerabilities catalog.
- Exploit likelihood from FIRST’s Exploit Prediction Scoring System (EPSS), refreshed daily.
- Explanations are written by Veriom from fixed templates over each record’s data, not by a person reviewing each CVE. Descriptions are quoted from the records as published.