undici up to 5.8.0 on Node.js Content-Type Header crlf injection

CVSS Meta Temp Score
CVSS is a standardized scoring system to determine possibilities of attacks. The Temp Score considers temporal factors like disclosure, exploit and countermeasures. The unique Meta Score calculates the average score of different sources to provide a normalized scoring system.
Current Exploit Price (≈)
Our analysts are monitoring exploit markets and are in contact with vulnerability brokers. The range indicates the observed or calculated exploit price to be seen on exploit markets. A good indicator to understand the monetary effort required for and the popularity of an attack.
CTI Interest Score
Our Cyber Threat Intelligence team is monitoring different web sites, mailing lists, exploit markets and social media networks. The CTI Interest Score identifies the interest of attackers and the security community for this specific vulnerability in real-time. A high score indicates an elevated risk to be targeted for this vulnerability.

A vulnerability, which was classified as critical, has been found in undici up to 5.8.0 on Node.js (JavaScript Library). Affected by this issue is an unknown part of the component Content-Type Header Handler. The manipulation with an unknown input leads to a crlf injection vulnerability. Using CWE to declare the problem leads to CWE-93. The product uses CRLF (carriage return line feeds) as a special element, e.g. to separate lines or records, but it does not neutralize or incorrectly neutralizes CRLF sequences from inputs. Impacted is confidentiality, integrity, and availability. CVE summarizes:

undici is an HTTP/1.1 client, written from scratch for Node.js.`=< undici@5.8.0` users are vulnerable to _CRLF Injection_ on headers when using unsanitized input as request headers, more specifically, inside the `content-type` header. Example: ``` import { request } from 'undici' const unsanitizedContentTypeInput = 'application/json\r\n\r\nGET /foo2 HTTP/1.1' await request('http://localhost:3000, { method: 'GET', headers: { 'content-type': unsanitizedContentTypeInput }, }) ``` The above snippet will perform two requests in a single `request` API call: 1) `http://localhost:3000/` 2) `http://localhost:3000/foo2` This issue was patched in Undici v5.8.1. Sanitize input when sending content-type headers using user input as a workaround.

The weakness was released 08/15/2022 as GHSA-f772-66g8-q5h3. The advisory is available at github.com. This vulnerability is handled as CVE-2022-35948 since 07/15/2022. The technical details are unknown and an exploit is not available.

Upgrading to version 5.8.1 eliminates this vulnerability. The upgrade is hosted for download at github.com. Applying the patch 66165d604fd0aee70a93ed5c44ad4cc2df395f80 is able to eliminate this problem. The bugfix is ready for download at github.com. The best possible mitigation is suggested to be patching the affected component.

Entries connected to this vulnerability are available at VDB-17900, VDB-163399, VDB-167198 and VDB-186831.






CPE 2.3info

CPE 2.2info


VulDB CVSS-B Score: 🔍
VulDB CVSS-BT Score: 🔍
VulDB Vector: 🔍
VulDB Reliability: 🔍


VulDB Meta Base Score: 5.8
VulDB Meta Temp Score: 5.7

VulDB Base Score: 5.0
VulDB Temp Score: 4.8
VulDB Vector: 🔍
VulDB Reliability: 🔍

NVD Base Score: 5.3
NVD Vector: 🔍

CNA Base Score: 7.1
CNA Vector (GitHub, Inc.): 🔍



VulDB Base Score: 🔍
VulDB Temp Score: 🔍
VulDB Reliability: 🔍


Class: Crlf injection
CWE: CWE-93 / CWE-74 / CWE-707

Local: No
Remote: Yes

Availability: 🔍
Status: Not defined

EPSS Score: 🔍
EPSS Percentile: 🔍

Price Prediction: 🔍
Current Price Estimation: 🔍


Threat Intelligenceinfo

Interest: 🔍
Active Actors: 🔍
Active APT Groups: 🔍


Recommended: Patch
Status: 🔍

0-Day Time: 🔍

Upgrade: undici 5.8.1
Patch: 66165d604fd0aee70a93ed5c44ad4cc2df395f80


07/15/2022 🔍
08/15/2022 +31 days 🔍
08/15/2022 +0 days 🔍
09/11/2022 +27 days 🔍


Advisory: GHSA-f772-66g8-q5h3
Status: Confirmed

CVE: CVE-2022-35948 (🔍)
See also: 🔍


Created: 08/15/2022 03:56 PM
Updated: 09/11/2022 02:39 PM
Changes: 08/15/2022 03:56 PM (55), 09/11/2022 02:39 PM (11)
Complete: 🔍
Cache ID: 44:34A:40


No comments yet. Languages: en.

Please log in to comment.

Do you need the next level of professionalism?

Upgrade your account now!