{"id":"CVE-2026-2297","aliases":["CVE-2026-2297","PSF-2026-9","BIT-LIBPYTHON-2026-2297","BIT-PYTHON-2026-2297","BIT-PYTHON-MIN-2026-2297"],"related":[],"kind":"vulnerability","state":"published","title":"SourcelessFileLoader does not use io.open_code()","summary":"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.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"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.","source":"cvelist"},{"lang":"es","text":"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.","source":"nvd"}],"published":"2026-03-04T22:10:43.297Z","modified":"2026-11-24T18:18:21.813Z","severity":{"scorer":"PSF","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N","score":5.7,"rating":"MEDIUM"},"severities":[{"scorer":"PSF","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N","score":5.7,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N","score":5.5,"rating":"MEDIUM"},{"scorer":"Bitnami Vulnerability Database","scheme":"rating","rating":"MEDIUM"}],"cwes":["CWE-668"],"affected":[{"ranges":[{"type":"python","introduced":"0","fixed":"3.10.21","status":"affected"},{"type":"python","introduced":"3.11.0","fixed":"3.11.16","status":"affected"},{"type":"python","introduced":"3.12.0","fixed":"3.12.14","status":"affected"},{"type":"python","introduced":"3.13.0","fixed":"3.13.13","status":"affected"},{"type":"python","introduced":"3.14.0","fixed":"3.14.4","status":"affected"},{"type":"python","introduced":"3.15.0a1","fixed":"3.15.0a7","status":"affected"}],"vendor":"Python Software Foundation","product":"CPython","repo":"https://github.com/python/cpython","source":"cvelist"},{"ranges":[{"type":"git","introduced":"0","status":"affected","fixed":"482d6f8bdba9da3725d272e8bb4a2d25fb6a603e"},{"type":"git","status":"affected","fixed":"a51b1b512de1d56b3714b65628a2eae2b07e535e"},{"type":"git","status":"affected","fixed":"e58e9802b9bec5cdbf48fc9bf1da5f4fda482e86"},{"type":"git","status":"affected","fixed":"69ddd9bb2cc4bd69b1565647c18659c6a789ccd9"},{"type":"git","status":"affected","fixed":"876858c9f65d9ab656c7fa639f268ce7856d89dd"},{"type":"git","status":"affected","fixed":"c70adad78caeeea33f92f560ecb93331ca11bf66"}],"repo":"https://github.com/python/cpython","source":"psf"},{"ranges":[{"status":"affected","fixed":"3.10.21"},{"status":"affected","introduced":"3.11.0","fixed":"3.11.16"},{"status":"affected","introduced":"3.13.0","fixed":"3.13.13"},{"status":"affected","introduced":"3.14.0","fixed":"3.14.4"},{"status":"affected","version":"3.15.0"},{"status":"affected","version":"3.15.0"},{"status":"affected","version":"3.15.0"},{"status":"affected","version":"3.15.0"},{"status":"affected","version":"3.15.0"},{"status":"affected","version":"3.15.0"}],"vendor":"python","product":"python","cpe":"cpe:2.3:a:python:python:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"3.15.0"}],"ecosystem":"Bitnami","package":"libpython","purl":"pkg:bitnami/libpython","source":"bitnami"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"3.15.0"}],"ecosystem":"Bitnami","package":"python","purl":"pkg:bitnami/python","source":"bitnami"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"3.15.0"}],"ecosystem":"Bitnami","package":"python-min","purl":"pkg:bitnami/python-min","source":"bitnami"}],"references":[{"url":"https://github.com/python/cpython/issues/145506","tags":["issue-tracking","report","vendor-advisory","web"],"sources":["cvelist","psf","nvd","bitnami"]},{"url":"https://github.com/python/cpython/pull/145507","tags":["issue-tracking","patch","vendor-advisory","web"],"sources":["cvelist","psf","nvd","bitnami"]},{"url":"https://github.com/python/cpython/commit/482d6f8bdba9da3725d272e8bb4a2d25fb6a603e","tags":["fix","patch","web"],"sources":["cvelist","psf","nvd","bitnami"]},{"url":"https://github.com/python/cpython/commit/a51b1b512de1d56b3714b65628a2eae2b07e535e","tags":["fix","patch","web"],"sources":["cvelist","psf","nvd","bitnami"]},{"url":"https://github.com/python/cpython/commit/e58e9802b9bec5cdbf48fc9bf1da5f4fda482e86","tags":["fix","patch","web"],"sources":["cvelist","psf","nvd","bitnami"]},{"url":"https://github.com/python/cpython/commit/69ddd9bb2cc4bd69b1565647c18659c6a789ccd9","tags":["fix","patch"],"sources":["cvelist","psf","nvd"]},{"url":"https://github.com/python/cpython/commit/876858c9f65d9ab656c7fa639f268ce7856d89dd","tags":["fix","patch"],"sources":["cvelist","psf","nvd"]},{"url":"https://github.com/python/cpython/commit/c70adad78caeeea33f92f560ecb93331ca11bf66","tags":["fix","patch"],"sources":["cvelist","psf","nvd"]},{"url":"http://www.openwall.com/lists/oss-security/2026/03/05/6","tags":["mailing-list","third-party-advisory","web"],"sources":["cvelist","nvd","bitnami"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-2297","tags":["web"],"sources":["bitnami"]}],"credits":[],"assigner":"PSF","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-03-12T14:58:41.472Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-2297","url":"https://www.cve.org/CVERecord?id=CVE-2026-2297","licence":"CVE Terms of Use","modified":"2026-08-13T00:28:17.928Z"},{"source":"psf","name":"Python Software Foundation","id":"PSF-2026-9","url":"https://osv.dev/vulnerability/PSF-2026-9","licence":"CC-BY-4.0","modified":"2026-08-05T14:17:02.366Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-2297","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-2297","licence":"Public domain","modified":"2026-11-24T18:18:21.813Z"},{"source":"bitnami","name":"Bitnami Vulnerability Database","id":"BIT-LIBPYTHON-2026-2297","url":"https://osv.dev/vulnerability/BIT-LIBPYTHON-2026-2297","licence":"Apache-2.0","modified":"2026-03-27T08:56:26.348Z"},{"source":"bitnami","name":"Bitnami Vulnerability Database","id":"BIT-PYTHON-2026-2297","url":"https://osv.dev/vulnerability/BIT-PYTHON-2026-2297","licence":"Apache-2.0","modified":"2026-03-27T08:48:14.762Z"},{"source":"bitnami","name":"Bitnami Vulnerability Database","id":"BIT-PYTHON-MIN-2026-2297","url":"https://osv.dev/vulnerability/BIT-PYTHON-MIN-2026-2297","licence":"Apache-2.0","modified":"2026-03-27T08:48:10.215Z"}],"updatedAt":"2026-11-25T22:59:15.234Z","epss":{"score":0.00213,"percentile":0.12379,"date":"2026-12-02T12:00:21.000Z"}}