Multiple Transfer-Encoding headers misinterprets request payload
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- High
- Impact type
- —
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · NVD. Fix status from CNA and GitHub.
Summary
hyper is an open-source HTTP library for Rust (crates.io). In hyper from version 0.12.0 and before versions 0.13.10 and 0.14.3 there is a vulnerability that can enable a request smuggling attack. The HTTP server code had a flaw that incorrectly understands some requests with multiple transfer-encoding headers to have a chunked payload, when it should have been rejected as illegal. This combined with an upstream HTTP proxy that understands the request payload boundary differently can result in "request smuggling" or "desync attacks". To determine if vulnerable, all these things must be true: 1) Using hyper as an HTTP server (the client is not affected), 2) Using HTTP/1.1 (HTTP/2 does not use transfer-encoding), 3) Using a vulnerable HTTP proxy upstream to hyper. If an upstream proxy correctly rejects the illegal transfer-encoding headers, the desync attack cannot succeed. If there is no proxy upstream of hyper, hyper cannot start the desync attack, as the client will repair the headers before forwarding. This is fixed in versions 0.14.3 and 0.13.10. As a workaround one can take the following options: 1) Reject requests that contain a `transfer-encoding` header, 2) Ensure any upstream proxy handles `transfer-encoding` correctly.
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 |
|---|---|---|---|---|---|
| hyperium | hyper | before 0.13.10; 0.14.0 to before 0.14.3 | 0.13.10, 0.14.3 | Patch available | CNA |
| — | hyper (crates.io) | 0.14.0 to before 0.14.3 | 0.14.3 | Patch available | GHSA-6hfq-h8hq-87mf |
| — | hyper (crates.io) | 0.13.0 to before 0.13.10 | 0.13.10 | Patch available | GHSA-6hfq-h8hq-87mf |
| — | hyper (crates.io) | 0.12.0 to before 0.12.36 | 0.12.36 | Patch available | GHSA-6hfq-h8hq-87mf |
- hyper Vendorhyperium Affected before 0.13.10; 0.14.0 to before 0.14.3 Fixed in 0.13.10, 0.14.3 Patch available CNA
- hyper (crates.io) Vendor— Affected 0.14.0 to before 0.14.3 Fixed in 0.14.3 Patch available GHSA-6hfq-h8hq-87mf
- hyper (crates.io) Vendor— Affected 0.13.0 to before 0.13.10 Fixed in 0.13.10 Patch available GHSA-6hfq-h8hq-87mf
- hyper (crates.io) Vendor— Affected 0.12.0 to before 0.12.36 Fixed in 0.12.36 Patch available GHSA-6hfq-h8hq-87mf
Remediation
- Fix · CNA hyper (hyperium) Fixed in 0.13.10, 0.14.3
- Fix · GHSA-6hfq-h8hq-87mf hyper (crates.io) Fixed in 0.14.3 Advisory →
- Fix · GHSA-6hfq-h8hq-87mf hyper (crates.io) Fixed in 0.13.10 Advisory →
- Fix · GHSA-6hfq-h8hq-87mf hyper (crates.io) Fixed in 0.12.36 Advisory →
Vendor assessments
Timeline
- 2026-10-02 Threatist record created from CVE-2021-21299
- 2026-10-03 Alias added: GHSA-6hfq-h8hq-87mf
References
Advisory 5
More hyperium Hyper vulnerabilities
- TI-2023-11846 An issue was discovered in hyper v0.13.7. CVSS 3.1HIGH 7.5
- TI-2022-13369 Hyperium Hyper before 0.14.19 does not allow for customization of the… CVSS 3.1HIGH 7.5
- TI-2020-18306 An issue was discovered in the hyper crate before 0.12.34 for Rust. CVSS 3.1CRITICAL 9.8
- TI-2021-12382 Integer Overflow in Chunked Transfer-Encoding CVSS 3.1CRITICAL 9.1
- TI-2021-12383 Lenient Parsing of Content-Length Header When Prefixed with Plus Sign CVSS 3.1MEDIUM 5.3
- TI-2017-13760 An issue was discovered in the hyper crate before 0.9.18 for Rust. CVSS 3.0MEDIUM 5.3
Sources
- CVE-2021-21299 · CVE Program
- CVE-2021-21299 · NVD
- FIRST EPSS
- GHSA-6hfq-h8hq-87mf · GitHub Advisory Database · CC BY 4.0
- CVE-2021-21299 · 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