# CVE-2026-55830: Zope RestrictedPython access policy bypass via positional-only arguments

Source: https://junglewise.ai/threats/cve-2026-55830-zope-restrictedpython-access-policy-bypass-via-positional-only  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-07-08. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

CVE-2026-55830 · Severity: high · CVSS 8.3 · Published 2026-07-08

RestrictedPython is a Python sandbox library used to restrict untrusted code execution by enforcing access policies through guard hooks. This vulnerability allows attackers to bypass these security guards by shadowing protected hook names using positional-only function parameters. An attacker can then intercept sensitive operations like attribute access and item access, or even capture internal hooks—potentially leading to unauthorized data access, modification, or remote code execution depending on how the host application handles the compromised objects.

Technologies: [restrictedpython (PyPI)](https://junglewise.ai/threats/technologies/pypi-restrictedpython). Vendors: [PyPI](https://junglewise.ai/threats/vendors/pypi).

## Quick answers

**Is CVE-2026-55830 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-55830 being exploited in the wild.

**How severe is CVE-2026-55830?** High severity, with a CVSS score of 8.3, published 8 July 2026.

**Which products and versions are affected?** restrictedpython (PyPI) ECOSYSTEM:introduced=0,fixed=8.3; Zope Foundation RestrictedPython < 8.3, 8.2 and earlier.

**Is there a fix for CVE-2026-55830?** Yes. restrictedpython (PyPI): upgrade to 8.3 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-55830 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-55830?** Check whether you run restrictedpython (PyPI) or Zope Foundation RestrictedPython at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- restrictedpython (PyPI): upgrade to 8.3 or later

  ```sh
  pip install "restrictedpython>=8.3"
  ```


## Technical details

RestrictedPython rewrites sensitive operations to route through guard hooks supplied by the embedding application: attribute access becomes `_getattr_(obj, name)`, item access becomes `_getitem_(obj, key)`, assignments through `_write_`, and printing through `_print_`. The vulnerability is a CWE-184 (Incomplete List of Disallowed Inputs): the `compile_restricted` function validates protected names in regular arguments, `*args`, `**kwargs`, and keyword-only arguments, but overlooks positional-only parameters (those before the `/` separator in Python function signatures). By defining a function like `def f(_getattr_=evil, /)`, attackers can create a local variable that shadows the policy hook, causing subsequent rewrites to call the attacker's code instead. Shadowing `_print_` also allows capturing RestrictedPython's internal `_getattr_` hook. The fix validates positional-only argument names using the same mechanism already applied to other parameter types. Attack requires the ability to submit code for compilation, and fix availability is confirmed for version 8.3.

## Affected products

- Zope Foundation RestrictedPython 8.2 and earlier

## Identifiers

- CVE-2026-55830
- GHSA-ffg3-p8fm-mjx2
- PYSEC-2026-3917

## Timeline

- 2026-06-22: disclosed: Vulnerability published by GitHub Advisory Database
- 2026-08-28: advisory: Advisory updated with full details
- 2026-08-28: patched: Fix released in RestrictedPython version 8.3

## References

- [https://api.github.com/users/Neroli-realy](https://api.github.com/users/Neroli-realy)
- [https://github.com/Neroli-realy](https://github.com/Neroli-realy)
- [https://api.github.com/users/Neroli-realy/gists%7B/gist_id%7D](https://api.github.com/users/Neroli-realy/gists%7B/gist_id%7D)
- [https://api.github.com/users/Neroli-realy/repos](https://api.github.com/users/Neroli-realy/repos)
- [https://avatars.githubusercontent.com/u/25514920?v=4](https://avatars.githubusercontent.com/u/25514920?v=4)
- [https://api.github.com/users/Neroli-realy/events%7B/privacy%7D](https://api.github.com/users/Neroli-realy/events%7B/privacy%7D)

## Related threats

- [RestrictedPython sandbox escape via string.Formatter field resolution](https://junglewise.ai/threats/cve-2026-76825-restrictedpython-sandbox-escape-via-string-formatter-field)
- [PYSEC-2026-1874 - try/except* clauses could allow bypass RestrictedPython via type confusion bug in the CPython interpreter](https://junglewise.ai/threats/cve-2025-22153-try-except-clauses-could-allow-bypass-restrictedpython-via-type)
- [RestrictedPython information leakage via `AttributeError.obj` and the `string` module](https://junglewise.ai/threats/cve-2024-47532-restrictedpython-information-leakage-via-attributeerror-obj-and)
- [Sandbox escape via various forms of "format".](https://junglewise.ai/threats/cve-2023-41039-sandbox-escape-via-various-forms-of-format)
- [RestrictedPython vulnerable to arbitrary code execution via stack frame sandbox escape](https://junglewise.ai/threats/cve-2023-37271-restrictedpython-vulnerable-to-arbitrary-code-execution-via-stack)
