CVE-2026-85091
HIGH 8.3CVSS 4.0libz-sys: heap buffer overflow
zlib 1.2.11 through 1.3.2 contains a heap buffer overflow: after an underlying write() fails, gz_write() returns without resetting strm.next_in, leaving it pointed at the caller's buffer. A later gz* write call then derives a position from the stale pointer and writes past a heap allocation; any write() failure reaches it, including EPIPE on a blocking descriptor, and in versions before 1.3.1.2 the failed write must be followed by a gzclearerr() call.
- Published
- 3 Sep 2026
- Last modified
- 3 Dec 2026
- Assigned by
- disclosure@vulncheck.com
- NVD status
- Awaiting Analysis
- Weakness
- CWE-787
- Also known as
- RUSTSEC-2026-0544
- Sources
- NVDJSONOSV RUSTSEC-2026-0544JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | disclosure@vulncheck.com (Secondary) | CVSS 4.0 | HIGH 8.3 | CVSS:4.0/AV:N/AC:H/AT:N/PR:N/UI:N/VC:N/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X |
| NVD | disclosure@vulncheck.com (Secondary) | CVSS 3.1 | HIGH 7.4 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:H |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| OSV | crates.io | libz-sys | >= 1.1.25, < 1.1.33 | 1.1.33 |
References
- https://gist.github.com/thesmartshadow/e0b9481792afb7c31e86fee1ff084490
- https://github.com/madler/zlib
- https://github.com/madler/zlib/blob/v1.3.2/gzwrite.c#L393
- https://github.com/madler/zlib/commit/df84af25dc1942490e1d1c899a07619152a46148 · WEB
- https://www.vulncheck.com/advisories/zlib-1.3.1.2-through-1.3.2-heap-buffer-overflow-via-gz-vacate
- https://crates.io/crates/libz-sys · PACKAGE
- https://rustsec.org/advisories/RUSTSEC-2026-0544.html · ADVISORY
- https://github.com/madler/zlib/issues/1310 · REPORT
- https://github.com/rust-lang/libz-sys/commit/b161d77050c00c6eeb7dd4b66ea14d4524d73dc4 · WEB
- https://github.com/rust-lang/libz-sys/commit/8827cadbe2b560233909212527c291827fb34512 · WEB
History
- 3 Dec 2026 11:07 UTC · OSV: updated (other details)
- 25 Nov 2026 21:05 UTC · NVD: first stored (published 3 Sep 2026)
- 25 Nov 2026 20:14 UTC · OSV: first stored (published 11 Nov 2026)