wpa_supplicant / hostapd
2.5
|
wpa_supplicant - WPA2/RSN pre-authentication functions More...
Go to the source code of this file.
Functions | |
void | pmksa_candidate_free (struct wpa_sm *sm) |
Free all entries in PMKSA candidate list. More... | |
int | rsn_preauth_init (struct wpa_sm *sm, const u8 *dst, struct eap_peer_config *eap_conf) |
Start new RSN pre-authentication. More... | |
void | rsn_preauth_deinit (struct wpa_sm *sm) |
Abort RSN pre-authentication. More... | |
int | rsn_preauth_scan_results (struct wpa_sm *sm) |
Start processing scan results for canditates. More... | |
void | rsn_preauth_scan_result (struct wpa_sm *sm, const u8 *bssid, const u8 *ssid, const u8 *rsn) |
Processing scan result for PMKSA canditates. More... | |
void | pmksa_candidate_add (struct wpa_sm *sm, const u8 *bssid, int prio, int preauth) |
Add a new PMKSA candidate. More... | |
void | rsn_preauth_candidate_process (struct wpa_sm *sm) |
Process PMKSA candidates. More... | |
int | rsn_preauth_get_status (struct wpa_sm *sm, char *buf, size_t buflen, int verbose) |
Get pre-authentication status. More... | |
int | rsn_preauth_in_progress (struct wpa_sm *sm) |
Verify whether pre-authentication is in progress. More... | |
wpa_supplicant - WPA2/RSN pre-authentication functions
void pmksa_candidate_add | ( | struct wpa_sm * | sm, |
const u8 * | bssid, | ||
int | prio, | ||
int | preauth | ||
) |
Add a new PMKSA candidate.
sm | Pointer to WPA state machine data from wpa_sm_init() |
bssid | BSSID (authenticator address) of the candidate |
prio | Priority (the smaller number, the higher priority) |
preauth | Whether the candidate AP advertises support for pre-authentication |
This function is used to add PMKSA candidates for RSN pre-authentication. It is called from scan result processing and from driver events for PMKSA candidates, i.e., EVENT_PMKID_CANDIDATE events to wpa_supplicant_event().
void pmksa_candidate_free | ( | struct wpa_sm * | sm | ) |
Free all entries in PMKSA candidate list.
sm | Pointer to WPA state machine data from wpa_sm_init() |
void rsn_preauth_candidate_process | ( | struct wpa_sm * | sm | ) |
Process PMKSA candidates.
sm | Pointer to WPA state machine data from wpa_sm_init() |
Go through the PMKSA candidates and start pre-authentication if a candidate without an existing PMKSA cache entry is found. Processed candidates will be removed from the list.
void rsn_preauth_deinit | ( | struct wpa_sm * | sm | ) |
Abort RSN pre-authentication.
sm | Pointer to WPA state machine data from wpa_sm_init() |
This function aborts the current RSN pre-authentication (if one is started) and frees resources allocated for it.
int rsn_preauth_get_status | ( | struct wpa_sm * | sm, |
char * | buf, | ||
size_t | buflen, | ||
int | verbose | ||
) |
Get pre-authentication status.
sm | Pointer to WPA state machine data from wpa_sm_init() |
buf | Buffer for status information |
buflen | Maximum buffer length |
verbose | Whether to include verbose status information |
Query WPA2 pre-authentication for status information. This function fills in a text area with current status information. If the buffer (buf) is not large enough, status information will be truncated to fit the buffer.
int rsn_preauth_in_progress | ( | struct wpa_sm * | sm | ) |
Verify whether pre-authentication is in progress.
sm | Pointer to WPA state machine data from wpa_sm_init() |
int rsn_preauth_init | ( | struct wpa_sm * | sm, |
const u8 * | dst, | ||
struct eap_peer_config * | eap_conf | ||
) |
Start new RSN pre-authentication.
sm | Pointer to WPA state machine data from wpa_sm_init() |
dst | Authenticator address (BSSID) with which to preauthenticate |
eap_conf | Current EAP configuration |
This function request an RSN pre-authentication with a given destination address. This is usually called for PMKSA candidates found from scan results or from driver reports. In addition, ctrl_iface PREAUTH command can trigger pre-authentication.
void rsn_preauth_scan_result | ( | struct wpa_sm * | sm, |
const u8 * | bssid, | ||
const u8 * | ssid, | ||
const u8 * | rsn | ||
) |
Processing scan result for PMKSA canditates.
sm | Pointer to WPA state machine data from wpa_sm_init() |
Add all suitable APs (Authenticators) from scan results into PMKSA candidate list.
int rsn_preauth_scan_results | ( | struct wpa_sm * | sm | ) |
Start processing scan results for canditates.
sm | Pointer to WPA state machine data from wpa_sm_init() |
This functions is used to notify RSN code about start of new scan results processing. The actual scan results will be provided by calling rsn_preauth_scan_result() for each BSS if this function returned 0.