restrictedpython
Affected
- introduced
6.0, fixed8.0(ecosystem)
Fixed versions
8.0
Fix
- Fixed version
8.0pip install --upgrade restrictedpython==8.0
Advisory
Also known as: CVE-2025-22153, GHSA-gmj9-h825-chq2
try/except* clauses could allow bypass RestrictedPython via type confusion bug in the CPython interpreter
Impact
Via a type confusion bug in the CPython interpreter when using try/except* RestrictedPython could be bypassed.
We believe this should be fixed upstream in Python itself until that we remove support for try/except* from RestrictedPython.
(It has been fixed for some Python versions.)
Patches
Patched in version 8.0 by removing support for try/except* clauses
Workarounds
There is no workaround.
References
none
High Basis: CVSS v3 score 7.9, vector CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:C/C:H/I:H/A:L
6.0, fixed 8.0 (ecosystem)8.0
8.0pip install --upgrade restrictedpython==8.0Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.
Check your own computer: guard packages check
Source: PyPA Advisory Database · CC BY 4.0