Description
A flaw in Node.js TLS hostname verification can cause a server certificate to be validated against a different IP address than the one the client connected to, when the host is a non-canonical IPv4 literal with a leading zero, such as `0127.0.0.1`.

`tls.checkServerIdentity()` normalizes the host following the WHATWG URL rules, which read a leading-zero octet as octal (`0127.0.0.1` becomes `87.0.0.1`), while the connection is made through the operating system resolver, which on some platforms such as macOS reads it as decimal (`127.0.0.1`). A server at the connected address can then be authenticated with a certificate issued for another IP address.

This vulnerability affects Node.js **26.x**, **24.x**, and **22.x**.
Published: 2026-10-23
Score: 7.4 High
EPSS: < 1% Very Low
KEV: No
Impact: Man-in-the-Middle / Authentication Bypass
Action: Patch
AI Analysis

Impact

Node.js TLS hostname verification logic incorrectly normalizes non‑canonical IPv4 literals that begin with a leading zero. When a client connects to an address such as 0127.0.0.1, the hostname is interpreted as octal by the TLS check, turning it into 87.0.0.1, while the operating system resolver treats the literal as decimal and connects to 127.0.0.1. The server’s certificate is then validated against the wrong IP, enabling an attacker to present a certificate issued for an unrelated address while the client believes it is authenticated. This flaw is a certificate trust validation weakness and an address parsing flaw (CWE‑295, CWE‑297) and permits a man‑in‑the‑middle or authentication‑bypass attack against any Node.js server that accepts such IP literals.

Affected Systems

Node.js JavaScript runtime versions 26.x, 24.x, and 22.x are affected. The vulnerability applies to any Node.js application using the default TLS hostname verification hooks, specifically the tls.checkServerIdentity() function.

Risk and Exploitability

The flaw carries a CVSS score of 7.4, indicating a high severity. Although no EPSS score is available, the potential to bypass certificate verification without local code execution makes the target attractive for attackers. The vulnerability is not listed in the CISA KEV catalog, but its impact is independent of platform; it can be triggered on any system that resolves lead‑zero IP literals as decimal, including macOS and potentially other operating systems with similar resolver behavior.

Generated by OpenCVE AI on October 24, 2026 at 01:50 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade to the latest Node.js release that contains the host name verification patch.
  • If an upgrade is not immediately possible, disable or replace the default tls.checkServerIdentity() callback with a custom implementation that performs strict decimal IPv4 resolution.
  • As a temporary measure, avoid using IPv4 literals with leading zeros in client connections; opt for quoted numeric names or fully qualified domain names that refer to the intended service.

Generated by OpenCVE AI on October 24, 2026 at 01:50 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Mon, 02 Nov 2026 14:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Sat, 24 Oct 2026 00:30:00 +0000

Type Values Removed Values Added
Title Node.js TLS Hostname Verification Mismatch for Leading-Zero IPv4 Addresses nodejs: nodejs: TLS certificate hostname bypass via non-canonical IP hostnames
Weaknesses CWE-297
References
Metrics threat_severity

None

cvssV3_1

{'score': 7.4, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N'}

threat_severity

Important


Fri, 23 Oct 2026 22:00:00 +0000

Type Values Removed Values Added
First Time appeared Nodejs
Nodejs nodejs
Vendors & Products Nodejs
Nodejs nodejs

Fri, 23 Oct 2026 18:00:00 +0000

Type Values Removed Values Added
Title Node.js TLS Hostname Verification Mismatch for Leading-Zero IPv4 Addresses

Fri, 23 Oct 2026 16:30:00 +0000

Type Values Removed Values Added
Description A flaw in Node.js TLS hostname verification can cause a server certificate to be validated against a different IP address than the one the client connected to, when the host is a non-canonical IPv4 literal with a leading zero, such as `0127.0.0.1`. `tls.checkServerIdentity()` normalizes the host following the WHATWG URL rules, which read a leading-zero octet as octal (`0127.0.0.1` becomes `87.0.0.1`), while the connection is made through the operating system resolver, which on some platforms such as macOS reads it as decimal (`127.0.0.1`). A server at the connected address can then be authenticated with a certificate issued for another IP address. This vulnerability affects Node.js **26.x**, **24.x**, and **22.x**.
Weaknesses CWE-295
References
Metrics cvssV3_0

{'score': 7.4, 'vector': 'CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: hackerone

Published:

Updated: 2026-11-02T13:31:52.012Z

Reserved: 2026-10-06T15:00:00.654Z

Link: CVE-2026-106069

cve-icon Vulnrichment

Updated: 2026-11-02T13:31:42.070Z

cve-icon NVD

Status : Awaiting Analysis

Published: 2026-10-23T17:17:19.740

Modified: 2026-11-02T14:17:34.950

Link: CVE-2026-106069

cve-icon Redhat

Severity : Important

Publid Date: 2026-10-21T00:00:00Z

Links: CVE-2026-106069 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-10-24T02:00:16Z

Weaknesses
  • CWE-295

    Improper Certificate Validation

  • CWE-297

    Improper Validation of Certificate with Host Mismatch