Skip to content
DoS Disclosed report Intermediate CVE-2024-41128

Possible ReDoS vulnerability in query parameter filtering in Action Dispatch

The query parameter filtering routines in Action Dispatch could take an unexpected amount of time when given carefully crafted query parameters. An attacker could use this to cause a denial of service.

scyoon Follow

Originally disclosed on HackerOne

  • Fixed in 2 months
  • Paid in 2 months
  • Disclosed after 3 months

Summary by the program

There is a possible ReDoS vulnerability in the query parameter filtering routines of Action Dispatch. This vulnerability has been assigned the CVE identifier CVE-2024-41128.

Versions Affected: < 8.0.0.beta1 Not affected: >= 8.0.0.beta1, Ruby >= 3.2 Fixed Versions: 7.2.1.1, 7.1.4.1, 7.0.8.5, 6.1.7.9

Impact Carefully crafted query parameters can cause query parameter filtering to take an unexpected amount of time, possibly resulting in a DoS vulnerability. All users running an affected release should either upgrade or apply the relevant patch immediately.

Ruby 3.2 has mitigations for this problem, so Rails applications using Ruby 3.2 or newer are unaffected. Rails 8.0.0.beta1 requires Ruby 3.2 or greater so is unaffected.

Advisory: https://discuss.rubyonrails.org/t/cve-2024-41128-possible-redos-vulnerability-in-query-parameter-filtering-in-action-dispatch/87699

The report

I have found a potential ReDoS vulnerability and reported it to the Rails team. Also the patches of mine have been included. You can find detailed information at the following link:

There is a possible ReDoS vulnerability in the query parameter filtering routines of Action Dispatch. This vulnerability has been assigned the CVE identifier CVE-2024-41128.

Versions Affected: < 8.0.0.beta1 Not affected: >= 8.0.0.beta1, Ruby >= 3.2 Fixed Versions: 7.2.1.1, 7.1.4.1, 7.0.8.5, 6.1.7.9

Impact

Carefully crafted query parameters can cause query parameter filtering to take an unexpected amount of time, possibly resulting in a DoS vulnerability. All users running an affected release should either upgrade or apply the relevant patch immediately.

Ruby 3.2 has mitigations for this problem, so Rails applications using Ruby 3.2 or newer are unaffected. Rails 8.0.0.beta1 requires Ruby 3.2 or greater so is unaffected.

The original report as published on HackerOne, by scyoon. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely a regular expression used in query parameter filtering has super-linear worst-case matching time on crafted input.

Impact

An attacker could cause a denial of service by making query parameter filtering take an unexpected amount of time; applications using Ruby 3.2 or newer are unaffected due to mitigations in Ruby.

What the attacker needed

Affected Rails version; Ruby older than 3.2

The fix

The vulnerability was fixed in versions [redacted], [redacted], [redacted], and 6.1.7.9.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

A regular expression is a pattern used to match text. Some patterns can become very slow when given specially crafted input, which is called a ReDoS. Here, an attacker could send a query string that makes the server spend a long time filtering parameters, potentially stopping it from serving other users.

What is DoS?

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.

More by scyoon

View all

2 more disclosed reports, best first.

More from Internet Bug Bounty

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Denial of service

The lesson behind this report.

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.