CVE-2023-41039: RestrictedPython is a restricted execution environment for Python to run untrusted code
CVE-2023-41039 is a high-severity flaw (CVSS 8.3) affecting restrictedpython. Below: why it ranks where it does, which versions are affected, what to do, and the exact commands.
RestrictedPython is a restricted execution environment for Python to run untrusted code. Python's "format" functionality allows someone controlling the format string to "read" all objects accessible through recursive attribute lookup and subscription from objects he can access. This can lead to critical information disclosure. With `RestrictedPython`, the format functionality is available via the `format` and `format_map` methods of `str` (and `u
Why this priority
- High severity
A fixed release or distro patch exists.
Risk facts
| CVSS score | 8.3 (High) |
| Attack vector | Network (remote) |
| Attack complexity | Low |
| Privileges needed | High |
| User interaction | Required |
| EPSS exploit chance | 0.7% (top 48%) |
| CISA exploited list | No |
| Weakness | CWE-74 |
| Published | 2023-08-30 |
| Last modified | 2026-06-17 |
Last updated 2026-06-17 · Sources: CVE Program, NVD, CISA KEV, EPSS and vendor advisories · How we score
Am I affected?
Timeline
- Published CVE record published
- Updated Record last modified
Scores and fixes here are computed automatically from those and other public sources. Confirm with the vendor advisory before changing production systems.
Quick answers
How do I fix CVE-2023-41039?
restrictedpython: upgrade to 5.4, 6.2. Exact commands for each OS are on this page.
Is CVE-2023-41039 being exploited?
CVE-2023-41039 is not on the CISA Known Exploited Vulnerabilities list at the time of the last update. Check again, as this can change.
What does CVE-2023-41039 affect?
CVE-2023-41039 affects restrictedpython. Severity is high (CVSS 8.3). RestrictedPython is a restricted execution environment for Python to run untrusted code. Python's "format" functionality allows someone controlling the format string to "read" all objects accessible through recursive attribute lookup and su
How urgent is CVE-2023-41039?
Priority 42/100. High severity
Software pages
Related CVEs
- CVE-2024-47532 MEDIUM 6.5 UPGRADE RestrictedPython is a restricted execution environment for Python to run untrusted code
- CVE-2023-37271 HIGH 8.4 UPGRADE RestrictedPython is a tool that helps to define a subset of the Python language which allows users to provide