You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ProxyAgent fails with IP-address HTTPS proxies on Node 26 #6144
Using an HTTPS proxy addressed by an IP literal causes ProxyAgent to pass that IP as the TLS servername. Node 26 rejects this before the TLS handshake:
ERR_INVALID_ARG_VALUE: The property 'options.servername' Setting the TLS ServerName to an IP address is not permitted.. Received '127.0.0.1'
A running proxy is unnecessary to trigger the error: the invalid SNI value is rejected before connection establishment. If the port is closed, the expected failure would be a connection error such as ECONNREFUSED.
Expected Behavior
For an IP-address HTTPS proxy, omit SNI while continuing to verify the proxy certificate against its IP address. DNS-addressed proxies should retain their hostname as SNI.
Environment
Node.js: v26.12.1
Undici: 8.12.3
macOS, arm64
Additional context
ProxyAgent supplies the proxy hostname as servername, including when it is an IP address. In lib/core/connect.js, explicitly supplied values bypass util.getServerName():
Activity