Skip to content

Rack ReDoS Vulnerability in HTTP Accept Headers Parsing

Moderate severity GitHub Reviewed Published Jul 2, 2024 in rack/rack • Updated Jul 5, 2024

Package

bundler rack (RubyGems)

Affected versions

>= 3.1.0, < 3.1.5

Patched versions

3.1.5

Description

Summary

A Regular Expression Denial of Service (ReDoS) vulnerability exists in the Rack::Request::Helpers module when parsing HTTP Accept headers. This vulnerability can be exploited by an attacker sending specially crafted Accept-Encoding or Accept-Language headers, causing the server to spend excessive time processing the request and leading to a Denial of Service (DoS).

Details

The fix for GHSA-54rr-7fvw-6x8f was not applied to the main branch and thus while the issue was fixed for the Rack v3.0 release series, it was not fixed in the v3.1 release series until v3.1.5.

References

@ioquatix ioquatix published to rack/rack Jul 2, 2024
Published by the National Vulnerability Database Jul 2, 2024
Published to the GitHub Advisory Database Jul 3, 2024
Reviewed Jul 3, 2024
Last updated Jul 5, 2024

Severity

Moderate

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
Low
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

EPSS score

0.045%
(16th percentile)

Weaknesses

CVE ID

CVE-2024-39316

GHSA ID

GHSA-cj83-2ww7-mvq7

Source code

Credits

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.