CVE-2026-87018
Description
undici is an HTTP client library for Node.js. In versions 4.2.1 through 6.29.0, 7.0.0 through 7.30.0, and 8.0.0 through 8.12.1, the client process crashes when a TLS 1.2 server renegotiates after the connection is established and presents a different, CA-trusted certificate whose hostname does not match the requested host. Node.js re-runs hostname verification on the renegotiated handshake and destroys the socket with a certificate-altname error, but undici's established-socket error handler asserted that this error code could never occur, so the peer-controlled error became an uncaught assertion that terminates the Node.js process, affecting both the HTTP/1.1 and HTTP/2 paths. A malicious or compromised HTTPS endpoint reached through undici or the global fetch() can crash the client with a single server-initiated renegotiation, taking down all in-flight requests and background work in the process, and exploitation needs no CA compromise because the attacker controls the endpoint and can present two ordinary valid certificates. Only TLS 1.2 is affected, since TLS 1.3 does not support renegotiation. The issue is fixed in undici 6.29.1, 7.30.1, and 8.12.2, and users should upgrade to one of those versions or later. As a workaround, restrict outbound connections to TLS 1.3 so renegotiation cannot occur, when the target endpoints support it.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
undicinpm | >= 4.2.1, < 6.29.1 | 6.29.1 |
undicinpm | >= 7.0.0, < 7.30.1 | 7.30.1 |
undicinpm | >= 8.0.0, < 8.12.2 | 8.12.2 |
Affected products
28- osv-coords25 versionspkg:rpm/almalinux/nodejspkg:rpm/almalinux/nodejs-develpkg:rpm/almalinux/nodejs-docspkg:rpm/almalinux/nodejs-full-i18npkg:rpm/almalinux/nodejs-libspkg:rpm/almalinux/nodejs-nodemonpkg:rpm/almalinux/nodejs-npmpkg:rpm/almalinux/nodejs-packagingpkg:rpm/almalinux/nodejs-packaging-bundlerpkg:rpm/almalinux/nodejs24pkg:rpm/almalinux/nodejs24-develpkg:rpm/almalinux/nodejs24-docspkg:rpm/almalinux/nodejs24-full-i18npkg:rpm/almalinux/nodejs24-libspkg:rpm/almalinux/nodejs24-npmpkg:rpm/almalinux/nodejs26pkg:rpm/almalinux/nodejs26-develpkg:rpm/almalinux/nodejs26-docspkg:rpm/almalinux/nodejs26-full-i18npkg:rpm/almalinux/nodejs26-libspkg:rpm/almalinux/nodejs26-npmpkg:rpm/almalinux/npmpkg:rpm/almalinux/v8-12.4-develpkg:rpm/almalinux/v8-13.6-develpkg:rpm/opensuse/pi-coding-agent&distro=openSUSE%20Tumbleweed
< 1:24.22.1-2.module_el8.10.0+4355+47fd9055+ 24 more
- (no CPE)range: < 1:24.22.1-2.module_el8.10.0+4355+47fd9055
- (no CPE)range: < 1:24.22.1-2.module_el8.10.0+4355+47fd9055
- (no CPE)range: < 1:22.23.4-1.el10_2
- (no CPE)range: < 1:24.22.1-2.module_el8.10.0+4355+47fd9055
- (no CPE)range: < 1:24.22.1-2.module_el8.10.0+4355+47fd9055
- (no CPE)range: < 3.1.14-6.module_el9.8.0+339+e26173b4
- (no CPE)range: < 1:10.9.9-1.22.23.4.1.el10_2
- (no CPE)range: < 2021.06-6.module_el9.7.0+209+ecf6523e
- (no CPE)range: < 2021.06-6.module_el9.7.0+209+ecf6523e
- (no CPE)range: < 1:24.22.1-3.el10_2
- (no CPE)range: < 1:24.22.1-3.el10_2
- (no CPE)range: < 1:24.22.1-3.el10_2
- (no CPE)range: < 1:24.22.1-3.el10_2
- (no CPE)range: < 1:24.22.1-3.el10_2
- (no CPE)range: < 2:11.19.1-1.24.22.1.3.el10_2
- (no CPE)range: < 1:26.12.1-3.el10_3
- (no CPE)range: < 1:26.12.1-3.el10_3
- (no CPE)range: < 1:26.12.1-3.el10_3
- (no CPE)range: < 1:26.12.1-3.el10_3
- (no CPE)range: < 1:26.12.1-3.el10_3
- (no CPE)range: < 1:11.20.0-1.26.12.1.3.el10_3
- (no CPE)range: < 1:11.19.1-1.24.22.1.2.module_el8.10.0+4355+47fd9055
- (no CPE)range: < 3:12.4.254.21-1.22.23.4.2.module_el8.10.0+4358+709b81be
- (no CPE)range: < 3:13.6.233.17-1.24.22.1.2.module_el8.10.0+4355+47fd9055
- (no CPE)range: < 1.5.0-1.1
Patches
Vulnerability mechanics
References
10- cna.openjsf.org/security-advisories.htmlnvdVendor AdvisoryWEB
- github.com/advisories/GHSA-qrxm-fqhp-jwvmghsaADVISORY
- github.com/nodejs/undici/security/advisories/GHSA-qrxm-fqhp-jwvmnvdVendor AdvisoryWEB
- nvd.nist.gov/vuln/detail/CVE-2026-87018ghsaADVISORY
- github.com/nodejs/undici/commit/12cfd96c3f430897656e3edc1c5e02be8c1cd309ghsaWEB
- github.com/nodejs/undici/commit/b40fbfc0651703cf9fa9f6ced68b679f28d8bb28ghsaWEB
- github.com/nodejs/undici/commit/e257e9f8fb42eedd50727b9cf65e548c8925e4a8ghsaWEB
- github.com/nodejs/undici/releases/tag/v6.29.1ghsaWEB
- github.com/nodejs/undici/releases/tag/v7.30.1ghsaWEB
- github.com/nodejs/undici/releases/tag/v8.12.2ghsaWEB
News mentions
0No linked articles in our index yet.