IP Helper Functions (Compact 2013)
3/26/2014
This section describes IP Helper functions
In This Section
Adapter Management Functions
- GetAdapterIndex
Obtains the index of an adapter, given its name.
- GetAdaptersAddresses
Retrieves the addresses associated with the adapters on the local device.
- GetPerAdapterInfo
Retrieves information about the adapter that corresponds to the specified interface.
- GetUniDirectionalAdapterInfo
Retrieves information about the unidirectional adapters installed on the local device.
Address Resolution Protocol Management Functions
- CreateIpNetEntry
Creates an Address Resolution Protocol (ARP) entry in the ARP table on the local device.
- CreateProxyArpEntry
Creates a Proxy Address Resolution Protocol (PARP) entry on the local device for the specified IPv4 address.
- DeleteIpNetEntry
Deletes an ARP entry from the ARP table on the local device.
- DeleteProxyArpEntry
Deletes the PARP entry on the local device specified by the dwAddress and dwIfIndex parameters.
- FlushIpNetTable
Deletes all ARP entries for the specified interface from the ARP table on the local device.
- GetIpNetTable
Retrieves the IP-to-physical address mapping table.
- SendARP
Sends an ARP request to obtain the physical address that corresponds to the specified destination IPv4 address.
- SetIpNetEntry
Modifies an existing ARP entry in the ARP table on the local device.
Interface Conversion Functions
- ConvertInterfaceAliasToLuid
Converts an interface alias name for a network interface to the LUID for the interface.
- ConvertInterfaceGuidToLuid
Converts a GUID for a network interface to the LUID for the interface.
- ConvertInterfaceIndexToLuid
Converts a local index for a network interface to the LUID for the interface.
- ConvertInterfaceLuidToAlias
Converts a LUID for a network interface to an interface alias.
- ConvertInterfaceLuidToGuid
Converts a LUID for a network interface to a GUID for the interface.
- ConvertInterfaceLuidToIndex
Converts a LUID for a network interface to the local index for the interface.
- ConvertInterfaceLuidToNameA
Converts a LUID for a network interface to the ANSI interface name.
- ConvertInterfaceLuidToNameW
Converts a LUID for a network interface to the Unicode interface name.
- ConvertInterfaceNameToLuidA
Converts an ANSI network interface name to the LUID for the interface.
- ConvertInterfaceNameToLuidW
Converts a Unicode network interface name to the LUID for the interface.
- if_indextoname
Converts the local index for a network interface to the ANSI interface name.
- if_nametoindex
Converts the ANSI interface name for a network interface to the local index for the interface.
Interface Management Functions
- GetFriendlyIfIndex
Takes an interface index and returns a backward-compatible interface index, that is, an index that uses only the lower 24 bits.
- GetIfEntry
Retrieves information for the specified interface on the local device.
- GetIfEntry2
Retrieves information for the specified interface on the local device.
- GetIfStackTable
Retrieves a table of network interface stack row entries that specify the relationship of the network interfaces on an interface stack.
- GetIfTable
Retrieves the MIB-II interface table.
- GetIfTable2
Retrieves the MIB-II interface table.
- GetIfTable2Ex
Retrieves the MIB-II interface table.
- GetInterfaceInfo
Obtains the list of the network interface adapters with IPv4 enabled on the local system.
- GetInvertedIfStackTable
Retrieves a table of inverted network interface stack row entries that specify the relationship of the network interfaces on an interface stack.
- GetIpInterfaceEntry
Retrieves IP information for the specified interface on the local device.
- GetIpInterfaceTable
Retrieves the IP interface entries on the local device.
- GetNumberOfInterfaces
Retrieves the number of interfaces on the local device.
- InitializeIpInterfaceEntry
Initializes the members of an MIB_IPINTERFACE_ROW entry with default values.
- SetIfEntry
Sets the administrative status of an interface.
- SetIpInterfaceEntry
Sets the properties of an IP interface on the local device.
IP and Internet Control Message Protocol Functions
- GetIcmpStatistics
Retrieves the Internet Control Message Protocol (ICMP) statistics for the local device.
- GetIpStatistics
Retrieves the IP statistics for the current device.
- Icmp6CreateFile
Opens a handle on which IPv6 ICMP echo requests can be issued.
- Icmp6ParseReplies
Parses the reply buffer provided and returns an IPv6 ICMPv6 echo response reply if found.
- Icmp6SendEcho2
Sends an IPv6 ICMPv6 echo request and returns either immediately (if Event or ApcRoutine is non-NULL) or returns after the specified time-out.
- IcmpCloseHandle
This function closes a handle opened by a call to the IcmpCreateFile or Icmp6CreateFile functions.
- IcmpCreateFile
Opens a handle on which IPv4 ICMP echo requests can be issued.
- IcmpParseReplies
Parses the reply buffer provided and returns the number of ICMP echo request responses found.
- IcmpSendEcho
Sends an IPv4 ICMP echo request and returns any echo response replies The call returns when the time-out has expired or the reply buffer is filled.
- IcmpSendEcho2
Sends an IPv4 ICMP echo request and returns either immediately (if Event or ApcRoutine is non-NULL) or returns after the specified time-out.
- SetIpTTL
Sets the default Time to Live (TTL) value for the local device.
IP Address Management Functions
- AddIPAddress
Adds the specified IPv4 address to the specified adapter.
- CreateAnycastIpAddressEntry
Adds a new anycast IP address entry on the local device.
- CreateUnicastIpAddressEntry
Adds a new unicast IP address entry on the local device.
- DeleteIPAddress
Deletes an IP address previously added by using AddIPAddress.
- DeleteAnycastIpAddressEntry
Deletes an existing anycast IP address entry on the local device.
- DeleteUnicastIpAddressEntry
Deletes an existing unicast IP address entry on the local device.
- GetAnycastIpAddressEntry
Retrieves information for an existing anycast IP address entry on the local device.
- GetAnycastIpAddressTable
Retrieves the anycast IP address table on the local device.
- GetIpAddrTable
Retrieves the interface-to-IPv4 address mapping table.
- GetMulticastIpAddressEntry
Retrieves information for an existing multicast IP address entry on the local device.
- GetMulticastIpAddressTable
Retrieves the multicast IP address table on the local device.
- GetUnicastIpAddressEntry
Retrieves information for an existing unicast IP address entry on the local device.
- GetUnicastIpAddressTable
Retrieves the unicast IP address table on the local device.
- InitializeUnicastIpAddressEntry
Initializes a MIB_UNICASTIPADDRESS_ROW structure with default values for a unicast IP address entry on the local device.
- IpReleaseAddress
Releases an IPv4 address previously obtained through DHCP.
- IpRenewAddress
Renews a lease on an IPv4 address previously obtained through DHCP.
- NotifyStableUnicastIpAddressTable
Retrieves the stable unicast IP address table on a local device.
- SetUnicastIpAddressEntry
Sets the properties of an existing unicast IP address entry on the local device.
IP Neighbor Address Management Functions
- CreateIpNetEntry2
Creates a new neighbor IP address entry on the local device.
- DeleteIpNetEntry2
Deletes a neighbor IP address entry on the local device.
- FlushIpNetTable2
Flushes the IP neighbor table on the local device.
- GetIpNetEntry2
Retrieves information for a neighbor IP address entry on the local device.
- GetIpNetTable2
Retrieves the IP neighbor table on the local device.
- ResolveIpNetEntry2
Resolves the physical address for a neighbor IP address entry on the local device.
ResolveNeighbor
Deprecated.Resolves the physical address for a neighbor IP address entry on the local device.
- SetIpNetEntry2
Sets the physical address of an existing neighbor IP address entry on the local device.
IP Path Management Functions
- FlushIpPathTable
Flushes the IP path table on the local device.
- GetIpPathEntry
Retrieves information for an IP path entry on the local device.
- GetIpPathTable
Retrieves the IP path table on the local device.
IP Route Management Functions
- CreateIpForwardEntry
Creates a route in the local device's IPv4 routing table.
- CreateIpForwardEntry2
Creates a new IP route entry on the local device.
- DeleteIpForwardEntry
Deletes an existing route in the local device's IPv4 routing table
- DeleteIpForwardEntry2
Deletes an IP route entry on the local device.
- EnableRouter
Turns on IPv4 forwarding on the local device EnableRouter also increments a reference count that tracks the number of requests to enable IPv4 forwarding.
- GetBestInterface
Retrieves the index of the interface that has the best route to the specified IPv4 address.
- GetBestInterfaceEx
Retrieves the index of the interface that has the best route to the specified IPv4 or IPv6 address.
- GetBestRoute
Retrieves the best route to the specified destination IP address.
- GetBestRoute2
Retrieves the IP route entry on the local device for the best route to the specified destination IP address.
- GetIpForwardEntry2
Retrieves information for an IP route entry on the local device.
- GetIpForwardTable
Retrieves the IPv4 routing table.
- GetIpForwardTable2
Retrieves the IP route entries on the local device.
- GetRTTAndHopCount
Determines the round-trip time (RTT) and hop count to the specified destination.
- InitializeIpForwardEntry
Initializes a MIB_IPFORWARD_ROW2 structure with default values for an IP route entry on the local device.
- SetIpForwardEntry
Modifies an existing route in the local device's IPv4 routing table
- SetIpForwardEntry2
Sets the properties of an IP route entry on the local device.
- SetIpStatistics
Toggles IP forwarding on or off and sets the default Time to Live (TTL) value for the local device.
- SetIpStatisticsEx
Toggles IP forwarding on or off and sets the default Time to Live (TTL) value for the local device.
- UnenableRouter
This function decrements the reference count that tracks the number of requests to enable IPv4 forwarding.
IP Table Memory Management Functions
- FreeMibTable
This function frees the buffer allocated by the functions that return tables of network interfaces, addresses, and routes.
IP Utility Functions
- ConvertIpv4MaskToLength
Converts an IPv4 subnet mask to an IPv4 prefix length.
- ConvertLengthToIpv4Mask
Converts an IPv4 prefix length to an IPv4 subnet mask.
- CreateSortedAddressPairs
Takes a supplied list of potential IP destination addresses, pairs the destination addresses together with the host machine's local IP addresses, and sorts the pairs according to which address pair is best suited for communication between the two peers.
Network Configuration Functions
- GetNetworkParams
Retrieves network parameters for the local device.
Notification Functions
- CancelMibChangeNotify2
Deregisters for change notifications for IP interface changes, IP address changes, IP route changes, and requests to retrieve the stable Unicast IP address table.
- NotifyAddrChange
Causes a notification to be sent to the caller when a change occurs in the table that maps IPv4 addresses to interfaces.
- NotifyIpInterfaceChange
Registers to be notified for changes to all IP interfaces, IPv4 interfaces, or IPv6 interfaces on a local device.
- NotifyRouteChange
Causes a notification to be sent to the caller when a change occurs in the IPv4 routing table.
- NotifyRouteChange2
Registers to be notified for changes to IP route entries on a local device.
- NotifyUnicastIpAddressChange
Registers to be notified for changes to all unicast IP interfaces, unicast IPv4 addresses, or unicast IPv6 addresses on a local device.
TCP and UDP
- GetExtendedTcpTable
Retrieves a table that contains a list of TCP endpoints available to the application.
- GetExtendedUdpTable
Retrieves a table that contains a list of UDP endpoints available to the application.
- GetOwnerModuleFromTcp6Entry
Retrieves data about the module that issued the context bind for a specific IPv6 TCP endpoint in a MIB table row.
- GetOwnerModuleFromTcpEntry
Retrieves data about the module that issued the context bind for a specific IPv4 TCP endpoint in a MIB table row.
- GetOwnerModuleFromUdp6Entry
Retrieves data about the module that issued the context bind for a specific IPv6 UDP endpoint in a MIB table row.
- GetOwnerModuleFromUdpEntry
Retrieves data about the module that issued the context bind for a specific IPv4 UDP endpoint in a MIB table row.
- GetPerTcp6ConnectionEStats
Retrieves extended statistics for an IPv6 TCP connection.
- GetPerTcpConnectionEStats
Retrieves extended statistics for an IPv4 TCP connection.
- GetTcpStatistics
Retrieves the TCP statistics for the local device.
- GetTcpStatisticsEx
Retrieves the Transmission Control Protocol (TCP) statistics for the current device.
- GetTcp6Table
Retrieves the TCP connection table for IPv6.
- GetTcp6Table2
Retrieves the TCP connection table for IPv6.
- GetTcpTable
Retrieves the IPv4 TCP connection table.
- GetTcpTable2
Retrieves the IPv4 TCP connection table.
- SetPerTcp6ConnectionEStats
Sets a value in the read/write information for an IPv6 TCP connection.
- SetPerTcpConnectionEStats
Sets a value in the read/write information for an IPv4 TCP connection.
- SetTcpEntry
Sets the state of a TCP connection.
- GetUdp6Table
Retrieves the IPv6 UDP listener table.
- GetUdpStatistics
Retrieves the UDP statistics for the local device.
- GetUdpStatisticsEx
Retrieves the UDP statistics for the current device.
- GetUdpTable
Retrieves the IPv4 UDP listener table.
Deprecated APIs
Note
These functions are deprecated and not supported by Microsoft
- AllocateAndGetTcpExTableFromStack
Retrieves the TCP connection table and allocates memory from the local heap to store the table.
- AllocateAndGetUdpExTableFromStack
Retrieves the UDP connection table and allocates memory from the local heap to store the table.