# CVE-2021-23385: flask-security: This affects all versions of package Flask-Security

CVE-2021-23385 is fixed in 2 products on 1 platform, first by python3-flask-security 1.7.5-2ubuntu0.18.04.1~esm1, released August 2, 2022. It is not reported as exploited. Patch Radar priority: Routine.

- Web page: https://patchblox.com/security/cve/CVE-2021-23385
- Priority: Routine
- CVSS: 6.1 (medium)
- EPSS: 0.0125
- CISA KEV: not listed
- Exploited (vendor report): no
- Publicly disclosed: no
- Published: Aug 2, 2022

## Description

This affects all versions of package Flask-Security. When using the get_post_logout_redirect and get_post_login_redirect functions, it is possible to bypass URL validation and redirect a user to an arbitrary URL by providing multiple back slashes such as \\\evil.com/path. This vulnerability is only exploitable if an alternative WSGI server other than Werkzeug is used, or the default behaviour of Werkzeug is modified using 'autocorrect_location_header=False. **Note:** Flask-Security is not maintained anymore.

## Where it's fixed

| Platform | Product | Fixed in | Fix | Released |
|---|---|---|---|---|
| Linux | flask-security Debian 12.15 (bookworm) | 5.0.2-1 | [DEBIAN-CVE-2021-23385](https://patchblox.com/security/data/fix/linux/debian-cve-2021-23385.md) | Aug 2, 2022 |
| Linux | flask-security Debian 13.5 (trixie) | 5.0.2-1 | [DEBIAN-CVE-2021-23385](https://patchblox.com/security/data/fix/linux/debian-cve-2021-23385.md) | Aug 2, 2022 |
| Linux | flask-security Debian 14 | 5.0.2-1 | [DEBIAN-CVE-2021-23385](https://patchblox.com/security/data/fix/linux/debian-cve-2021-23385.md) | Aug 2, 2022 |
| Linux | python3-flask-security Ubuntu 18.04.6 LTS (bionic) | 1.7.5-2ubuntu0.18.04.1~esm1 | [python3-flask-security 1.7.5-2ubuntu0.18.04.1~esm1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-python3-flask-security-1.7.5-2ubuntu0.18.04.1-esm1.md) | Aug 2, 2022 |
| Linux | python3-flask-security Ubuntu 20.04 LTS (focal) | 1.7.5-2ubuntu0.20.04.1 | [python3-flask-security 1.7.5-2ubuntu0.20.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-focal-python3-flask-security-1.7.5-2ubuntu0.20.04.1.md) | Aug 2, 2022 |
| Linux | python3-flask-security Ubuntu 22.04.1 LTS (jammy) | 4.0.0-1ubuntu0.1 | [python3-flask-security 4.0.0-1ubuntu0.1](https://patchblox.com/security/data/fix/linux/ubuntu-jammy-python3-flask-security-4.0.0-1ubuntu0.1.md) | Aug 2, 2022 |

---

Data as of 2026-11-08T13:06:02Z UTC. Source: Patchblox Patch Radar (https://patchblox.com/security/patch-radar). Patchblox finds out-of-date software on Windows, macOS and Linux and updates it through release rings: https://patchblox.com/demo

Free to use with attribution: show "Data: Patchblox Patch Radar" with a link to https://patchblox.com/security/patch-radar. Terms, including what needs a written agreement: https://patchblox.com/security/patch-radar/use-the-data

Product names, logos and trademarks shown on Patch Radar belong to their respective owners. They are used only to identify the software each security fix applies to and to help readers find their platform. Their use does not imply any affiliation with, or endorsement by, those owners, and Patchblox is not affiliated with any of them.
