Manager for network card information gathering and state control.
More...
#include <net_card_manager.h>
Manager for network card information gathering and state control.
◆ ChannelModes
| Enumerator |
|---|
| NO_HT | |
| HT20 | |
| HT40MINUS | |
| HT40PLUS | |
| VHT80 | |
| VHT80P80 | |
| VHT160 | |
◆ FcsState
| Enumerator |
|---|
| FCS_ALL | |
| FCS_VALID | |
| FCS_INVALID | |
◆ NetCardManager()
| yarilo::NetCardManager::NetCardManager |
( |
| ) |
|
Basic constructor for logger initialisation
◆ ~NetCardManager()
| yarilo::NetCardManager::~NetCardManager |
( |
| ) |
|
|
inline |
◆ chan_to_freq()
| int yarilo::NetCardManager::chan_to_freq |
( |
int |
chan | ) |
|
|
static |
Get the frequency from a specific wifi channel
- Parameters
-
- Returns
- frequency
◆ connect()
| bool yarilo::NetCardManager::connect |
( |
| ) |
|
Connect to the nl80211 netlink socket
- Returns
- True if the connection succeeded, false otherwise
◆ disconnect()
| void yarilo::NetCardManager::disconnect |
( |
| ) |
|
Disconnect from the nl80211 netlink socket
◆ freq_to_chan()
| int yarilo::NetCardManager::freq_to_chan |
( |
int |
freq | ) |
|
|
static |
Get the channel from a specific frequency
- Parameters
-
- Returns
- wifi channel number
◆ net_iface_details()
| std::optional< iface_state > yarilo::NetCardManager::net_iface_details |
( |
const std::string & |
ifname | ) |
const |
Get the details for a particular logical interface. For details see iface_state
- Parameters
-
| [in] | ifname | Name of the logical interface (for example wlp1s0) |
- Returns
- Optionally return details of an interface
◆ net_interfaces()
| std::set< std::string > yarilo::NetCardManager::net_interfaces |
( |
| ) |
|
|
static |
Get available logical interfaces (for example wlp1s0)
- Returns
- Set of available network interfaces
◆ phy_details()
| std::optional< phy_info > yarilo::NetCardManager::phy_details |
( |
int |
phy_idx | ) |
const |
Get the details for a particular physical interface, like the available frequencies and monitor mode support. For details see phy_iface
- Parameters
-
| [in] | phy_idx | Index of the physical interface (for example 0 for phy0) |
- Returns
- Optionally return details of an interface
◆ phy_interfaces()
| std::set< std::string > yarilo::NetCardManager::phy_interfaces |
( |
| ) |
const |
Get available physical interfaces (for example phy0)
- Returns
- Set of available network interfaces
◆ set_phy_channel()
| bool yarilo::NetCardManager::set_phy_channel |
( |
int |
phy_idx, |
|
|
int |
chan |
|
) |
| const |
Set the physical focused channel of an interface, other programs can interfere with this setting, overriding it. It helps to have other programs like NetworkManager or wpa_supplicant disabled, or the phy excluded in their settings
- Parameters
-
| [in] | phy_idx | Index of the physical interface (for example 0 for phy0) |
| [in] | chan | target channel, supports only channels below 14 (2.4GHz band) |
- Returns
- True if the operation succeeded, false otherwise
The documentation for this class was generated from the following files: