PyPI: mpmath

CVE-2021-29063

Safety vulnerability ID: SFTY-20210621-16519

Safety legacy ID: pyup.io-51549

Mpmath 1.3.0 includes a fix for CVE-2021-29063: Regular Expression Denial of Service (ReDOS) vulnerability when the mpmathify function is called. https://github.com/fredrik-johansson/mpmath/commit/46d44c3c8f3244017fe1eb102d564eb4ab8ef750

Created at: Jul 5, 2026Updated at: Jul 5, 2026

Overview

ReDOS in Mpmath

Advisory

Mpmath 1.3.0 includes a fix for CVE-2021-29063: Regular Expression Denial of Service (ReDOS) vulnerability when the mpmathify function is called. https://github.com/fredrik-johansson/mpmath/commit/46d44c3c8f3244017fe1eb102d564eb4ab8ef750

Affected Package

Affecting mpmath package, versions>=1.0.0,<=1.2.1

Also affects

---

How to Fix

Upgradempmathto1.3.0or higher.

Mitigation and Workarounds

---

Vulnerable Functions

Functions linked to known vulnerabilities.

Vulnerable function data is available for Enterprise customers

Book a call with us to see Safety in action.

Safety

Verified by Safety

Our Cybersecurity Intelligence Team reviewed this vulnerability. We combine public data with our own research to find issues not yet reported to public sources.

Learn more