| CVE ID | CVE-2026-41991 |
| Publication date | 29 June 2026 |
| Vendor | GNU |
| Product | gzip |
| Vulnerable versions | All through 1.14 |
| Vulnerability type (CWE) | Insecure Temporary File (CWE-377) |
| Report source | Report to CERT Polska |
| CVE ID | CVE-2026-41992 |
| Publication date | 29 June 2026 |
| Vendor | GNU |
| Product | gzip |
| Vulnerable versions | All through 1.14 |
| Vulnerability type (CWE) | Buffer Over-read (CWE-126) |
| Report source | Report to CERT Polska |
Description
CERT Polska has received a report about vulnerabilities in GNU gzip software and participated in coordination of their disclosure.
The vulnerability CVE-2026-41991: GNU gzip contains a vulnerability in the gzexe utility related to insecure temporary file handling. When the mktemp utility is not available in the user’s PATH, gzexe falls back to constructing a temporary file path based solely on the process ID (PID). This predictable filename is created without exclusive access or existence checks.
A local attacker can pre‑create the predicted temporary file path as a symbolic link pointing to an arbitrary file writable by the victim. When gzexe runs, it follows the symlink and overwrites the target file, resulting in a time‑of‑check to time‑of‑use (TOCTOU) condition that allows arbitrary file overwrite.
This issue has been fixed in the commit 4e6f8b24ab823146ab8776f0b7fe486ab34d4269
The vulnerability CVE-2026-41992: GNU gzip contains a global buffer overflow vulnerability in the LZH decompression logic caused by improper reuse of shared global state between different decompression formats within a single execution. GNU gzip maintains a global array that is shared across the LZ77, LZW, and LZH decompression routines and is not reinitialized between files processed in the same invocation.
By decompressing a specially crafted LZW file followed by a specially crafted LZH file in a single gzip -d command, an attacker can poison the shared global state and subsequently trigger an out‑of‑bounds read in the LZH decoder. The LZH decompression logic follows stale values left in the shared array, causing reads past the end of the allocated global buffer.
This issue has been fixed in the commit 63dbf6b3b9e6e781df1a6a64e609b10e23969681
Credits
We thank Michal Majchrowicz and Marcin Wyczechowski (AFINE) for the responsible vulnerability report.
More about the coordinated vulnerability disclosure process at CERT Polska can be found at https://cert.pl/en/cvd/.