Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8216417

cleanup of IPv6 scope-id handling

    XMLWordPrintable

Details

    • b25
    • Verified

    Backports

      Description

        There is a lot of OS specific native code (mostly Linux) around determining which network interface to use when binding/connecting sockets to link-local (LL) IPv6 addresses.

        Most of this code can be removed such that:

        1. when binding/connecting to a local LL address, a common Java level implementation can check local link-local addresses and supply the scope-id automatically.

        2. when connecting to a non local LL address, we can just require the scope-id to be set explicitly, like most native applications. Link-local addresses can sometimes, but not always be determined from routing tables, but it is more reliable to require them to be set by the caller.

        This change affects NIO as well classic sockets and fixes a problem on macos where channels could not bind to local link-local addresses without the scope-id being set explicitly.

        Attachments

          Issue Links

            Activity

              People

                michaelm Michael McMahon
                alanb Alan Bateman
                Votes:
                0 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: