{"id":"CVE-2026-34785","published":"2026-04-02T16:44:17Z","modified":"2026-07-15T01:03:43Z","title":"Rack: Local file inclusion in `Rack::Static` via URL Prefix Matching","vendor":"rack","product":"rack","tier":"tail","description":{"text":"Rack is a modular Ruby web server interface. Prior to versions 2.2.23, 3.1.21, and 3.2.6, Rack::Static determines whether a request should be served as a static file using a simple string prefix check. When configured with URL prefixes such as \"/css\", it matches any request path that begins with that string, including unrelated paths such as \"/css-config.env\" or \"/css-backup.sql\". As a result, files under the static root whose names merely share the configured prefix may be served unintentionally, leading to information disclosure. This issue has been patched in versions 2.2.23, 3.1.21, and 3.2.6.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.5,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00549,"percentile":0.39585,"provenance":"source"},"cwes":[{"id":"CWE-187","name":"Partial String Comparison"},{"id":"CWE-200","name":"Exposure of Sensitive Information to an Unauthorized Actor"},{"id":"CWE-552","name":"Files or Directories Accessible to External Parties"}],"references":[{"url":"https://github.com/rack/rack/security/advisories/GHSA-h2jq-g4cq-5ppq","tags":["x_refsource_CONFIRM"]},{"url":"https://access.redhat.com/security/cve/CVE-2026-34785","tags":["vdb-entry","x_refsource_REDHAT"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2454486","tags":["issue-tracking","x_refsource_REDHAT"]},{"url":"https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-34785.json","tags":["x_sadp-csaf-vex"]}],"priority":{"score":13.2,"factors":[{"name":"EPSS percentile","points":7.92},{"name":"CVSS severity","points":5.25}]},"vendorSlug":"rack","affectedVersions":[{"vendor":"rack","product":"rack","versions":["< 2.2.23",">= 3.0.0.beta1, < 3.1.21",">= 3.2.0, < 3.2.6"]}],"ssvc":{"exploitation":"none","automatable":"yes","technicalImpact":"partial","timestamp":"2026-04-02T18:58:57.726888Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"RubyGems","package":"rack","vulnerableRanges":["<2.2.23",">=3.0.0.beta1, <3.1.21",">=3.2.0, <3.2.6"],"patched":["2.2.23","3.1.21","3.2.6"],"from":["GHSA-h2jq-g4cq-5ppq"],"provenance":"source"}],"summary":{"text":"The flaw is in the Rack::Static component of the rack Ruby web server interface, where URL prefix matching uses a simple string prefix check, so configured prefixes such as \"/css\" also match unrelated paths like \"/css-config.env\". An unauthenticated remote attacker who can send HTTP requests can retrieve files under the static root whose names merely share a configured prefix, which may disclose sensitive information; no user interaction or special configuration is indicated beyond the use of such prefixes.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:51:05Z"},"euvd":{"id":"EUVD-2026-18382","exploited":false,"provenance":"source"}}