CVE-2024-6844 Inconsistent CORS Matching Due to Handling of '+' in URL Path in corydolphin/flask-cors

Medium 5.3 Published Updated

Attackers can bypass CORS restrictions due to inconsistent path matching caused by '+' character handling in the flask-cors library.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2024-6844?

CVE-2024-6844 is a medium-severity vulnerability in corydolphin/flask-cors, published on 20 Mar 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

A vulnerability in corydolphin/flask-cors version 4.0.1 allows for inconsistent CORS matching due to the handling of the '+' character in URL paths. The request.path is passed through the unquote_plus function, which converts the '+' character to a space ' '. This behavior leads to incorrect path normalization, causing potential mismatches in CORS configuration. As a result, endpoints may not be matched correctly to their CORS settings, leading to unexpected CORS policy application. This can cause unauthorized cross-origin access or block valid requests, creating security vulnerabilities and usability issues.

Weakness: CWE-346

Which versions are affected by CVE-2024-6844?

3 open source packages ship an affected version, including flask-cors. It affects 1 product.

PackageAffectedFixed in
flask-cors PyPIAll versions6.0.0
flask-cors PyPIAll versions6.0.0
flask-cors PyPIAll versions6.0.0

Products include Flask-Cors Project Flask-Cors.

How do I fix CVE-2024-6844?

Upgrade flask-cors to 6.0.0 or later.

Is CVE-2024-6844 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-6844 exists.

Sources

Also known as CLSA-2026-1781139191, DEBIAN-CVE-2024-6844, ECHO-4cff-5ded-70e4, GHSA-8vgw-p6qm-5gr7, PYSEC-2026-1385, ROOT-APP-PYPI-CVE-2024-6844 and 1 more.

Is CVE-2024-6844 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free