Python2.7: Use-after-free (UAF) was possible in the lzma.LZMADecompressor, bz2.BZ2Decompressor, and gzip.GzipFile when a memory allocation fails with a… (CVE-2026-6100)
A use-after-free vulnerability exists in Python's decompression modules lzma.LZMADecompressor, bz2.BZ2Decompressor, and gzip.GzipFile when a MemoryError occurs during decompression and the decompressor instance is reused. This flaw can lead to arbitrary code execution or information disclosure. The vulnerability only affects scenarios where decompressor instances are reused after a MemoryError; one-shot decompression helper functions are not affected. A patch is available to address this issue.
AI Analysis
Technical Summary
CVE-2026-6100 describes a use-after-free vulnerability in Python's decompression modules (lzma.LZMADecompressor, bz2.BZ2Decompressor, gzip.GzipFile) triggered when a memory allocation fails with a MemoryError and the decompression instance is reused across multiple decompression calls. The vulnerability arises from a dangling pointer not being cleaned up in this error condition. Helper functions that create new decompressor instances per call are not vulnerable. The issue is fixed by cleaning up the dangling pointer when a MemoryError occurs during decompression.
Potential Impact
Successful exploitation can lead to arbitrary code execution or information disclosure due to use-after-free conditions in decompression modules. The vulnerability requires reuse of decompressor instances after a MemoryError, which limits exposure. The CVSS v3.1 base score is 8.1 (high severity), reflecting network attack vector, high impact on confidentiality, integrity, and availability, and requiring high attack complexity.
Mitigation Recommendations
A patch is available and should be applied to affected Python versions. The vendor advisory from Red Hat confirms the availability of an official fix. Users should update to patched versions to remediate this vulnerability. Avoid reusing decompressor instances after a MemoryError as a temporary mitigation. Using one-shot decompression helper functions is not vulnerable.
Python2.7: Use-after-free (UAF) was possible in the lzma.LZMADecompressor, bz2.BZ2Decompressor, and gzip.GzipFile when a memory allocation fails with a… (CVE-2026-6100)
Description
A use-after-free vulnerability exists in Python's decompression modules lzma.LZMADecompressor, bz2.BZ2Decompressor, and gzip.GzipFile when a MemoryError occurs during decompression and the decompressor instance is reused. This flaw can lead to arbitrary code execution or information disclosure. The vulnerability only affects scenarios where decompressor instances are reused after a MemoryError; one-shot decompression helper functions are not affected. A patch is available to address this issue.
CVSS v3.1
Score 8.1high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
CVE-2026-6100 describes a use-after-free vulnerability in Python's decompression modules (lzma.LZMADecompressor, bz2.BZ2Decompressor, gzip.GzipFile) triggered when a memory allocation fails with a MemoryError and the decompression instance is reused across multiple decompression calls. The vulnerability arises from a dangling pointer not being cleaned up in this error condition. Helper functions that create new decompressor instances per call are not vulnerable. The issue is fixed by cleaning up the dangling pointer when a MemoryError occurs during decompression.
Potential Impact
Successful exploitation can lead to arbitrary code execution or information disclosure due to use-after-free conditions in decompression modules. The vulnerability requires reuse of decompressor instances after a MemoryError, which limits exposure. The CVSS v3.1 base score is 8.1 (high severity), reflecting network attack vector, high impact on confidentiality, integrity, and availability, and requiring high attack complexity.
Mitigation Recommendations
A patch is available and should be applied to affected Python versions. The vendor advisory from Red Hat confirms the availability of an official fix. Users should update to patched versions to remediate this vulnerability. Avoid reusing decompressor instances after a MemoryError as a temporary mitigation. Using one-shot decompression helper functions is not vulnerable.
Technical Details
- Gcve Source
- db.gcve.eu
- Csaf Category
- csaf_security_advisory
- Csaf Version
- 2.0
- Publisher
- Red Hat Product Security
- Advisory Id
- RHSA-2026:52400
- Cve Count
- 1
- State
- PUBLISHED
Threat ID: 6a79f0efbf8831d539f63c11
Added to database: 08/10/2026, 15:40:31 UTC
Last enriched: 09/13/2026, 14:49:50 UTC
Last updated: 09/24/2026, 13:47:47 UTC
Views: 75
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.