CVE-2026-6100: Use-after-free in lzma.LZMADecompressor, bz2.BZ2Decompressor, and gzip.GzipFile after re-use under memory pressure
Use-after-free (UAF) was possible in the `lzma.LZMADecompressor`, `bz2.BZ2Decompressor`, and `gzip.GzipFile` when a memory allocation fails with a `MemoryError` and the decompression instance is re-used. This scenario can be triggered if the process is under memory pressure. The fix cleans up the dangling pointer in this specific error condition.
The vulnerability is only present if the program re-uses decompressor instances across multiple decompression calls even after a `MemoryError` is raised during decompression. Using the helper functions to one-shot decompress data such as `lzma.decompress()`, `bz2.decompress()`, `gzip.decompress()`, and `zlib.decompress()` are not affected as a new decompressor instance is used per call. If the decompressor instance is not re-used after an error condition, this usage is similarly not vulnerable.
Security readout for executives and security teams
Plain-English summary
CVE-2026-6100 is a CPython memory-safety flaw in decompression objects. A program is vulnerable only if it reuses the same lzma, bz2, or gzip decompressor after a MemoryError during decompression, typically under memory pressure. One-shot helper decompression functions are described as unaffected.
Executive priority
Prioritize assessment for exposed Python services handling compressed uploads, archives, logs, or messages. The rating is critical, but the vulnerable pattern is specific, so response should combine package updates with targeted code review rather than broad emergency assumptions.
Technical view
The flaw is a use-after-free in lzma.LZMADecompressor, bz2.BZ2Decompressor, and gzip.GzipFile after allocation failure leaves a dangling pointer. The fix clears that pointer in the specific MemoryError path. CVSS v4.0 is 9.1, but attack complexity and required memory-pressure conditions are material constraints.
Likely exposure
Exposure is narrow but important for Python services that process untrusted compressed data and reuse decompressor instances across calls after errors. Applications using lzma.decompress, bz2.decompress, gzip.decompress, or zlib.decompress per call are described as unaffected.
Exploitation context
The provided sources do not report active exploitation, and KEV status is false. Practical exploitation would require triggering memory pressure and reuse of an errored decompressor instance. Treat internet-facing decompression workflows as the highest validation priority.
Researcher notes
Evidence supports a specific CPython UAF after allocation failure, not broad decompression compromise. The affected product data lists CPython with default status unaffected and named versions including 3.14.0a1 and 3.15.0a1. Confirm exact downstream package impact through vendor advisories.
Mitigation direction
Update CPython or vendor packages using PSF and distribution advisories.
Avoid reusing decompressor instances after MemoryError or decompression failure.
Prefer one-shot helper decompression functions where streaming state is unnecessary.
Review Red Hat errata if running affected Red Hat packages.
Monitor PSF and vendor advisories for fixed version guidance.
Validation and detection
Inventory services using Python lzma, bz2, or gzip streaming decompressor objects.
Check whether code retries or reuses decompressor instances after MemoryError.
Identify endpoints or jobs accepting untrusted compressed input.
Confirm runtime Python versions and vendor package status against advisories.
Add regression tests for decompressor error cleanup behavior if applicable.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · low confidence lookup
CWE-416: Exact CWE lookup
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
2CVSS vectors
5Timeline events
3ADP providers
49Source links
SSVC decision data
CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: noneAutomatable: noTechnical Impact: total
CVSS vector scores
2 official scores
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-416 · source CWE mapping
Use After Free
Use After Free represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.
Out-of-bounds Write represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.
Expired Pointer Dereference represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.