Network device wrappers¶
Basic usage¶
Module contents¶
-
class
hwd.network.NetIface(dev)¶ Wrapper for
pyudev.Deviceobjects of ‘net’ subclass.-
ipv4addr¶ IPv4 address.
-
ipv4gateway¶ IPv4 default gateway.
-
ipv4netmask¶ IPv4 netmask.
-
ipv6addr¶ IPv6 address.
-
ipv6gateway¶ IPv6 default gateway.
-
ipv6netmask¶ IPv6 netmask.
-
is_connected¶ Whether there is carrier.
-
mac¶ NIC’s MAC address.
-
type¶ NIC type. Not all network devices have this value. For wireless devices this value is
'wlan', and for loopback devices, the value is'loop'. When the value is missing,'eth'is returned as most ethernet devices authors have encountered have this value missing.
-