Expand description
Network interface detection, IP resolution, Wi-Fi, and related helpers.
Structs§
Functions§
- detect_
active_ interface_ and_ local_ ip - Detects the local IP address and active network interface name.
- detect_
dns - Returns the list of configured DNS nameserver addresses.
- detect_
domain - Returns the configured DNS domain name.
- detect_
domain_ search - Returns per-interface DNS search domain lists.
- detect_
networks - Builds the formatted list of network interfaces with IP addresses and RX/TX stats.
- detect_
public_ ip - Fetches the public IP address via an external service (best-effort, 2s timeout).
- detect_
wifi - Detects the connected Wi-Fi network and link parameters.
- format_
bytes - Formats a byte count into human-readable form (KB, MB, GB, etc.)
- lookup_
pci_ vendor - Looks up a PCI vendor name from
/usr/share/hwdata/pci.ids(or fallback paths). - parse_
domain_ from_ resolv_ conf - Parses the
domaindirective (or firstsearchentry as fallback) from/etc/resolv.confcontent. - parse_
iw_ link_ output - parse_
netsh_ output - parse_
proc_ net_ route - parse_
resolv_ conf - parse_
resolvectl_ search - Parses
resolvectl status --no-pageroutput into per-interface search domain strings. - parse_
search_ from_ resolv_ conf - Parses all entries from the
searchdirective in/etc/resolv.confcontent.