CVE-2026-2297

The import hook in CPython that handles legacy *.pyc files (SourcelessFileLoader) is incorrectly handled in FileLoader (a base class) and so does not use io.open_code() to read the .pyc files. sys.audit handlers for this audit event therefore do not fire.
Configurations

Configuration 1 (hide)

OR cpe:2.3:a:python:python:*:*:*:*:*:*:*:*
cpe:2.3:a:python:python:*:*:*:*:*:*:*:*
cpe:2.3:a:python:python:*:*:*:*:*:*:*:*
cpe:2.3:a:python:python:*:*:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha1:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha2:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha3:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha4:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha5:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha6:*:*:*:*:*:*

History

24 Nov 2026, 18:18

Type Values Removed Values Added
References () https://github.com/python/cpython/commit/482d6f8bdba9da3725d272e8bb4a2d25fb6a603e - () https://github.com/python/cpython/commit/482d6f8bdba9da3725d272e8bb4a2d25fb6a603e - Patch
References () https://github.com/python/cpython/commit/69ddd9bb2cc4bd69b1565647c18659c6a789ccd9 - () https://github.com/python/cpython/commit/69ddd9bb2cc4bd69b1565647c18659c6a789ccd9 - Patch
References () https://github.com/python/cpython/commit/876858c9f65d9ab656c7fa639f268ce7856d89dd - () https://github.com/python/cpython/commit/876858c9f65d9ab656c7fa639f268ce7856d89dd - Patch
References () https://github.com/python/cpython/commit/a51b1b512de1d56b3714b65628a2eae2b07e535e - () https://github.com/python/cpython/commit/a51b1b512de1d56b3714b65628a2eae2b07e535e - Patch
References () https://github.com/python/cpython/commit/c70adad78caeeea33f92f560ecb93331ca11bf66 - () https://github.com/python/cpython/commit/c70adad78caeeea33f92f560ecb93331ca11bf66 - Patch
References () https://github.com/python/cpython/commit/e58e9802b9bec5cdbf48fc9bf1da5f4fda482e86 - () https://github.com/python/cpython/commit/e58e9802b9bec5cdbf48fc9bf1da5f4fda482e86 - Patch
References () https://github.com/python/cpython/issues/145506 - () https://github.com/python/cpython/issues/145506 - Issue Tracking, Vendor Advisory
References () https://github.com/python/cpython/pull/145507 - () https://github.com/python/cpython/pull/145507 - Issue Tracking, Patch, Vendor Advisory
References () http://www.openwall.com/lists/oss-security/2026/03/05/6 - () http://www.openwall.com/lists/oss-security/2026/03/05/6 - Mailing List, Third Party Advisory
First Time Python python
Python
CPE cpe:2.3:a:python:python:3.15.0:alpha2:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha6:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha4:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha1:*:*:*:*:*:*
cpe:2.3:a:python:python:*:*:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha3:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha5:*:*:*:*:*:*
CVSS v2 : unknown
v3 : unknown
v2 : unknown
v3 : 5.5

05 Aug 2026, 01:16

Type Values Removed Values Added
References
  • () https://github.com/python/cpython/commit/c70adad78caeeea33f92f560ecb93331ca11bf66 -

01 May 2026, 16:16

Type Values Removed Values Added
References
  • () https://github.com/python/cpython/commit/69ddd9bb2cc4bd69b1565647c18659c6a789ccd9 -
  • () https://github.com/python/cpython/commit/876858c9f65d9ab656c7fa639f268ce7856d89dd -

12 Mar 2026, 15:16

Type Values Removed Values Added
CWE CWE-668
Summary
  • (es) El gancho de importación en CPython que maneja los archivos *.pyc heredados (SourcelessFileLoader) es manejado incorrectamente en FileLoader (una clase base) y por lo tanto no usa io.open_code() para leer los archivos .pyc. Los manejadores de sys.audit para este evento de auditoría, por lo tanto, no se disparan.

05 Mar 2026, 19:16

Type Values Removed Values Added
References
  • () http://www.openwall.com/lists/oss-security/2026/03/05/6 -

04 Mar 2026, 23:16

Type Values Removed Values Added
New CVE

Information

Published : 2026-03-04 23:16

Updated : 2026-11-24 18:18


NVD link : CVE-2026-2297

Mitre link : CVE-2026-2297

CVE.ORG link : CVE-2026-2297


JSON object : View

Products Affected

python

  • python
CWE
CWE-668

Exposure of Resource to Wrong Sphere