CVE-2025-59830: Rack has an unsafe default in Rack::QueryParser allows params_limit bypass via semicolon-separated parameters
7.5
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
-
CWE
Published
9/25/2025
Updated
9/25/2025
KEV Status
No
Technology
Ruby
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
rack | rubygems | < 2.2.18 | 2.2.18 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability exists in how Rack's query parser handles parameter limits. The description and the provided patch clearly indicate that the check_query_string
function in lib/rack/query_parser.rb
is the source of the vulnerability. The patch modifies this function to correctly count both '&' and ';' as parameter separators when enforcing the params_limit
. The previous implementation only counted '&', which allowed an attacker to bypass the limit by using semicolons, potentially leading to a denial of service through resource exhaustion. The functions parse_query
and parse_nested_query
call check_query_string
, making them the entry points for the vulnerable logic, but the root cause is within check_query_string
itself.
Vulnerable functions
Rack::QueryParser.check_query_string
lib/rack/query_parser.rb
The vulnerability lies in the `check_query_string` function within the `Rack::QueryParser` class. The original code only counted the ampersand ('&') character to enforce the `params_limit`, but the query parser would split parameters on both ampersands and semicolons (';'). This discrepancy allowed an attacker to bypass the parameter limit by using semicolons as separators, leading to excessive resource consumption. The patch corrects this by counting both '&' and ';' characters.