-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Comparing changes
Open a pull request
base repository: rack/rack
base: v3.2.5
head repository: rack/rack
compare: v3.2.6
- 19 commits
- 18 files changed
- 6 contributors
Commits on Mar 31, 2026
-
Configuration menu - View commit details
-
Copy full SHA for 549a135 - Browse repository at this point
Copy the full SHA 549a135View commit details -
Root directory disclosure via unescaped regex interpolation in \`Rack…
…::Directory\`. Escape the root path before interpolating into a regular expression, preventing RegexpError when the root contains metacharacters and avoiding path disclosure when regex silently mismatches.
Configuration menu - View commit details
-
Copy full SHA for 459ea1f - Browse repository at this point
Copy the full SHA 459ea1fView commit details -
Avoid O(n^2) algorithm in Rack::Utils.select_best_encoding
If a wildcard has already been seen as an acceptable encoding, ignore additional wildcards. Other improvements while here: * Only process up to 16 encodings. * Improve efficiency of candidate sorting. Add tests for: * Lower but non-zero wildcard priority * Multiple wildcards with different priorities
Configuration menu - View commit details
-
Copy full SHA for 8bf0c2e - Browse repository at this point
Copy the full SHA 8bf0c2eView commit details -
Parse Forwarded header instead of using regexp scan
`;` and `,` are allowed as characters inside a quoted value of a forwarded parameter. So you cannot safely split on those and then try to remove quotes. Switch to using a parser based on the one used for parsing multipart content-disposition.
Configuration menu - View commit details
-
Copy full SHA for 27e06c6 - Browse repository at this point
Copy the full SHA 27e06c6View commit details -
Raise error for multipart requests with multiple boundary parameters
RFC 1341 specifies there should be a single boundary parameter. Requests with multiple boundary parameters are unlikely to be legitimate, and likely are attempts to exploit parsing differences between rack and web application firewalls. * Disallow whitespace between boundary and = when parsing multipart boundaries Rack has historically not accepted these. To avoid security issues when parsing multiple boundaries, check for boundary cases that may have whitespace, but explicitly disallow the parsing if there is whitespace.
Configuration menu - View commit details
-
Copy full SHA for 1c0b723 - Browse repository at this point
Copy the full SHA 1c0b723View commit details -
Fix
header_rulesbypass via URL-encoded paths.Decode path once in applicable_rules before matching, fixing: - URL-encoded paths bypassing :fonts, Array, and Regexp header rules. - Path mutation across rules when String rule unescapes inside find_all. - Array rule values interpolated into regexp without Regexp.escape.
Configuration menu - View commit details
-
Copy full SHA for d6af063 - Browse repository at this point
Copy the full SHA d6af063View commit details -
Use
String#bytesizeforContent-Lengthin error responses.`String#size` returns character count, not byte count. For responses containing multi-byte UTF-8 characters, this produces an incorrect `Content-Length` value, violating RFC 9110 Section 8.6.
Configuration menu - View commit details
-
Copy full SHA for 10ecd9a - Browse repository at this point
Copy the full SHA 10ecd9aView commit details
Commits on Apr 1, 2026
-
Use a default limit of 100 byte ranges
Allow exceeding this limit by passing max_ranges keyword argument. If the limit is exceeded, return nil, treating the request as not requesting ranges. This seems better than returning [], which would treat the request as requesting no ranges. We use [] when the total size exceeds the size of the file, as such case is obviously a problem. However, a request with more than the given number of ranges is not obviously a problem.
Configuration menu - View commit details
-
Copy full SHA for 9138756 - Browse repository at this point
Copy the full SHA 9138756View commit details -
Change Rack::Request::AUTHORITY to only match RFC allowed characters
RFC 9110 specifies that allowed characters in a Host header come from RFC 3986 Section 3.2.2, which provides the following ABNF: ``` host = IP-literal / IPv4address / reg-name reg-name = *( unreserved / pct-encoded / sub-delims ) unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" pct-encoded = "%" HEXDIG HEXDIG sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" ``` This limits the allowed characters to those characters. This breaks a spec that tests for internationalized domain names. Such a spec is incorrect as internationalized domain names must be encoded via punycode in Host headers, so update the specs to correctly test for the punycode versions.Configuration menu - View commit details
-
Copy full SHA for 2246626 - Browse repository at this point
Copy the full SHA 2246626View commit details -
Only do a simple substitution on the x-accel-mapping paths
Mention the substitution is case insensitive in the documentation, since if the file system is case sensitive, this would be unexpected.
Configuration menu - View commit details
-
Copy full SHA for a57bc14 - Browse repository at this point
Copy the full SHA a57bc14View commit details -
Fix root prefix bug in Rack::Static
This is similar to the fix of CVE-2026-22860 for Rack::Directory.
Configuration menu - View commit details
-
Copy full SHA for 7a8f326 - Browse repository at this point
Copy the full SHA 7a8f326View commit details -
Add Content-Length size check in Rack::Multipart::Parser
Compare the declared `Content-Length` against a configurable maximum (`PARSER_BYTESIZE_LIMIT`) before any parsing begins. If it exceeds the limit, raise an exception immediately.
Configuration menu - View commit details
-
Copy full SHA for b3e5945 - Browse repository at this point
Copy the full SHA b3e5945View commit details -
Limit the number of quoted escapes during multipart parsing
This sets a default limit of 8192 escapes, which can be modified using the RACK_MULTIPART_CONTENT_DISPOSITION_QUOTED_ESCAPES_LIMIT environment variable.
Configuration menu - View commit details
-
Copy full SHA for bfb6914 - Browse repository at this point
Copy the full SHA bfb6914View commit details -
Implement OBS unfolding for multipart requests per RFC 5322 2.2.3
Do this for both the Content-Disposition and Content-Type lines. Co-authored-by: "William T. Nelson" <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for d50c4d3 - Browse repository at this point
Copy the full SHA d50c4d3View commit details -
Configuration menu - View commit details
-
Copy full SHA for bf83042 - Browse repository at this point
Copy the full SHA bf83042View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8f425de - Browse repository at this point
Copy the full SHA 8f425deView commit details -
Configuration menu - View commit details
-
Copy full SHA for d268165 - Browse repository at this point
Copy the full SHA d268165View commit details -
Configuration menu - View commit details
-
Copy full SHA for 31989fd - Browse repository at this point
Copy the full SHA 31989fdView commit details -
Configuration menu - View commit details
-
Copy full SHA for e1f22fd - Browse repository at this point
Copy the full SHA e1f22fdView commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff v3.2.5...v3.2.6