Machine-written summary
Summary written by Claude Haiku from the source advisory. Not reviewed by a person.
RestrictedPython versions before 5.3, and from 6.0a1.dev0 up to but not including 6.1, do not check access to stack frames and their attributes. An attacker who can write code in a RestrictedPython environment can use a generator to walk the stack beyond the sandbox boundary and run unrestricted Python code. Upgrade to restrictedpython 5.3 or 6.1. The source lists no workaround other than limiting the environment to trusted users.
Not analysed yet
We haven’t published our analysis of this Advisory yet. Once a person has reviewed it, this page will say what’s vulnerable, what has to be true for your app to be affected, and how to check.
Severity and exploitation
| Score | Rating | CVSS | Vector | Source |
|---|---|---|---|---|
| 8.4 | High | 3.1 | CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:L | CNA (GitHub_M) |
- CISA KEV Not listed.
- EPSS 0.0085, the 58th percentile, on 5 Nov 2026: FIRST’s estimate of the chance of exploitation in the next 30 days.
Timeline
- 31 Oct 2026, 14:36 UTC First seen by agentprime
- 31 Oct 2026, 14:36 UTC Confirmed by OSV
Sources
- GitHub Advisory Database: GHSA-wqc8-x2pr-7jqh
- OSV: GHSA-wqc8-x2pr-7jqh
- github.com/zopefoundation/RestrictedPython/security/advisories/GHSA-wqc8-x2pr-7jqh
- nvd.nist.gov/vuln/detail/CVE-2023-37271
- github.com/zopefoundation/RestrictedPython/commit/c8eca66ae49081f0016d2e1f094c3d72095ef531
- github.com/pypa/advisory-database/tree/main/vulns/restrictedpython/PYSEC-2023-118.yaml
- github.com/zopefoundation/RestrictedPython