CVE-2026-9669: Python CPython stack buffer overflow in bz2.BZ2Decompressor reuse

CVE-2026-9669 · Severity: info · CVSS 8.2 · Published 2026-06-08

A vulnerability exists in Python's bz2 compression library, which is used by many applications to handle compressed data. If an application encounters an error while decompressing a file and attempts to reuse the same decompressor object, it could lead to a system crash. This could allow an attacker to disrupt services or cause applications to fail by providing specially crafted compressed files.

Technologies: Python Software Foundation CPython. Vendors: Python Software Foundation.

Quick answers

Is CVE-2026-9669 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-9669 being exploited in the wild.
How severe is CVE-2026-9669?
Informational severity, with a CVSS score of 8.2, published 8 June 2026.
Which products and versions are affected?
Python Software Foundation CPython 3.12, 3.13, 3.14, 3.15 (main).
Is there a fix for CVE-2026-9669?
A patch was published on 2026-06-07: Fix merged into CPython main branch Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-9669 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-9669?
Check whether you run Python Software Foundation CPython at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

A stack-based buffer overflow (CWE-121) exists in the CPython bz2 module. The vulnerability occurs when a bz2.BZ2Decompressor object is reused after it has already raised an OSError during a previous decompression attempt. If an application catches the exception and retries decompression with the same object, crafted input can cause the underlying libbz2 state to become desynchronized, resulting in out-of-bounds writes to a stack buffer. This typically results in a hard crash of the Python interpreter. The issue has been addressed by preventing the reuse of decompressor objects once they have entered an error state.

Affected products

  • Python Software Foundation CPython 3.12, 3.13, 3.14, 3.15 (main)

Timeline

  • 2026-05-30: disclosed: Issue reported on GitHub
  • 2026-06-07: patched: Fix merged into CPython main branch
  • 2026-06-08: advisory: CVE published and NVD record created

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.