diff options
author | Miss Skeleton (bot) <31488909+miss-islington@users.noreply.github.com> | 2020-10-19 22:39:50 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-19 22:39:50 (GMT) |
commit | 609a38a36f3006ee00eccc18b25e3b2d577a3e56 (patch) | |
tree | cc2dfe78b2e5e0b496d5c656a8f5023f9bad8ecc | |
parent | 6e998fad1c92aee9c8c23c5887a7023d76bdf6c2 (diff) | |
download | cpython-609a38a36f3006ee00eccc18b25e3b2d577a3e56.zip cpython-609a38a36f3006ee00eccc18b25e3b2d577a3e56.tar.gz cpython-609a38a36f3006ee00eccc18b25e3b2d577a3e56.tar.bz2 |
bpo-40901: Describe what "interface name" means on Windows (GH-20694)
(cherry picked from commit f85658a09878c658ae0e0590bfa30e4ce51c9a04)
Co-authored-by: Jakub Stasiak <jakub@stasiak.at>
-rw-r--r-- | Doc/library/socket.rst | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/Doc/library/socket.rst b/Doc/library/socket.rst index 9ab050e..5e496ca 100644 --- a/Doc/library/socket.rst +++ b/Doc/library/socket.rst @@ -1046,6 +1046,19 @@ The :mod:`socket` module also offers various network-related services: .. versionchanged:: 3.8 Windows support was added. + .. note:: + + On Windows network interfaces have different names in different contexts + (all names are examples): + + * UUID: ``{FB605B73-AAC2-49A6-9A2F-25416AEA0573}`` + * name: ``ethernet_32770`` + * friendly name: ``vEthernet (nat)`` + * description: ``Hyper-V Virtual Ethernet Adapter`` + + This function returns names of the second form from the list, ``ethernet_32770`` + in this example case. + .. function:: if_nametoindex(if_name) @@ -1060,6 +1073,9 @@ The :mod:`socket` module also offers various network-related services: .. versionchanged:: 3.8 Windows support was added. + .. seealso:: + "Interface name" is a name as documented in :func:`if_nameindex`. + .. function:: if_indextoname(if_index) @@ -1074,6 +1090,9 @@ The :mod:`socket` module also offers various network-related services: .. versionchanged:: 3.8 Windows support was added. + .. seealso:: + "Interface name" is a name as documented in :func:`if_nameindex`. + .. _socket-objects: |