Red Hat VEX
RHVEX-CVE-2023-25577
python-werkzeug: high resource usage when parsing multipart form data with many fields
Details
A flaw was found in python-werkzeug. Werkzeug is multipart form data parser, that will parse an unlimited number of parts, including file parts. These parts can be a small amount of bytes, but each requires CPU time to parse, and may use more memory as Python data. If a request can be made to an endpoint that accesses request.data, request.form, request.files, or request.get_data(parse_form_data=False), it can cause unexpectedly high resource usage, allowing an attacker to cause a denial of service by sending crafted multipart data to an endpoint that will parse it. The amount of CPU time required can block worker processes from handling legitimate requests, and if many concurrent requests are sent continuously, this can exhaust or kill all available workers.
Affected packages
| Ecosystem | Package | Affected versions |
|---|---|---|
| Red Hat:enterprise_linux:7 | python-werkzeug | All versions, no fix yet |
| Red Hat:enterprise_linux:8 | python3-werkzeug | All versions, no fix yet |
References
- https://access.redhat.com/security/cve/CVE-2023-25577
- https://bugzilla.redhat.com/show_bug.cgi?id=2170242
- https://www.cve.org/CVERecord?id=CVE-2023-25577
- https://nvd.nist.gov/vuln/detail/CVE-2023-25577
- https://github.com/pallets/werkzeug/commit/517cac5a804e8c4dc4ed038bb20dacd038e7a9f1
- https://github.com/pallets/werkzeug/releases/tag/2.2.3
- https://github.com/pallets/werkzeug/security/advisories/GHSA-xg9f-g7g7-2323