What’s Vulnerable › Vulnerabilities
CVE-2021-32838: Regular Expression Denial of Service in flask-restx
- Severity: medium (CVSS 5.0 v2.0)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 1.9% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2021-09-20 · updated 2026-06-17
- Weakness: CWE-400
Description
Flask-RESTX (pypi package flask-restx) is a community driven fork of Flask-RESTPlus. Flask-RESTX before version 0.5.1 is vulnerable to ReDoS (Regular Expression Denial of Service) in email_regex. This is fixed in version 0.5.1.
Affected products
- Fedoraproject Fedora: 33, 34
- Flask-Restx Project Flask-Restx: before 0.5.1 — fixed in 0.5.1
How to fix
Upgrade to a fixed version: Flask-Restx Project Flask-Restx 0.5.1. Check the vendor advisory for mitigations.
References
- https://github.com/advisories/GHSA-3q6g-vf58-7m4g
- https://github.com/python-restx/flask-restx/blob/fd99fe11a88531f5f3441a278f7020589f9d2cc0/flask_restx/inputs.py#L51
- https://github.com/python-restx/flask-restx/commit/bab31e085f355dd73858fd3715f7ed71849656da
- https://github.com/python-restx/flask-restx/issues/372
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/5UCTFVDU3677B5OBGK4EF5NMUPJLL6SQ/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/QUD6SWZLX52AAZUHDETJ2CDMQGEPGFL3/
- https://pypi.org/project/flask-restx/
- https://github.com/advisories/GHSA-3q6g-vf58-7m4g
- https://github.com/python-restx/flask-restx/blob/fd99fe11a88531f5f3441a278f7020589f9d2cc0/flask_restx/inputs.py#L51
- https://github.com/python-restx/flask-restx/commit/bab31e085f355dd73858fd3715f7ed71849656da
- https://github.com/python-restx/flask-restx/issues/372
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/5UCTFVDU3677B5OBGK4EF5NMUPJLL6SQ/
Get alerted when CVE-2021-32838 or the next vulnerability affects your stack