|
| static size_t | getMTU (const std::string &interfaceName) noexcept |
| |
| static result< std::string > | getHostName () noexcept |
| |
| static result< std::vector< ip::address > > | getInterfaceIPs (const std::string &interfaceName, bool v6=false) noexcept |
| |
|
static result< int > | getSocketOutstandingBytes (int sockfd) noexcept |
| |
| static bool | isNonRoutable (const std::string &addr_str) noexcept |
| |
| static bool | isNonRoutable (const std::vector< std::string > &addrs) noexcept |
| |
◆ getHostName()
| result< std::string > e2sar::NetUtil::getHostName |
( |
| ) |
|
|
staticnoexcept |
Get the hostname of the host
◆ getInterfaceIPs()
| result< std::vector< ip::address > > e2sar::NetUtil::getInterfaceIPs |
( |
const std::string & | interfaceName, |
|
|
bool | v6 = false ) |
|
staticnoexcept |
get IPs of an interface (by name), either IPv4 or IPv6
◆ getMTU()
| size_t e2sar::NetUtil::getMTU |
( |
const std::string & | interfaceName | ) |
|
|
staticnoexcept |
Get MTU of a given interface
- Parameters
-
| interfaceName | - name of the interface |
- Returns
- MTU or 1500 as the best guess
Get MTU of a given interface. Used in constructors, so doesn't return error.
◆ isNonRoutable() [1/2]
| bool e2sar::NetUtil::isNonRoutable |
( |
const std::string & | addr_str | ) |
|
|
staticnoexcept |
Check if an IP address string is non-routable (private RFC1918, loopback, link-local, IPv6 ULA, or unspecified). Returns false on parse failure.
◆ isNonRoutable() [2/2]
| bool e2sar::NetUtil::isNonRoutable |
( |
const std::vector< std::string > & | addrs | ) |
|
|
staticnoexcept |
Check if any address in the vector is non-routable.
The documentation for this class was generated from the following files: