rack
Affected
- introduced
3.0.0, fixed3.0.9.1(ecosystem)
Fixed versions
3.0.9.1
Fix
The export has no generic command for this ecosystem.
Advisory
Also known as: CVE-2024-25126
Rack vulnerable to ReDoS in content type parsing (2nd degree polynomial)
Summary
module Rack
class MediaType
SPLIT_PATTERN = %r{\s*[;,]\s*}
The above regexp is subject to ReDos. 50K blank characters as a prefix to the header will take over 10s to split.
PoC
A simple HTTP request with lots of blank characters in the content-type header:
request["Content-Type"] = (" " * 50_000) + "a,"
Impact
It's a very easy to craft ReDoS. Like all ReDoS the impact is debatable.
Medium Basis: The source's own band: MODERATE
3.0.0, fixed 3.0.9.1 (ecosystem)3.0.9.1
The export has no generic command for this ecosystem.
0.4, fixed 2.2.8.1 (ecosystem)2.2.8.1
The export has no generic command for this ecosystem.
Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.
Check your own computer: guard packages check
Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0