Skip to content
Heist/ feed
Back to feed
Low

Sinatra has ReDoS vulnerability in ETag header value generation

Type: advisorySources: OSV

Sinatra is a domain-specific language for creating web applications in Ruby. In versions prior to 4.2.0, 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. 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. Version 4.2.0 fixes the issue.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2025-61921
Confirmed fixed CVEs
Not specified
Updated in this feed
2 Nov 2026, 18:25 UTC · Revision 1

Source evidence

Sinatra has ReDoS vulnerability in ETag header value generation

core-osv · Original source

Published 10 Oct 2025, 19:28 UTC

Sinatra is a domain-specific language for creating web applications in Ruby. In versions prior to 4.2.0, 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. 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. Version 4.2.0 fixes the issue.

osv:CVE-2025-61921
Complete source record
{
  "id": "804676ac0a5a1bb42cb86df2029b5491c84ae15a5f43f780c4ad8b2ef630c047",
  "url": "https://osv.dev/vulnerability/CVE-2025-61921",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Sinatra has ReDoS vulnerability in ETag header value generation",
    "summary": "Sinatra is a domain-specific language for creating web applications in Ruby. In versions prior to 4.2.0, 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. 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. Version 4.2.0 fixes the issue.",
    "evidence": "osv:CVE-2025-61921",
    "products": [],
    "severity": "low",
    "structured": {
      "id": "CVE-2025-61921",
      "aliases": [
        "CVE-2025-61921",
        "GHSA-mr3q-g2mv-mr4q"
      ],
      "metrics": [
        {
          "type": "CVSS_V4",
          "score": "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"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/sinatra/sinatra",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "f2ad45f7d2456172974a30d300e9f82424336e09"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "4.2.0"
                      }
                    ],
                    "source": "AFFECTED_FIELD",
                    "strategy": "StringRangeExpression"
                  },
                  {
                    "cpe": "cpe:2.3:a:sinatrarb:sinatra:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "4.2.0"
                      }
                    ],
                    "source": "CPE_RANGE"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v3.2.0",
            "v4.0.0",
            "v4.1.1",
            "v4.1.0",
            "v3.1.0",
            "v3.0.6",
            "v3.0.5",
            "v3.0.4",
            "v3.0.3",
            "v3.0.2",
            "v3.0.1",
            "v3.0.0",
            "v2.2.0",
            "v2.1.0",
            "v2.0.8.1",
            "v2.0.8",
            "v2.0.7",
            "v2.0.6",
            "v2.0.5",
            "v2.0.4",
            "v2.0.3",
            "v2.0.2",
            "v2.0.1",
            "v2.0.1.rc1",
            "v2.0.0",
            "v2.0.0.rc6",
            "v2.0.0.rc5",
            "2.0.0.rc5",
            "v2.0.0.rc4",
            "2.0.0.rc4",
            "v2.0.0.rc3",
            "2.0.0.rc3",
            "v2.0.0.rc2",
            "v2.0.0.beta2",
            "v2.0.0.rc1",
            "v1.4.6",
            "v1.4.5",
            "v1.4.4",
            "v1.4.3",
            "1.4.3",
            "v1.4.2",
            "1.4.2",
            "v1.4.1",
            "1.4.1",
            "v1.4.0",
            "1.4.0",
            "v1.3.2",
            "1.3.2",
            "v1.3.1",
            "1.3.1",
            "v1.3.0",
            "1.3.0",
            "v1.2.1",
            "1.2.1",
            "v1.2.0",
            "1.2.0",
            "1.2.0.d",
            "1.2.0.c",
            "1.2.0.b",
            "1.2.0.a",
            "v1.1.0",
            "1.1.0",
            "1.1.b",
            "1.1.a",
            "v1.0.0",
            "semver",
            "1.0",
            "1.0.b",
            "1.0.a",
            "0.9.2",
            "0.9.1.1",
            "0.9.1",
            "0.9.0.2",
            "0.9.0.1",
            "0.3.3",
            "0.3.2",
            "0.3.1",
            "0.3.0",
            "0.2.2",
            "0.2.0",
            "0.1.7",
            "0.1.6",
            "0.1.5",
            "0.1.0",
            "0.0.1"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-61921.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:22.039876149Z",
      "provider": "osv",
      "references": [
        "https://bugs.ruby-lang.org/issues/19104",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/61xxx/CVE-2025-61921.json",
        "https://github.com/sinatra/sinatra/security/advisories/GHSA-mr3q-g2mv-mr4q",
        "https://nvd.nist.gov/vuln/detail/CVE-2025-61921",
        "https://github.com/sinatra/sinatra/issues/2120",
        "https://github.com/sinatra/sinatra/pull/1823",
        "https://github.com/sinatra/sinatra/pull/2121"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-1333"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/61xxx/CVE-2025-61921.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2025-61921",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 488350,
  "published_at": "2025-10-10T19:28:10.688+00:00"
}