#include <driver.h>
Data Fields | |
const char * | name |
const char * | desc |
int(* | get_bssid )(void *priv, u8 *bssid) |
Get the current BSSID. | |
int(* | get_ssid )(void *priv, u8 *ssid) |
Get the current SSID. | |
int(* | set_wpa )(void *priv, int enabled) |
Enable/disable WPA support (OBSOLETE). | |
int(* | set_key )(void *priv, wpa_alg alg, const u8 *addr, int key_idx, int set_tx, const u8 *seq, size_t seq_len, const u8 *key, size_t key_len) |
Configure encryption key. | |
void *(* | init )(void *ctx, const char *ifname) |
Initialize driver interface. | |
void(* | deinit )(void *priv) |
Deinitialize driver interface. | |
int(* | set_param )(void *priv, const char *param) |
Set driver configuration parameters. | |
int(* | set_countermeasures )(void *priv, int enabled) |
Enable/disable TKIP countermeasures. | |
int(* | set_drop_unencrypted )(void *priv, int enabled) |
Enable/disable unencrypted frame filtering. | |
int(* | scan )(void *priv, const u8 *ssid, size_t ssid_len) |
Request the driver to initiate scan. | |
int(* | get_scan_results )(void *priv, struct wpa_scan_result *results, size_t max_size) |
Fetch the latest scan results. | |
int(* | deauthenticate )(void *priv, const u8 *addr, int reason_code) |
Request driver to deauthenticate. | |
int(* | disassociate )(void *priv, const u8 *addr, int reason_code) |
Request driver to disassociate. | |
int(* | associate )(void *priv, struct wpa_driver_associate_params *params) |
Request driver to associate. | |
int(* | set_auth_alg )(void *priv, int auth_alg) |
Set IEEE 802.11 authentication algorithm. | |
int(* | add_pmkid )(void *priv, const u8 *bssid, const u8 *pmkid) |
Add PMKSA cache entry to the driver. | |
int(* | remove_pmkid )(void *priv, const u8 *bssid, const u8 *pmkid) |
Remove PMKSA cache entry to the driver. | |
int(* | flush_pmkid )(void *priv) |
Flush PMKSA cache. | |
int(* | get_capa )(void *priv, struct wpa_driver_capa *capa) |
Flush PMKSA cache. | |
void(* | poll )(void *priv) |
Poll driver for association information. | |
const char *(* | get_ifname )(void *priv) |
Get interface name. | |
const u8 *(* | get_mac_addr )(void *priv) |
Get own MAC address. | |
int(* | send_eapol )(void *priv, const u8 *dest, u16 proto, const u8 *data, size_t data_len) |
Optional function for sending EAPOL packets. |
This structure defines the API that each driver interface needs to implement for core wpa_supplicant code. All driver specific functionality is captured in this wrapper.
Definition at line 181 of file driver.h.
|
Add PMKSA cache entry to the driver.
If the driver generates RSN IE, i.e., it does not use wpa_ie in associate(), add_pmkid() can be used to add new PMKSA cache entries in the driver. If the driver uses wpa_ie from wpa_supplicant, this driver_ops function does not need to be implemented. Likewise, if the driver does not support WPA, this function is not needed. |
|
Request driver to associate.
|
|
Request driver to deauthenticate.
|
|
Deinitialize driver interface.
|
|
One line description of the driver interface |
|
Request driver to disassociate.
|
|
Flush PMKSA cache.
If the driver generates RSN IE, i.e., it does not use wpa_ie in associate(), remove_pmkid() can be used to synchronize PMKSA caches between the driver and wpa_supplicant. If the driver uses wpa_ie from wpa_supplicant, this driver_ops function does not need to be implemented. Likewise, if the driver does not support WPA, this function is not needed. |
|
Get the current BSSID.
|
|
Flush PMKSA cache.
|
|
Get interface name.
|
|
Get own MAC address.
|
|
Fetch the latest scan results.
|
|
Get the current SSID.
Note: SSID is an array of octets, i.e., it is not nul terminated and can, at least in theory, contain control characters (including nul) and as such, should be processed as binary data, not a printable string. |
|
Initialize driver interface.
See wpa_supplicant.h for more information about events and wpa_supplicant_event() function. |
|
Name of the driver interface |
|
Poll driver for association information.
|
|
Remove PMKSA cache entry to the driver.
If the driver generates RSN IE, i.e., it does not use wpa_ie in associate(), remove_pmkid() can be used to synchronize PMKSA caches between the driver and wpa_supplicant. If the driver uses wpa_ie from wpa_supplicant, this driver_ops function does not need to be implemented. Likewise, if the driver does not support WPA, this function is not needed. |
|
Request the driver to initiate scan.
|
|
Optional function for sending EAPOL packets.
|
|
Set IEEE 802.11 authentication algorithm.
|
|
Enable/disable TKIP countermeasures.
|
|
Enable/disable unencrypted frame filtering.
|
|
Configure encryption key.
Please note that TKIP keys include separate TX and RX MIC keys and some drivers may expect them in different order than wpa_supplicant is using. If the TX/RX keys are swapped, all TKIP encrypted packets will tricker Michael MIC errors. This can be fixed by changing the order of MIC keys by swapping te bytes 16..23 and 24..31 of the key in driver_*.c set_key() implementation, see driver_ndis.c for an example on how this can be done. |
|
Set driver configuration parameters.
|
|
Enable/disable WPA support (OBSOLETE).
Configure the kernel driver to enable/disable WPA support. This may be empty function, if WPA support is always enabled. Common configuration items are WPA IE (clearing it when WPA support is disabled), Privacy flag configuration for capability field (note: this the value need to set in associate handler to allow plaintext mode to be used) when trying to associate with, roaming mode (can allow wpa_supplicant to control roaming if ap_scan=1 is used; however, drivers can also implement roaming if desired, especially ap_scan=2 mode is used for this). |