# CVE-2021-32811: Remote Code Execution via Script (Python) objects under Python 3

Source: https://junglewise.ai/threats/cve-2021-32811-remote-code-execution-via-script-python-objects-under-python-3  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2021-08-02  
License: CC BY 4.0 with a link back

CVE-2021-32811 · Severity: low · CVSS 3.1 · Published 2021-08-02

Zope is an open-source web application server. Zope versions prior to versions 4.6.3 and 5.3 have a remote code execution security issue. In order to be affected, one must use Python 3 for one's Zope deployment, run Zope 4 below version 4.6.3 or Zope 5 below version 5.3, and have the optional `Products.PythonScripts` add-on package installed. By default, one must have the admin-level Zope "Manager" role to add or edit Script (Python) objects through the web. Only sites that allow untrusted users to add/edit these scripts through the web are at risk. Zope releases 4.6.3 and 5.3 are not vulnerable. As a workaround, a site administrator can restrict adding/editing Script (Python) objects through the web using the standard Zope user/role permission mechanisms. Untrusted users should not be assigned the Zope Manager role and adding/editing these scripts through the web should be restricted to trusted users only. This is the default configuration in Zope.

Technologies: [AccessControl (PyPI)](https://junglewise.ai/threats/technologies/accesscontrol), [Zope (PyPI)](https://junglewise.ai/threats/technologies/zope). Vendors: [PyPI](https://junglewise.ai/threats/vendors/pypi).

## Quick answers

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

**How severe is CVE-2021-32811?** Low severity, with a CVSS score of 3.1, published 2 August 2021.

**Which products and versions are affected?** AccessControl (PyPI) ECOSYSTEM:introduced=4.0,fixed=4.3,introduced=5.0,fixed=5.2; Zope (PyPI) ECOSYSTEM:introduced=4.0,fixed=4.6.3, GIT:introduced=0,fixed=f72a18dda8e9bf2aedb46168761668464a4be988|ECOSYSTEM:introduced=4.0,fixed=4.6.3,introduced=5.0,fixed=5.3.

**Is there a fix for CVE-2021-32811?** Yes. AccessControl (PyPI): upgrade to 5.2 or later; Zope (PyPI): upgrade to 4.6.3, 5.3 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**Am I affected by CVE-2021-32811?** Check whether you run AccessControl (PyPI) or Zope (PyPI) 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

- AccessControl (PyPI): upgrade to 5.2 or later

  ```sh
  pip install "AccessControl>=5.2"
  ```

- Zope (PyPI): upgrade to 4.6.3, 5.3 or later

  ```sh
  pip install "Zope>=5.3"
  ```


## Affected products

- AccessControl (PyPI) ECOSYSTEM:introduced=4.0,fixed=4.3,introduced=5.0,fixed=5.2
- Zope (PyPI) ECOSYSTEM:introduced=4.0,fixed=4.6.3, GIT:introduced=0,fixed=f72a18dda8e9bf2aedb46168761668464a4be988|ECOSYSTEM:introduced=4.0,fixed=4.6.3,introduced=5.0,fixed=5.3

## Identifiers

- CVE-2021-32811
- GHSA-g4gq-j4p2-j8fr
- PYSEC-2021-368
- PYSEC-2021-370

## Related threats

- [Zope AccessControl information disclosure via string format functions](https://junglewise.ai/threats/cve-2026-77401-zope-accesscontrol-information-disclosure-via-string-format)
- [PYSEC-2026-2326 - Access control vulnerable to user data deletion by anonynmous users](https://junglewise.ai/threats/cve-2024-51734-access-control-vulnerable-to-user-data-deletion-by-anonynmous)
- [PYSEC-2026-2325 - Information disclosure in AccessControl](https://junglewise.ai/threats/cve-2023-41050-information-disclosure-in-accesscontrol)
- [PYSEC-2026-2077 - Zope vulnerable to Stored Cross Site Scripting with SVG images](https://junglewise.ai/threats/cve-2023-42458-zope-vulnerable-to-stored-cross-site-scripting-with-svg-images)
- [PYSEC-2026-760 - Zope DocumentTemplate package allows unauthenticated write](https://junglewise.ai/threats/cve-2000-0483-zope-documenttemplate-package-allows-unauthenticated-write)
