Documentation
¶
Overview ¶
Package netutils provides network utility functions.
Index ¶
- func GenerateIfaceName(nlh nlwrap.Handle, prefix string, len int) (string, error)
- func GenerateMACFromIP(ip net.IP) net.HardwareAddr
- func GenerateRandomMAC() net.HardwareAddr
- func GenerateRandomName(prefix string, length int) (string, error)
- func InferReservedNetworks(v6 bool) []netip.Prefix
- func IsV6Listenable() bool
- func MustParseMAC(s string) net.HardwareAddr
- func ReverseIP(IP string) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateIfaceName ¶
GenerateIfaceName returns an interface name using the passed in prefix and the length of random bytes. The api ensures that the there are is no interface which exists with that name.