Package netutil implements network-related utility functions.
DropPort drops all tcp packets that are received from the given port and sent to the given port.
GetDefaultHost obtains the first IP address of machine from the routing table and returns the IP address as string. An IPv4 address is preferred to an IPv6 address for backward compatibility.
GetDefaultInterfaces gets names of interfaces and returns a map[interface]families.
RecoverPort stops dropping tcp packets at given port.
RemoveLatency resets latency configurations.
SetLatency adds latency in millisecond scale with random variations.
URLStringsEqual returns "true" if given URLs are valid and resolved to same IP addresses. Otherwise, return "false" and error, if any.