Related Vulnerabilities: CVE-2022-31150  

undici is an HTTP/1.1 client, written from scratch for Node.js. It is possible to inject CRLF sequences into request headers in undici in versions less than 5.7.1. A fix was released in version 5.8.0. Sanitizing all HTTP headers from untrusted sources to eliminate `\r\n` is a workaround for this issue.

Description

The MITRE CVE dictionary describes this issue as:

undici is an HTTP/1.1 client, written from scratch for Node.js. It is possible to inject CRLF sequences into request headers in undici in versions less than 5.7.1. A fix was released in version 5.8.0. Sanitizing all HTTP headers from untrusted sources to eliminate `\r\n` is a workaround for this issue.

Additional Information

  • Bugzilla 2109354: CVE-2022-31150 nodejs16: CRLF injection in node-undici
  • CWE-93: Improper Neutralization of CRLF Sequences ('CRLF Injection')
  • FAQ: Frequently asked questions about CVE-2022-31150