Cross-site scripting in Rack
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- Required
- Attack complexity
- Low
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- Low · Low · None
- Fix status
- Partial Red Hat: 4 without a fix
Attack profile from CVSS 3.0 · NVD. Fix status from CNA, GitHub and Red Hat. Impact type from CWE-79.
Summary
There is a possible XSS vulnerability in Rack before 2.0.6 and 1.6.11. Carefully crafted requests can impact the data returned by the `scheme` method on `Rack::Request`. Applications that expect the scheme to be limited to 'http' or 'https' and do not escape the return value could be vulnerable to an XSS attack. Note that applications using the normal escaping mechanisms provided by Rails may not impacted, but applications that bypass the escaping mechanisms, or do not use them may be vulnerable.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| rack | Rack | 2.0.6, 1.6.11 | — | No fix listed | CNA |
| — | rack (RubyGems) | 2.0.0 to before 2.0.6 | 2.0.6 | Patch available | GHSA-5r2p-j47h-mhpg |
| — | rack (RubyGems) | before 1.6.11 | 1.6.11 | Patch available | GHSA-5r2p-j47h-mhpg |
- Rack Vendorrack Affected 2.0.6, 1.6.11 Fixed in — No fix listed CNA
- rack (RubyGems) Vendor— Affected 2.0.0 to before 2.0.6 Fixed in 2.0.6 Patch available GHSA-5r2p-j47h-mhpg
- rack (RubyGems) Vendor— Affected before 1.6.11 Fixed in 1.6.11 Patch available GHSA-5r2p-j47h-mhpg
CPE configurations NVD · 2
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:a:rack_project:rack:*:*:*:*:*:*:*:* | 1.6.0 to before 1.6.11; 2.0.0 to before 2.0.6 | Vulnerable | Rack Project |
| cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:* | 8.0 | Vulnerable | Debian |
- cpe:2.3:a:rack_project:rack:*:*:*:*:*:*:*:* Versions 1.6.0 to before 1.6.11; 2.0.0 to before 2.0.6 Vulnerable ·Rack Project
- cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:* Versions 8.0 Vulnerable ·Debian
Remediation
- Fix · GHSA-5r2p-j47h-mhpg rack (RubyGems) Fixed in 2.0.6 Advisory →
- Fix · GHSA-5r2p-j47h-mhpg rack (RubyGems) Fixed in 1.6.11 Advisory →
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat Software Collections | Affected | No fix planned: Will not fix |
| Red Hat Storage 3 | Affected | No fix planned: Will not fix |
| Red Hat Subscription Asset Manager | Affected | No fix planned: Will not fix |
| Red Hat Update Infrastructure 3 for Cloud Providers | Affected | No fix planned: Will not fix |
Not affected: 12 products
- CloudForms Management Engine 5
- Red Hat OpenShift Container Platform 3.2
- Red Hat OpenShift Container Platform 3.3
- Red Hat OpenShift Container Platform 3.4
- Red Hat OpenShift Enterprise 3.1
- Red Hat OpenStack Platform 10 (Newton) Operational Tools
- Red Hat OpenStack Platform 12 (Pike) Operational Tools
- Red Hat OpenStack Platform 13 (Queens) Operational Tools
- Red Hat OpenStack Platform 14 (Rocky) Operational Tools
- Red Hat OpenStack Platform 8 (Liberty) Operational Tools
- Red Hat OpenStack Platform 9 (Mitaka) Operational Tools
- Red Hat Satellite 6
Timeline
- 2026-10-02 Threatist record created from CVE-2018-16471
- 2026-10-03 Alias added: GHSA-5r2p-j47h-mhpg
References
Advisory 5
Other 6
- https://groups.google.com/forum/#%21topic/rubyonrails-security/GKsAFT924Ag
- https://github.com/rack/rack
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/rack/CVE-2018-16471.yml
- https://groups.google.com/forum/#!topic/ruby-security-ann/NAalCee8n6o
- https://groups.google.com/forum/#!topic/rubyonrails-security/GKsAFT924Ag
- https://usn.ubuntu.com/4089-1
More rack vulnerabilities
- TI-2024-23301 rack-contrib vulnerable to Denial of Service due to the unconstrained value of the incoming "profiler_runs" parameter CVSS 3.1HIGH 8.6
- TI-2024-16580 Rack ReDos in content type parsing (2nd degree polynomial) CVSS 3.1HIGH 7.5
- TI-2026-28312 Rack::Session::Cookie secrets: decrypt failure fallback enables secretless session forgery and Marshal deserialization CVSS 4.0CRITICAL 9.3
- TI-2024-17236 Possible Denial of Service Vulnerability in Rack Header Parsing CVSS 3.1HIGH 7.5
- TI-2024-17231 Possible DoS Vulnerability with Range Header in Rack CVSS 3.1HIGH 7.5
- TI-2023-12254 Uncontrolled resource consumption in https://github.com/rack/rack CVSS 3.1HIGH 7.5
Sources
- CVE-2018-16471 · CVE Program
- CVE-2018-16471 · NVD
- FIRST EPSS
- GHSA-5r2p-j47h-mhpg · GitHub Advisory Database · CC BY 4.0
- CVE-2018-16471 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences