Classes | Defines | Functions
mlme.c File Reference
#include "includes.h"
#include "common.h"
#include "eloop.h"
#include "config_ssid.h"
#include "wpa_supplicant_i.h"
#include "notify.h"
#include "driver_i.h"
#include "rsn_supp/wpa.h"
#include "common/ieee802_11_defs.h"
#include "common/ieee802_11_common.h"
#include "mlme.h"
Include dependency graph for mlme.c:

Go to the source code of this file.

Classes

struct  ieee80211_sta_bss

Defines

#define IEEE80211_ASSOC_MAX_TRIES   3
#define IEEE80211_ASSOC_TIMEOUT   (200)
#define IEEE80211_AUTH_MAX_TRIES   3
#define IEEE80211_AUTH_TIMEOUT   (200)
#define IEEE80211_CHANNEL_TIME   (33)
#define IEEE80211_FC(type, stype)   host_to_le16((type << 2) | (stype << 4))
#define IEEE80211_IBSS_INACTIVITY_LIMIT   (60000)
#define IEEE80211_IBSS_JOIN_TIMEOUT   (20000)
#define IEEE80211_IBSS_MAX_STA_ENTRIES   128
#define IEEE80211_IBSS_MERGE_INTERVAL   (30000)
#define IEEE80211_MAX_SUPP_RATES   32
#define IEEE80211_MONITORING_INTERVAL   (2000)
#define IEEE80211_PASSIVE_CHANNEL_TIME   (200)
#define IEEE80211_PROBE_DELAY   (33)
#define IEEE80211_PROBE_INTERVAL   (60000)
#define IEEE80211_RETRY_AUTH_INTERVAL   (1000)
#define IEEE80211_SCAN_INTERVAL   (2000)
#define IEEE80211_SCAN_INTERVAL_SLOW   (15000)
#define IEEE80211_SCAN_RESULT_EXPIRE   (10000)

Functions

static void __ieee80211_bss_hash_add (struct wpa_supplicant *wpa_s, struct ieee80211_sta_bss *bss)
static void __ieee80211_bss_hash_del (struct wpa_supplicant *wpa_s, struct ieee80211_sta_bss *bss)
static void dump_tspec (struct wmm_tspec_element *tspec)
static int ecw2cw (int ecw)
static int ieee80211_active_scan (struct wpa_supplicant *wpa_s)
static void ieee80211_associate (struct wpa_supplicant *wpa_s)
static void ieee80211_associated (struct wpa_supplicant *wpa_s)
static void ieee80211_auth_challenge (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_auth_completed (struct wpa_supplicant *wpa_s)
static void ieee80211_authenticate (struct wpa_supplicant *wpa_s)
static struct ieee80211_sta_bssieee80211_bss_add (struct wpa_supplicant *wpa_s, const u8 *bssid)
static void ieee80211_bss_free (struct wpa_supplicant *wpa_s, struct ieee80211_sta_bss *bss)
static struct ieee80211_sta_bssieee80211_bss_get (struct wpa_supplicant *wpa_s, const u8 *bssid)
static void ieee80211_bss_info (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status, int beacon)
static void ieee80211_bss_list_deinit (struct wpa_supplicant *wpa_s)
static void ieee80211_build_tspec (struct wpabuf *buf)
static int ieee80211_ibss_allowed (struct wpa_supplicant *wpa_s)
static int ieee80211_privacy_mismatch (struct wpa_supplicant *wpa_s)
static void ieee80211_reschedule_timer (struct wpa_supplicant *wpa_s, int ms)
static void ieee80211_rx_addts_resp (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, size_t var_len)
static void ieee80211_rx_delts (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, size_t var_len)
static void ieee80211_rx_mgmt_action (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_rx_mgmt_assoc_resp (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status, int reassoc)
static void ieee80211_rx_mgmt_auth (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_rx_mgmt_beacon (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_rx_mgmt_deauth (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_rx_mgmt_disassoc (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_rx_mgmt_probe_req (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_rx_mgmt_probe_resp (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_rx_mgmt_wmm_action (struct wpa_supplicant *wpa_s, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_send_assoc (struct wpa_supplicant *wpa_s)
static void ieee80211_send_auth (struct wpa_supplicant *wpa_s, int transaction, const u8 *extra, size_t extra_len, int encrypt)
static void ieee80211_send_deauth (struct wpa_supplicant *wpa_s, u16 reason)
static void ieee80211_send_disassoc (struct wpa_supplicant *wpa_s, u16 reason)
static void ieee80211_send_probe_req (struct wpa_supplicant *wpa_s, const u8 *dst, const u8 *ssid, size_t ssid_len)
static void ieee80211_set_associated (struct wpa_supplicant *wpa_s, int assoc)
static int ieee80211_sta_active_ibss (struct wpa_supplicant *wpa_s)
int ieee80211_sta_associate (struct wpa_supplicant *wpa_s, struct wpa_driver_associate_params *params)
int ieee80211_sta_deauthenticate (struct wpa_supplicant *wpa_s, u16 reason)
void ieee80211_sta_deinit (struct wpa_supplicant *wpa_s)
int ieee80211_sta_disassociate (struct wpa_supplicant *wpa_s, u16 reason)
static void ieee80211_sta_expire (struct wpa_supplicant *wpa_s)
static int ieee80211_sta_find_ibss (struct wpa_supplicant *wpa_s)
void ieee80211_sta_free_hw_features (struct hostapd_hw_modes *hw_features, size_t num_hw_features)
struct wpa_scan_resultsieee80211_sta_get_scan_results (struct wpa_supplicant *wpa_s)
int ieee80211_sta_get_ssid (struct wpa_supplicant *wpa_s, u8 *ssid, size_t *len)
int ieee80211_sta_init (struct wpa_supplicant *wpa_s)
static int ieee80211_sta_join_ibss (struct wpa_supplicant *wpa_s, struct ieee80211_sta_bss *bss)
static void ieee80211_sta_merge_ibss (struct wpa_supplicant *wpa_s)
static void ieee80211_sta_new_auth (struct wpa_supplicant *wpa_s)
int ieee80211_sta_req_scan (struct wpa_supplicant *wpa_s, struct wpa_driver_scan_params *params)
static int ieee80211_sta_restore_oper_chan (struct wpa_supplicant *wpa_s)
void ieee80211_sta_rx (struct wpa_supplicant *wpa_s, const u8 *buf, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_sta_rx_mgmt (struct wpa_supplicant *wpa_s, const u8 *buf, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_sta_rx_scan (struct wpa_supplicant *wpa_s, const u8 *buf, size_t len, struct ieee80211_rx_status *rx_status)
static void ieee80211_sta_save_oper_chan (struct wpa_supplicant *wpa_s)
static void ieee80211_sta_scan_timer (void *eloop_ctx, void *timeout_ctx)
static int ieee80211_sta_set_channel (struct wpa_supplicant *wpa_s, enum hostapd_hw_mode phymode, int chan, int freq)
static int ieee80211_sta_set_probe_req_ie (struct wpa_supplicant *wpa_s, const u8 *ies, size_t ies_len)
static void ieee80211_sta_timer (void *eloop_ctx, void *timeout_ctx)
static int ieee80211_sta_tx (struct wpa_supplicant *wpa_s, const u8 *buf, size_t len)
static int ieee80211_sta_wep_configured (struct wpa_supplicant *wpa_s)
static void ieee80211_sta_wmm_params (struct wpa_supplicant *wpa_s, const u8 *wmm_param, size_t wmm_param_len)
static void ieee80211_tx_addts (struct wpa_supplicant *wpa_s)
static int is_wmm_tspec (const u8 *ie, size_t len)

Define Documentation

#define IEEE80211_ASSOC_MAX_TRIES   3

Definition at line 35 of file mlme.c.

#define IEEE80211_ASSOC_TIMEOUT   (200)

Definition at line 34 of file mlme.c.

#define IEEE80211_AUTH_MAX_TRIES   3

Definition at line 33 of file mlme.c.

#define IEEE80211_AUTH_TIMEOUT   (200)

Definition at line 32 of file mlme.c.

#define IEEE80211_CHANNEL_TIME   (33)

Definition at line 44 of file mlme.c.

#define IEEE80211_FC (   type,
  stype 
)    host_to_le16((type << 2) | (stype << 4))

Definition at line 53 of file mlme.c.

#define IEEE80211_IBSS_INACTIVITY_LIMIT   (60000)

Definition at line 48 of file mlme.c.

#define IEEE80211_IBSS_JOIN_TIMEOUT   (20000)

Definition at line 41 of file mlme.c.

Definition at line 50 of file mlme.c.

#define IEEE80211_IBSS_MERGE_INTERVAL   (30000)

Definition at line 47 of file mlme.c.

#define IEEE80211_MAX_SUPP_RATES   32

Definition at line 78 of file mlme.c.

#define IEEE80211_MONITORING_INTERVAL   (2000)

Definition at line 36 of file mlme.c.

#define IEEE80211_PASSIVE_CHANNEL_TIME   (200)

Definition at line 45 of file mlme.c.

#define IEEE80211_PROBE_DELAY   (33)

Definition at line 43 of file mlme.c.

#define IEEE80211_PROBE_INTERVAL   (60000)

Definition at line 37 of file mlme.c.

#define IEEE80211_RETRY_AUTH_INTERVAL   (1000)

Definition at line 38 of file mlme.c.

#define IEEE80211_SCAN_INTERVAL   (2000)

Definition at line 39 of file mlme.c.

#define IEEE80211_SCAN_INTERVAL_SLOW   (15000)

Definition at line 40 of file mlme.c.

#define IEEE80211_SCAN_RESULT_EXPIRE   (10000)

Definition at line 46 of file mlme.c.


Function Documentation

static void __ieee80211_bss_hash_add ( struct wpa_supplicant wpa_s,
struct ieee80211_sta_bss bss 
) [static]

Definition at line 1221 of file mlme.c.

static void __ieee80211_bss_hash_del ( struct wpa_supplicant wpa_s,
struct ieee80211_sta_bss bss 
) [static]

Definition at line 1230 of file mlme.c.

static void dump_tspec ( struct wmm_tspec_element tspec) [static]

Definition at line 1842 of file mlme.c.

static int ecw2cw ( int  ecw) [static]

Definition at line 123 of file mlme.c.

static int ieee80211_active_scan ( struct wpa_supplicant wpa_s) [static]

Definition at line 2671 of file mlme.c.

static void ieee80211_associate ( struct wpa_supplicant wpa_s) [static]

Definition at line 545 of file mlme.c.

static void ieee80211_associated ( struct wpa_supplicant wpa_s) [static]

Definition at line 570 of file mlme.c.

static void ieee80211_auth_challenge ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 723 of file mlme.c.

static void ieee80211_auth_completed ( struct wpa_supplicant wpa_s) [static]

Definition at line 715 of file mlme.c.

static void ieee80211_authenticate ( struct wpa_supplicant wpa_s) [static]

Definition at line 270 of file mlme.c.

static struct ieee80211_sta_bss* ieee80211_bss_add ( struct wpa_supplicant wpa_s,
const u8 *  bssid 
) [static, read]

Definition at line 1252 of file mlme.c.

static void ieee80211_bss_free ( struct wpa_supplicant wpa_s,
struct ieee80211_sta_bss bss 
) [static]

Definition at line 1284 of file mlme.c.

static struct ieee80211_sta_bss * ieee80211_bss_get ( struct wpa_supplicant wpa_s,
const u8 *  bssid 
) [static, read]

Definition at line 1270 of file mlme.c.

static void ieee80211_bss_info ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status,
int  beacon 
) [static]

Definition at line 1311 of file mlme.c.

static void ieee80211_bss_list_deinit ( struct wpa_supplicant wpa_s) [static]

Definition at line 1297 of file mlme.c.

static void ieee80211_build_tspec ( struct wpabuf buf) [static]

Definition at line 999 of file mlme.c.

static int ieee80211_ibss_allowed ( struct wpa_supplicant wpa_s) [static]

Definition at line 2194 of file mlme.c.

static int ieee80211_privacy_mismatch ( struct wpa_supplicant wpa_s) [static]

Definition at line 524 of file mlme.c.

static void ieee80211_reschedule_timer ( struct wpa_supplicant wpa_s,
int  ms 
) [static]

Definition at line 262 of file mlme.c.

static void ieee80211_rx_addts_resp ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
size_t  var_len 
) [static]

Definition at line 1888 of file mlme.c.

static void ieee80211_rx_delts ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
size_t  var_len 
) [static]

Definition at line 1905 of file mlme.c.

static void ieee80211_rx_mgmt_action ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 1955 of file mlme.c.

static void ieee80211_rx_mgmt_assoc_resp ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status,
int  reassoc 
) [static]

Definition at line 1059 of file mlme.c.

static void ieee80211_rx_mgmt_auth ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 748 of file mlme.c.

static void ieee80211_rx_mgmt_beacon ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 1591 of file mlme.c.

static void ieee80211_rx_mgmt_deauth ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 916 of file mlme.c.

static void ieee80211_rx_mgmt_disassoc ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 959 of file mlme.c.

static void ieee80211_rx_mgmt_probe_req ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 1637 of file mlme.c.

static void ieee80211_rx_mgmt_probe_resp ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 1582 of file mlme.c.

static void ieee80211_rx_mgmt_wmm_action ( struct wpa_supplicant wpa_s,
struct ieee80211_mgmt mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 1922 of file mlme.c.

static void ieee80211_send_assoc ( struct wpa_supplicant wpa_s) [static]

Definition at line 316 of file mlme.c.

static void ieee80211_send_auth ( struct wpa_supplicant wpa_s,
int  transaction,
const u8 *  extra,
size_t  extra_len,
int  encrypt 
) [static]

Definition at line 223 of file mlme.c.

static void ieee80211_send_deauth ( struct wpa_supplicant wpa_s,
u16  reason 
) [static]

Definition at line 468 of file mlme.c.

static void ieee80211_send_disassoc ( struct wpa_supplicant wpa_s,
u16  reason 
) [static]

Definition at line 496 of file mlme.c.

static void ieee80211_send_probe_req ( struct wpa_supplicant wpa_s,
const u8 *  dst,
const u8 *  ssid,
size_t  ssid_len 
) [static]

Definition at line 631 of file mlme.c.

static void ieee80211_set_associated ( struct wpa_supplicant wpa_s,
int  assoc 
) [static]

Definition at line 191 of file mlme.c.

static int ieee80211_sta_active_ibss ( struct wpa_supplicant wpa_s) [static]

Definition at line 2068 of file mlme.c.

int ieee80211_sta_associate ( struct wpa_supplicant wpa_s,
struct wpa_driver_associate_params params 
)

Definition at line 2556 of file mlme.c.

int ieee80211_sta_deauthenticate ( struct wpa_supplicant wpa_s,
u16  reason 
)

Definition at line 2969 of file mlme.c.

void ieee80211_sta_deinit ( struct wpa_supplicant wpa_s)

Definition at line 3074 of file mlme.c.

int ieee80211_sta_disassociate ( struct wpa_supplicant wpa_s,
u16  reason 
)

Definition at line 2979 of file mlme.c.

static void ieee80211_sta_expire ( struct wpa_supplicant wpa_s) [static]

Definition at line 2088 of file mlme.c.

static int ieee80211_sta_find_ibss ( struct wpa_supplicant wpa_s) [static]

Definition at line 2456 of file mlme.c.

void ieee80211_sta_free_hw_features ( struct hostapd_hw_modes hw_features,
size_t  num_hw_features 
)

Definition at line 3033 of file mlme.c.

Definition at line 2879 of file mlme.c.

int ieee80211_sta_get_ssid ( struct wpa_supplicant wpa_s,
u8 *  ssid,
size_t *  len 
)

Definition at line 2547 of file mlme.c.

int ieee80211_sta_init ( struct wpa_supplicant wpa_s)

Definition at line 3050 of file mlme.c.

static int ieee80211_sta_join_ibss ( struct wpa_supplicant wpa_s,
struct ieee80211_sta_bss bss 
) [static]

Definition at line 2219 of file mlme.c.

static void ieee80211_sta_merge_ibss ( struct wpa_supplicant wpa_s) [static]

Definition at line 2104 of file mlme.c.

static void ieee80211_sta_new_auth ( struct wpa_supplicant wpa_s) [static]

Definition at line 2162 of file mlme.c.

int ieee80211_sta_req_scan ( struct wpa_supplicant wpa_s,
struct wpa_driver_scan_params params 
)

Definition at line 2808 of file mlme.c.

static int ieee80211_sta_restore_oper_chan ( struct wpa_supplicant wpa_s) [static]

Definition at line 2658 of file mlme.c.

void ieee80211_sta_rx ( struct wpa_supplicant wpa_s,
const u8 *  buf,
size_t  len,
struct ieee80211_rx_status rx_status 
)

Definition at line 2992 of file mlme.c.

static void ieee80211_sta_rx_mgmt ( struct wpa_supplicant wpa_s,
const u8 *  buf,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 1995 of file mlme.c.

static void ieee80211_sta_rx_scan ( struct wpa_supplicant wpa_s,
const u8 *  buf,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 2044 of file mlme.c.

static void ieee80211_sta_save_oper_chan ( struct wpa_supplicant wpa_s) [static]

Definition at line 2650 of file mlme.c.

static void ieee80211_sta_scan_timer ( void *  eloop_ctx,
void *  timeout_ctx 
) [static]

Definition at line 2695 of file mlme.c.

static int ieee80211_sta_set_channel ( struct wpa_supplicant wpa_s,
enum hostapd_hw_mode  phymode,
int  chan,
int  freq 
) [static]

Definition at line 103 of file mlme.c.

static int ieee80211_sta_set_probe_req_ie ( struct wpa_supplicant wpa_s,
const u8 *  ies,
size_t  ies_len 
) [static]

Definition at line 3180 of file mlme.c.

static void ieee80211_sta_timer ( void *  eloop_ctx,
void *  timeout_ctx 
) [static]

Definition at line 2124 of file mlme.c.

static int ieee80211_sta_tx ( struct wpa_supplicant wpa_s,
const u8 *  buf,
size_t  len 
) [static]

Definition at line 216 of file mlme.c.

static int ieee80211_sta_wep_configured ( struct wpa_supplicant wpa_s) [static]

Definition at line 702 of file mlme.c.

static void ieee80211_sta_wmm_params ( struct wpa_supplicant wpa_s,
const u8 *  wmm_param,
size_t  wmm_param_len 
) [static]

Definition at line 134 of file mlme.c.

static void ieee80211_tx_addts ( struct wpa_supplicant wpa_s) [static]

Definition at line 1027 of file mlme.c.

static int is_wmm_tspec ( const u8 *  ie,
size_t  len 
) [static]

Definition at line 1869 of file mlme.c.



wpa_supplicant
Author(s): Package maintained by Blaise Gassend
autogenerated on Thu Apr 24 2014 15:34:38