Loading...
Skip to main content

CVE-2025-61921 — Vulnerability in sinatra — CVE Details

LOW

Sinatra is vulnerable to ReDoS through ETag header value generation

Published October 10, 2025Updated September 10, 2026Source: osv

Summary

### Summary There is a denial of service vulnerability in the `If-Match` and `If-None-Match` header parsing component of Sinatra, if the `etag` method is used when constructing the response and you are using Ruby < 3.2. ### Details Carefully crafted input can cause `If-Match` and `If-None-Match` header parsing in Sinatra to take an unexpected amount of time, possibly resulting in a denial of service attack vector. This header is typically involved in generating the `ETag` header value. Any applications that use the `etag` method when generating a response are impacted if they are using Ruby below version 3.2. ### Resources * https://github.com/sinatra/sinatra/issues/2120 (report) * https://github.com/sinatra/sinatra/pull/2121 (fix) * https://github.com/sinatra/sinatra/pull/1823 (older ReDoS vulnerability) * https://bugs.ruby-lang.org/issues/19104 (fix in Ruby >= 3.2)

Advisory Timeline

  • First published October 10, 2025 (367 days ago).
  • Last revised September 10, 2026 — 334 days after initial publication.

Remediation

Upgrade to the fixed version using your package manager.

Bundler
Update sinatra to 4.2.0 or later
gem install sinatra -v 4.2.0

After upgrading, run your dependency scanner again to confirm the vulnerability is resolved.

Affected Packages (1)

Affects 1 ecosystem: rubygems (1).

PackageEcosystemAffectedFixed In
sinatra
rubygems
0.1.0, 0.1.5, 0.1.6, 0.1.7 (+102 more)4.2.0

Vulnerability Classification

Common Weakness Enumeration (CWE) identifiers for this vulnerability type.

CVSS Score Breakdown

What the CVSS (Common Vulnerability Scoring System) 5.3 score means for each attack dimension.

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
—
Confidentiality
—
Integrity
—
Availability
—

CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:U

Frequently Asked Questions

What is CVE-2025-61921?
Sinatra is vulnerable to ReDoS through ETag header value generation This vulnerability has been assigned a severity rating of LOW (CVSS score: 5.3/10).
How do I check if my project is affected by CVE-2025-61921?
CVE-2025-61921 affects sinatra. Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2025-61921 and 200,000+ other known vulnerabilities.

Severity & Exploitability

CVSS Score
5.3

Exploitation requires specific conditions or has limited impact. Remediate within weeks.

Also Known As

GHSA-mr3q-g2mv-mr4q

Related CVEs

Check if you're affected

Scan your dependencies to see if this vulnerability affects your projects.

Scan Your Dependencies