CVE-2026-53585 libgit2: Unbounded Memory Allocation via Delta Object Result-Size Header
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- Proof of concept public · automatable: yes · technical impact: partial
- Technology
- UbuntuDebianRed Hat
Description
libgit2 is a portable C implementation of the Git core methods provided as a linkable library with a solid API, allowing to build Git functionality into your application. Prior to 1.8.6 and 1.9.5, git_delta_apply in src/libgit2/delta.c trusts the attacker-controlled res_sz value parsed by hdr_sz from a delta object header and passes that amount to git__malloc before validating delta instructions. Malicious pack data supplied through git_clone, git_fetch, git_remote_fetch, git_indexer_append, or a local attacker-supplied repository can use a very small multi-level OFS_DELTA chain to retain extremely large allocations and exhaust memory. This issue is fixed in versions 1.8.6 and 1.9.5.
Upgrade path
15 packages: 9 fixed, 5 with no fix yet.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| redhat/libgit2(Red Hat enterprise_linux 8) | All versions | No fix listed | No fix yet |
| redhat/libgit2(Red Hat enterprise_linux_ai 3) | All versions | No fix listed | No fix yet |
| redhat/rust(Red Hat enterprise_linux 10) | All versions | No fix listed | No fix yet |
| redhat/rust(Red Hat enterprise_linux 9) | All versions | No fix listed | No fix yet |
| redhat/rust(Red Hat enterprise_linux_ai 3) | All versions | No fix listed | No fix yet |
| alpine/libgit2(Alpine v3.23) | < 1.9.6-r0 | 1.9.6-r0 | Fixed |
| alpine/libgit2(Alpine v3.24) | < 1.9.6-r0 | 1.9.6-r0 | Fixed |
| debian/libgit2(Debian 12) | < 1.5.1+ds-1+deb12u2; = 1.5.1+ds-1; = 1.5.1+ds-1+deb12u1 | 1.5.1+ds-1+deb12u2 | Fixed |
| debian/libgit2(Debian 13) | < 1.9.0+ds-2+deb13u1; = 1.9.0+ds-2 | 1.9.0+ds-2+deb13u1 | Fixed |
| debian/libgit2(Debian 14) | < 1.9.6+ds-1; = 1.9.0+ds-2; = 1.9.1+ds-1; = 1.9.2+ds-1 +10 more | 1.9.6+ds-1 | Fixed |
| redhat/libgit2-main(Red Hat hummingbird 1) | < 1.9.7-1.hum1 | 1.9.7-1.hum1 | Fixed |
| ubuntu/libgit2(Ubuntu 22.04) | < 1.1.0+dfsg.1-4.1ubuntu0.1+esm1 | 1.1.0+dfsg.1-4.1ubuntu0.1+esm1 | Fixed |
| ubuntu/libgit2(Ubuntu 24.04) | < 1.7.2+ds-1ubuntu3.1 | 1.7.2+ds-1ubuntu3.1 | Fixed |
| ubuntu/libgit2(Ubuntu 26.04) | < 1.9.1+ds-1ubuntu1.1 | 1.9.1+ds-1ubuntu1.1 | Fixed |
| libgit2 | = < 1.8.6; = >= 1.9.0, < 1.9.5 | No fix listed | Versions listed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| libgit2 | = < 1.8.6 | No fix listed |
| libgit2 | = >= 1.9.0, < 1.9.5 | No fix listed |
| redhat/libgit2-main(Red Hat:hummingbird:1) | < 1.9.7-1.hum1 | 1.9.7-1.hum1 |
| redhat/rust(Red Hat:enterprise_linux:10) | All versions | No fix listed |
| redhat/libgit2(Red Hat:enterprise_linux:8) | All versions | No fix listed |
| redhat/rust(Red Hat:enterprise_linux:9) | All versions | No fix listed |
| redhat/libgit2(Red Hat:enterprise_linux_ai:3) | All versions | No fix listed |
| redhat/rust(Red Hat:enterprise_linux_ai:3) | All versions | No fix listed |
| debian/libgit2(Debian:12) | < 1.5.1+ds-1+deb12u2 | 1.5.1+ds-1+deb12u2 |
| debian/libgit2(Debian:12) | = 1.5.1+ds-1 | No fix listed |
| debian/libgit2(Debian:12) | = 1.5.1+ds-1+deb12u1 | No fix listed |
| debian/libgit2(Debian:13) | < 1.9.0+ds-2+deb13u1 | 1.9.0+ds-2+deb13u1 |
| debian/libgit2(Debian:13) | = 1.9.0+ds-2 | No fix listed |
| debian/libgit2(Debian:14) | < 1.9.6+ds-1 | 1.9.6+ds-1 |
| debian/libgit2(Debian:14) | = 1.9.0+ds-2 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.1+ds-1 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-1 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-2 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-3 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-4 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-5 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-6 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-7 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-8 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.2+ds-9 | No fix listed |
Show 7 more
| Product | Affected versions | Fixed in |
|---|---|---|
| debian/libgit2(Debian:14) | = 1.9.3+ds-1 | No fix listed |
| debian/libgit2(Debian:14) | = 1.9.4+ds-1 | No fix listed |
| ubuntu/libgit2(Ubuntu:22.04) | < 1.1.0+dfsg.1-4.1ubuntu0.1+esm1 | 1.1.0+dfsg.1-4.1ubuntu0.1+esm1 |
| alpine/libgit2(Alpine:v3.23) | < 1.9.6-r0 | 1.9.6-r0 |
| alpine/libgit2(Alpine:v3.24) | < 1.9.6-r0 | 1.9.6-r0 |
| ubuntu/libgit2(Ubuntu:24.04) | < 1.7.2+ds-1ubuntu3.1 | 1.7.2+ds-1ubuntu3.1 |
| ubuntu/libgit2(Ubuntu:26.04) | < 1.9.1+ds-1ubuntu1.1 | 1.9.1+ds-1ubuntu1.1 |
References
- https://github.com/libgit2/libgit2/security/advisories/GHSA-27m5-gxxh-x79j exploit
- https://github.com/libgit2/libgit2/commit/0cdfdd5fa8f8514c82413025e1e0808866cf7c30
- https://github.com/libgit2/libgit2/commit/c1896f06df22cc0ca5658df3a8f6cd7ede4cd6ae
- https://github.com/libgit2/libgit2/commit/dec22ac01ad9620c96b7b9ac3ef636ea46d43bed
- https://github.com/libgit2/libgit2/releases/tag/v1.8.6
- https://github.com/libgit2/libgit2/releases/tag/v1.9.5
- Red Hat CVE page mitigation vendor-advisory
- RHSA-2026:59361 patch vendor-advisory
- Red Hat Bugzilla 2520696 issue-tracking
- www.cve.org
- nvd.nist.gov
- Debian Security Tracker CVE-2026-53585 vendor-advisory
- Ubuntu CVE tracker vendor-advisory
- USN-8628-1 vendor-advisory
- security.alpinelinux.org vendor-advisory
- ENISA EUVD EUVD-2026-63548 third-party-advisory