CVE-2022-24790 — Vulnerability in puma — CVE Details
Puma vulnerable to HTTP Request Smuggling
What Should I Do?
Address in Next Maintenance Window
Low exploitation probability (1.90%). Schedule for your next planned update.
Does your project use an affected puma version?
Paste your Gemfile.lock to check it for CVE-2022-24790 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.
Summary
When using Puma behind a proxy that does not properly validate that the incoming HTTP request matches the RFC7230 standard, Puma and the frontend proxy may disagree on where a request starts and ends. This would allow requests to be smuggled via the front-end proxy to Puma.
The following vulnerabilities are addressed by this advisory:
- Lenient parsing of
Transfer-Encodingheaders, when unsupported encodings should be rejected and the final encoding must bechunked. - Lenient parsing of malformed
Content-Lengthheaders and chunk sizes, when only digits and hex digits should be allowed. - Lenient parsing of duplicate
Content-Lengthheaders, when they should be rejected. - Lenient parsing of the ending of chunked segments, when they should end with
\r\n.
The vulnerability has been fixed in 5.6.4 and 4.3.12. When deploying a proxy in front of Puma, turning on any and all functionality to make sure that the request matches the RFC7230 standard.
These proxy servers are known to have "good" behavior re: this standard and upgrading Puma may not be necessary. Users are encouraged to validate for themselves.
- Nginx (latest)
- Apache (latest)
- Haproxy 2.5+
- Caddy (latest)
- Traefik (latest)
Advisory Timeline
- First published March 30, 2022 (1702 days ago).
- Last revised February 16, 2024 — 687 days after initial publication.
Remediation
Upgrade to the fixed version using your package manager.
gem install puma -v 5.6.4
gem install puma -v 4.3.12
After upgrading, scan your dependencies again to confirm the vulnerability is resolved.
Affected Packages (2)
Affects 1 ecosystem: RubyGems (1).
Vulnerability Classification
Common Weakness Enumeration (CWE) identifiers for this vulnerability type.
- CWE-444
CVSS Score Breakdown
What the CVSS (Common Vulnerability Scoring System) 9.1 score means for each attack dimension.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
References
- https://github.com/puma/puma/security/advisories/GHSA-h99w-9q5r-gjq9WEB
- https://nvd.nist.gov/vuln/detail/CVE-2022-24790ADVISORY
- https://github.com/puma/puma/commit/5bb7d202e24dec00a898dca4aa11db391d7787a5WEB
- https://github.com/puma/pumaPACKAGE
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/puma/CVE-2022-24790.ymlWEB
- https://lists.debian.org/debian-lts-announce/2022/08/msg00015.htmlWEB
- https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/F6YWGIIKL7KKTS3ZOAYMYPC7D6WQ5OA5WEB
- https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/L7NESIBFCNSR3XH7LXDPKVMSUBNUB43GWEB
- https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/TUBFJ44NCKJ34LECZRAP4N5VL6USJSIBWEB
- https://portswigger.net/web-security/request-smugglingWEB
- https://security.gentoo.org/glsa/202208-28WEB
- https://www.debian.org/security/2022/dsa-5146WEB
Frequently Asked Questions
- What is CVE-2022-24790?
- Puma vulnerable to HTTP Request Smuggling. This vulnerability has been assigned a severity rating of CRITICAL (CVSS score: 9.1/10).
- How do I check if my project is affected by CVE-2022-24790?
- CVE-2022-24790 affects puma. It has a 1.9% probability of exploitation within 30 days (EPSS score). Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2022-24790 and 200,000+ other known vulnerabilities.
Severity & Exploitability
Maximum impact if exploited, often with little effort or access required.
This places it in the top quartile of EPSS-scored vulnerabilities — 80.2% of tracked vulnerabilities score at or below it, so it is more likely to be exploited than most of the tracked corpus.
Also Known As
Related CVEs
- CVE-2023-40175CRITICAL
Puma HTTP Request/Response Smuggling vulnerability
- CVE-2026-47737HIGH
Puma PROXY Protocol v1 Accepts Repeated Protocol Headers on Persistent Connections
- CVE-2021-29509HIGH
Puma's Keepalive Connections Causing Denial Of Service
- CVE-2026-47736HIGH
Puma PROXY Protocol v1 Parser Allows Remote Memory Exhaustion
- CVE-2020-5249MEDIUM
HTTP Response Splitting (Early Hints) in Puma
- CVE-2020-5247MEDIUM
HTTP Response Splitting in Puma
- CVE-2024-45614MEDIUM
Puma's header normalization allows for client to clobber proxy set headers
- CVE-2024-21647MEDIUM
Puma HTTP Request/Response Smuggling vulnerability