JDK-8303898 : Release Note: New Network Interface Names on Windows
  • Type: Sub-task
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 21
  • Priority: P4
  • Status: Resolved
  • Resolution: Delivered
  • OS: windows
  • Submitted: 2023-03-09
  • Updated: 2024-04-23
  • Resolved: 2023-03-15
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 21
21Resolved
Description
Maintainers of applications that do network multicasting or use the `java.net.NetworkInterface` API should note that the names that the JDK assigns to network interfaces on Windows have changed in this release. The JDK historically synthesized names for network interfaces on Windows. This has changed to use the names assigned by the Windows operating system. For example, the JDK may have historically assigned a name such as “eth0” for an ethernet interface and “lo” for the loopback. The equivalent names that Windows assigns may be names such as “ethernet_32768” and “loopback_0".

This change may impact code that does a lookup of network interfaces with the `NetworkInterace.getByName(String name)` method. It also may also be surprising to code that enumerates all network interfaces with the `NetworkInterfaces.networkInterfaces()` or `NetworkInterface.getNetworkInterfaces()` methods as the names of the network interfaces will look different to previous releases. Depending on configuration, it is possible that enumerating all network interfaces will enumerate network interfaces that weren’t previously enumerated because they didn’t have an Internet Protocol address assigned. The display name returned by `NetworkInterface::getDisplayName` has not changed so this should facilitate the identification of network interfaces when using Windows native tools.