CVE-2026-76825 json
RestrictedPython: Sandbox escape via string.Formatter field resolution
published 3mo ago modified last mo. also EUVD-2026-80780 , GHSA-hp3v-5vw7-fx9w , PYSEC-2026-4161
- cvss
- 8.4
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.6%
- EPSS 0.6% chance of exploitation in 30 days, percentile 50%
- public exploits
- 0
- none known
Summary
RestrictedPython is a tool that helps define a subset of the Python language for accepting program input in a trusted environment. Prior to 8.4, RestrictedPython could allow a sandbox escape when a custom import policy or globals exposed the standard library string module, the string.Formatter class, a Formatter instance, or a Formatter subclass to restricted code. The string.Formatter methods format, get_field, get_value, and vformat performed attribute and item traversal internally without passing through RestrictedPython's safer_getattr protections. Restricted code could use those live object references to reach function globals, builtins, file access, or code execution primitives, affecting confidentiality, integrity, and availability in the host environment. This issue is fixed in version 8.4.
Patch / fix
- pypi restrictedpython 8.4
- zope restrictedpython 8.4
- restrictedpython Debian 14 8.4-1
debian advisories DEBIAN-CVE-2026-76825
Is CVE-2026-76825 in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.
Check with FencerCISA SSVC
- Exploitation
- none
- Automatable
- no
- Technical impact
- total
- Assessed
- last mo.
Exploit prediction
0.62% chance of exploitation in the next 30 days, higher than 50% of all scored CVEs (FIRST EPSS, 2026-11-11).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 8.4 | CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:H/A:H |
| GitHub | 3.1 | 8.4 | CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:H/A:H |
| OSV | 3.1 | 8.4 | CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:H/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| pypi | restrictedpython | <8.4 |
8.4 |
Affected products
- zopefoundation RestrictedPython
Classification
References
-
github.com
/zopefoundation/RestrictedPython/commit/3b47440070b91f8807c2b2998aca99e94783639a
web
-
github.com
/zopefoundation/RestrictedPython/security/advisories/GHSA-hp3v-5vw7-fx9w
web, advisory
-
github.com
/zopefoundation/RestrictedPython/releases/tag/8.4
web
-
nvd.nist.gov
/vuln/detail/CVE-2026-76825
advisory
-
github.com
/zopefoundation/RestrictedPython
package
-
pypi.org
/project/restrictedpython
package
-
github.com
/advisories/GHSA-hp3v-5vw7-fx9w
advisory
Sources
- CVE List CVE-2026-76825
- GitHub Advisory GHSA-hp3v-5vw7-fx9w
- NVD CVE-2026-76825
- OSV PYSEC-2026-4161
- Maintainer advisory GHSA-hp3v-5vw7-fx9w
Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.
The maintainers of zopefoundation/RestrictedPython published their own advisory on GitHub. Reviewed sources take precedence over it.
CPEs and fixed versions use Anchore's correction of NVD's data: Added CPE configurations because not yet analyzed by NVD.