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

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), Zope (PyPI). 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
    pip install "AccessControl>=5.2"
  • Zope (PyPI): upgrade to 4.6.3, 5.3 or later
    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

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.