chore(deps): update dependency undici to v6 [security]#118
Open
renovate[bot] wants to merge 1 commit intomasterfrom
Open
chore(deps): update dependency undici to v6 [security]#118renovate[bot] wants to merge 1 commit intomasterfrom
renovate[bot] wants to merge 1 commit intomasterfrom
Conversation
540a481 to
4a6f885
Compare
4a6f885 to
7f896ed
Compare
ea7e285 to
6dd3cdd
Compare
6dd3cdd to
55f85cf
Compare
55f85cf to
ac3270f
Compare
ac3270f to
3b011ca
Compare
3b011ca to
a6c06f9
Compare
a6c06f9 to
8ec6896
Compare
8ec6896 to
014b48a
Compare
3452e50 to
832e122
Compare
832e122 to
6189d45
Compare
6189d45 to
13bbd6d
Compare
13bbd6d to
6ebc049
Compare
6ebc049 to
bdcd5e1
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
4.7.0→6.24.0undici before v5.8.0 vulnerable to CRLF injection in request headers
CVE-2022-31150 / GHSA-3cvr-822r-rqcc
More information
Details
Impact
It is possible to inject CRLF sequences into request headers in Undici.
The same applies to
pathandmethodPatches
Update to v5.8.0
Workarounds
Sanitize all HTTP headers from untrusted sources to eliminate
\r\n.References
https://hackerone.com/reports/409943
https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-12116
For more information
If you have any questions or comments about this advisory:
Severity
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
undici before v5.8.0 vulnerable to uncleared cookies on cross-host / cross-origin redirect
CVE-2022-31151 / GHSA-q768-x9m6-m9qp
More information
Details
Impact
Authorization headers are already cleared on cross-origin redirect in
https://github.com/nodejs/undici/blob/main/lib/handler/redirect.js#L189, based on https://github.com/nodejs/undici/issues/872.
However, cookie headers which are sensitive headers and are official headers found in the spec, remain uncleared. There also has been active discussion of implementing a cookie store https://github.com/nodejs/undici/pull/1441, which suggests that there are active users using cookie headers in undici.
As such this may lead to accidental leakage of cookie to a 3rd-party site or a malicious attacker who can control the redirection target (ie. an open redirector) to leak the cookie to the 3rd party site.
Patches
This was patched in v5.8.0.
Workarounds
By default, this vulnerability is not exploitable.
Do not enable redirections, i.e.
maxRedirections: 0(the default).References
https://hackerone.com/reports/1635514
https://curl.se/docs/CVE-2018-1000007.html
https://curl.se/docs/CVE-2022-27776.html
For more information
If you have any questions or comments about this advisory:
Severity
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
undici.requestvulnerable to SSRF using absolute URL onpathnameCVE-2022-35949 / GHSA-8qr4-xgw6-wmr3
More information
Details
Impact
undiciis vulnerable to SSRF (Server-side Request Forgery) when an application takes in user input into thepath/pathnameoption ofundici.request.If a user specifies a URL such as
http://127.0.0.1or//127.0.0.1Instead of processing the request as
http://example.org//127.0.0.1(orhttp://example.org/http://127.0.0.1whenhttp://127.0.0.1 is used), it actually processes the request ashttp://127.0.0.1/and sends it tohttp://127.0.0.1.If a developer passes in user input into
pathparameter ofundici.request, it can result in an SSRF as they will assume that the hostname cannot change, when in actual fact it can change because the specified path parameter is combined with the base URL.Patches
This issue was fixed in
undici@5.8.1.Workarounds
The best workaround is to validate user input before passing it to the
undici.requestcall.For more information
If you have any questions or comments about this advisory:
Severity
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Nodejs ‘undici’ vulnerable to CRLF Injection via Content-Type
CVE-2022-35948 / GHSA-f772-66g8-q5h3
More information
Details
Impact
=< undici@5.8.0users are vulnerable to CRLF Injection on headers when using unsanitized input as request headers, more specifically, inside thecontent-typeheader.Example:
The above snippet will perform two requests in a single
requestAPI call:http://localhost:3000/http://localhost:3000/foo2Patches
This issue was patched in Undici v5.8.1
Workarounds
Sanitize input when sending content-type headers using user input.
For more information
If you have any questions or comments about this advisory:
Severity
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
CRLF Injection in Nodejs ‘undici’ via host
CVE-2023-23936 / GHSA-5r9g-qh6m-jxff
More information
Details
Impact
undici library does not protect
hostHTTP header from CRLF injection vulnerabilities.Patches
This issue was patched in Undici v5.19.1.
Workarounds
Sanitize the
headers.hoststring before passing to undici.References
Reported at https://hackerone.com/reports/1820955.
Credits
Thank you to Zhipeng Zhang (@timon8) for reporting this vulnerability.
Severity
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Undici's cookie header not cleared on cross-origin redirect in fetch
CVE-2023-45143 / GHSA-wqq4-5wpv-mx2g
More information
Details
Impact
Undici clears Authorization headers on cross-origin redirects, but does not clear
Cookieheaders. By design,cookieheaders are forbidden request headers, disallowing them to be set inRequestInit.headersin browser environments. Since Undici handles headers more liberally than the specification, there was a disconnect from the assumptions the spec made, and Undici's implementation of fetch.As such this may lead to accidental leakage of cookie to a 3rd-party site or a malicious attacker who can control the redirection target (ie. an open redirector) to leak the cookie to the 3rd party site.
Patches
This was patched in e041de359221ebeae04c469e8aff4145764e6d76, which is included in version 5.26.2.
Severity
CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:U/C:L/I:L/A:LReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Undici proxy-authorization header not cleared on cross-origin redirect in fetch
CVE-2024-24758 / GHSA-3787-6prv-h9w3
More information
Details
Impact
Undici already cleared Authorization headers on cross-origin redirects, but did not clear
Proxy-Authorizationheaders.Patches
This is patched in v5.28.3 and v6.6.1
Workarounds
There are no known workarounds.
References
Severity
CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:U/C:L/I:L/A:LReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Undici's fetch with integrity option is too lax when algorithm is specified but hash value is in incorrect
CVE-2024-30261 / GHSA-9qxr-qj54-h672
More information
Details
Impact
If an attacker can alter the
integrityoption passed tofetch(), they can letfetch()accept requests as valid even if they have been tampered.Patches
Fixed in nodejs/undici@d542b8c.
Fixes has been released in v5.28.4 and v6.11.1.
Workarounds
Ensure that
integritycannot be tampered with.References
https://hackerone.com/reports/2377760
Severity
CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:N/I:L/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Undici's Proxy-Authorization header not cleared on cross-origin redirect for dispatch, request, stream, pipeline
CVE-2024-30260 / GHSA-m4v8-wqvr-p9f7
More information
Details
Impact
Undici cleared Authorization and Proxy-Authorization headers for
fetch(), but did not clear them forundici.request().Patches
This has been patched in nodejs/undici@6805746.
Fixes has been released in v5.28.4 and v6.11.1.
Workarounds
use
fetch()or disablemaxRedirections.References
Linzi Shang reported this.
Severity
CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:U/C:L/I:L/A:LReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Use of Insufficiently Random Values in undici
CVE-2025-22150 / GHSA-c76h-2ccp-4975
More information
Details
Impact
Undici
fetch()uses Math.random() to choose the boundary for a multipart/form-data request. It is known that the output of Math.random() can be predicted if several of its generated values are known.If there is a mechanism in an app that sends multipart requests to an attacker-controlled website, they can use this to leak the necessary values. Therefore, An attacker can tamper with the requests going to the backend APIs if certain conditions are met.
Patches
This is fixed in 5.28.5; 6.21.1; 7.2.3.
Workarounds
Do not issue multipart requests to attacker controlled servers.
References
Severity
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
undici Denial of Service attack via bad certificate data
CVE-2025-47279 / GHSA-cxrh-j4jr-qwg3
More information
Details
Impact
Applications that use undici to implement a webhook-like system are vulnerable. If the attacker set up a server with an invalid certificate, and they can force the application to call the webhook repeatedly, then they can cause a memory leak.
Patches
This has been patched in https://github.com/nodejs/undici/pull/4088.
Workarounds
If a webhook fails, avoid keep calling it repeatedly.
References
Reported as: https://github.com/nodejs/undici/issues/3895
Severity
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:LReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Undici has an HTTP Request/Response Smuggling issue
CVE-2026-1525 / GHSA-2mjp-6q6p-2qxm
More information
Details
Impact
Undici allows duplicate HTTP
Content-Lengthheaders when they are provided in an array with case-variant names (e.g.,Content-Lengthandcontent-length). This produces malformed HTTP/1.1 requests with multiple conflictingContent-Lengthvalues on the wire.Who is impacted:
undici.request(),undici.Client, or similar low-level APIs with headers passed as flat arraysPotential consequences:
Content-Lengthheaders (400 Bad Request)Patches
Patched in the undici version v7.24.0 and v6.24.0. Users should upgrade to this version or later.
Workarounds
If upgrading is not immediately possible:
Content-Lengthheaders (case-insensitive) are present before passing headers to undici{ 'content-length': '123' }) rather than an array, which naturally deduplicates by keySeverity
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:LReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Undici has CRLF Injection in undici via
upgradeoptionCVE-2026-1527 / GHSA-4992-7rv2-5pvq
More information
Details
Impact
When an application passes user-controlled input to the
upgradeoption ofclient.request(), an attacker can inject CRLF sequences (\r\n) to:The vulnerability exists because undici writes the
upgradevalue directly to the socket without validating for invalid header characters:Patches
Patched in the undici version v7.24.0 and v6.24.0. Users should upgrade to this version or later.
Workarounds
Sanitize the
upgradeoption string before passing to undici:Severity
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Release Notes
nodejs/undici (undici)
v6.24.0Compare Source
Undici v6.24.0 Security Release Notes (LTS)
This release backports fixes for security vulnerabilities affecting the v6 line.
Upgrade guidance
All users on v6 should upgrade to v6.24.0 or later.
Fixed advisories
GHSA-2mjp-6q6p-2qxm / CVE-2026-1525 (Medium)
Inconsistent interpretation of HTTP requests (request/response smuggling class issue).
GHSA-f269-vfmq-vjvj / CVE-2026-1528 (High)
Malicious WebSocket 64-bit frame length handling could crash the client.
GHSA-4992-7rv2-5pvq / CVE-2026-1527 (Medium)
CRLF injection via the
upgradeoption.GHSA-v9p9-hfj2-hcw8 / CVE-2026-2229 (High)
Unhandled exception from invalid
server_max_window_bitsin WebSocket permessage-deflate negotiation.GHSA-vrm6-8vpv-qv8q / CVE-2026-1526 (High)
Unbounded memory consumption in WebSocket permessage-deflate decompression.
Not applicable to v6
>= 7.17.0 < 7.24.0only.Affected and patched ranges (v6)
< 6.24.0, patched6.24.0>= 6.0.0 < 6.24.0, patched6.24.0< 6.24.0, patched6.24.0< 6.24.0, patched6.24.0< 6.24.0, patched6.24.0References
v6.23.0Compare Source
Full Changelog: nodejs/undici@v6.22.0...v6.23.0
v6.22.0Compare Source
What's Changed
Full Changelog: nodejs/undici@v6.21.3...v6.22.0
v6.21.3Compare Source
What's Changed
Full Changelog: nodejs/undici@v6.21.2...v6.21.3
v6.21.2Compare Source
What's Changed
New Contributors
Full Changelog: nodejs/undici@v6.21.1...v6.21.2
v6.21.1Compare Source
Fixes CVE CVE-2025-22150 GHSA-c76h-2ccp-4975 (embargoed until 22-01-2025).
What's Changed
183f8e9to v6.x by @ggoodman in #3855Full Changelog: nodejs/undici@v6.21.0...v6.21.1
v6.21.0Compare Source
What's Changed
Full Changelog: nodejs/undici@v6.20.1...v6.21.0
v6.20.1Compare Source
What's Changed
BodyReadable.bytesby @github-actions in #3711Full Changelog: nodejs/undici@v6.20.0...v6.20.1
v6.20.0Compare Source
What's Changed
v6.xbranch) by @eXhumer in #3531Full Changelog: nodejs/undici@v6.19.8...v6.20.0
v6.19.8Compare Source
Full Changelog: nodejs/undici@v6.19.7...v6.19.8
v6.19.7Compare Source
Full Changelog: nodejs/undici@v6.19.6...v6.19.7
v6.19.6Compare Source
Full Changelog: nodejs/undici@v6.19.5...v6.19.6
v6.19.5Compare Source
Full Changelog: nodejs/undici@v6.19.4...v6.19.5
v6.19.4Compare Source
Full Changelog: nodejs/undici@v6.19.3...v6.19.4
v6.19.3Compare Source
Full Changelog: nodejs/undici@v6.19.2...v6.19.3
v6.19.2Compare Source
What's Changed
huskyashusky installis deprecated by @jazelly in #3340Full Changelog: nodejs/undici@v6.19.1...v6.19.2
v6.19.1Compare Source
What's Changed
Full Changelog: nodejs/undici@v6.19.0...v6.19.1
v6.19.0Compare Source
What's Changed
9e8f45ftodd7e693in /build by @dependabot in #3309dd7e693toe6d4495in /build by @dependabot in #3313e6d4495to075a5ccin /build by @dependabot in #3326bodyTimeoutin the request by @jakecastelli in #3324New Contributors
Full Changelog: nodejs/undici@v6.18.2...v6.19.0
v6.18.2Compare Source
What's Changed
Full Changelog: nodejs/undici@v6.18.1...v6.18.2
v6.18.1Compare Source
What's Changed
New Contributors
Full Changelog: nodejs/undici@v6.18.0...v6.18.1
v6.18.0Compare Source
What's Changed
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.