CVE-2024-40642
The netty incubator codec.bhttp is a java language binary http parser. In affected versions the `BinaryHttpParser` class does not properly validate input values thus giving attackers almost complete control over the HTTP requests constructed from the parsed output. Attackers can abuse several issues individually to perform various injection attacks including HTTP request smuggling, desync attacks, HTTP header injections, request queue poisoning, caching attacks and Server Side Request Forgery (SSRF). Attacker could also combine several issues to create well-formed messages for other text-based protocols which may result in attacks beyond the HTTP protocol. The BinaryHttpParser class implements the readRequestHead method which performs most of the relevant parsing of the received request. The data structure prefixes values with a variable length integer value. The parsing code below first gets the lengths of the values from the prefixed variable length integer. After it has all of the lengths and calculates all of the indices, the parser casts the applicable slices of the ByteBuf to String. Finally, it passes these values into a new `DefaultBinaryHttpRequest` object where no further parsing or validation occurs. Method is partially validated while other values are not validated at all. Software that relies on netty to apply input validation for binary HTTP data may be vulnerable to various injection and protocol based attacks. This issue has been addressed in version 0.0.13.Final. Users are advised to upgrade. There are no known workarounds for this vulnerability.
EPSS 0.67% · 49.7th percentile
Risk Scores
Affected Products
| Vendor | Product | Versions |
|---|---|---|
| netty | netty-incubator-codec-ohttp | 0 |
| Maven | io.netty.incubator:netty-incubator-codec-bhttp | 0 |
| netty | netty-incubator-codec-ohttp | < 0.0.13.Final, 0 |
Timeline
- Jan 21, 1970 Security Advisory
- Jul 18, 2024 CVE Published
- Jul 19, 2024 EPSS Score
- Jul 19, 2024 PoC Published
- Aug 10, 2024 EPSS Score
- Sep 1, 2024 EPSS Score
- Sep 23, 2024 EPSS Score
- Oct 4, 2024 Coalition ESS Score
- Oct 15, 2024 EPSS Score
- Nov 6, 2024 EPSS Score
- Nov 28, 2024 EPSS Score
- Dec 21, 2024 EPSS Score
References
- https://www.ibm.com/support/pages/node/7183597 advisory
- https://github.com/netty/netty-incubator-codec-ohttp/security/advisories/GHSA-q8f2-hxq5-cp4h url
- https://github.com/netty/netty-incubator-codec-ohttp/commit/b687a0cf6ea1030232ea204d73bce82f2698e571 url
- https://www.ibm.com/support/pages/node/7183612 advisory
- https://nvd.nist.gov/vuln/detail/CVE-2024-40642 advisory
- https://github.com/netty/netty-incubator-codec-ohttp package
- https://www.ibm.com/support/pages/node/7183584 advisory