Netty vulnerable to HTTP Response splitting from assigning header value iterator
GHSA-hh82-3pmq-7frp · CVE-2022-41915
Published · Modified
AI SAST
Find this class of vulnerability in your own code
Corgea's AI-native static analysis detects vulnerabilities like this one across your repositories, ranks them by exploitability, and returns review-ready fixes.
Description
Impact
When calling DefaultHttpHeaders.set with an iterator of values (as opposed to a single given value), header value validation was not performed, allowing malicious header values in the iterator to perform HTTP Response Splitting.
Patches
The necessary validation was added in Netty 4.1.86.Final.
Workarounds
Integrators can work around the issue by changing the DefaultHttpHeaders.set(CharSequence, Iterator<?>) call, into a remove() call, and call add() in a loop over the iterator of values.
References
HTTP Response Splitting
CWE-113: Improper Neutralization of CRLF Sequences in HTTP Headers
For more information
If you have any questions or comments about this advisory:
- Open an issue in example link to repo
- Email us at netty-security@googlegroups.com
References
- WEB https://github.com/netty/netty/security/advisories/GHSA-hh82-3pmq-7frp
- ADVISORY https://nvd.nist.gov/vuln/detail/CVE-2022-41915
- WEB https://github.com/netty/netty/issues/13084
- WEB https://github.com/netty/netty/pull/12760
- WEB https://github.com/netty/netty/commit/c37c637f096e7be3dffd36edee3455c8e90cb1b0
- WEB https://github.com/netty/netty/commit/fe18adff1c2b333acb135ab779a3b9ba3295a1c4
- WEB https://github.com/netty/netty
- WEB https://lists.debian.org/debian-lts-announce/2023/01/msg00008.html
- WEB https://security.netapp.com/advisory/ntap-20230113-0004
- WEB https://www.debian.org/security/2023/dsa-5316
Ready to move
Start Securing
Free, no credit card | First findings in minutes