14 #include "common/defs.h" 15 #include "common/wpa_common.h" 20 #include "common/ieee802_11_defs.h" 23 #define WLAN_STA_AUTH BIT(0) 24 #define WLAN_STA_ASSOC BIT(1) 25 #define WLAN_STA_AUTHORIZED BIT(5) 26 #define WLAN_STA_PENDING_POLL BIT(6) 27 #define WLAN_STA_SHORT_PREAMBLE BIT(7) 28 #define WLAN_STA_PREAUTH BIT(8) 29 #define WLAN_STA_WMM BIT(9) 30 #define WLAN_STA_MFP BIT(10) 31 #define WLAN_STA_HT BIT(11) 32 #define WLAN_STA_WPS BIT(12) 33 #define WLAN_STA_MAYBE_WPS BIT(13) 34 #define WLAN_STA_WDS BIT(14) 35 #define WLAN_STA_ASSOC_REQ_OK BIT(15) 36 #define WLAN_STA_WPS2 BIT(16) 37 #define WLAN_STA_GAS BIT(17) 38 #define WLAN_STA_VHT BIT(18) 39 #define WLAN_STA_WNM_SLEEP_MODE BIT(19) 40 #define WLAN_STA_VHT_OPMODE_ENABLED BIT(20) 41 #define WLAN_STA_VENDOR_VHT BIT(21) 42 #define WLAN_STA_PENDING_FILS_ERP BIT(22) 43 #define WLAN_STA_PENDING_DISASSOC_CB BIT(29) 44 #define WLAN_STA_PENDING_DEAUTH_CB BIT(30) 45 #define WLAN_STA_NONERP BIT(31) 49 #define WLAN_SUPP_RATES_MAX 32 76 u8 supported_rates[WLAN_SUPP_RATES_MAX];
77 int supported_rates_len;
81 enum mesh_plink_state plink_state;
87 u8 my_nonce[WPA_NONCE_LEN];
88 u8 peer_nonce[WPA_NONCE_LEN];
90 u8 mtk[WPA_TK_MAX_LEN];
94 u8 mgtk[WPA_TK_MAX_LEN];
97 u8 igtk[WPA_TK_MAX_LEN];
103 unsigned int nonerp_set:1;
104 unsigned int no_short_slot_time_set:1;
105 unsigned int no_short_preamble_set:1;
106 unsigned int no_ht_gf_set:1;
107 unsigned int no_ht_set:1;
108 unsigned int ht40_intolerant_set:1;
109 unsigned int ht_20mhz_set:1;
110 unsigned int no_p2p_set:1;
111 unsigned int qos_map_enabled:1;
112 unsigned int remediation:1;
113 unsigned int hs20_deauth_requested:1;
114 unsigned int session_timeout_set:1;
115 unsigned int radius_das_match:1;
116 unsigned int ecsa_supported:1;
117 unsigned int added_unassoc:1;
118 unsigned int pending_wds_enable:1;
123 STA_NULLFUNC = 0, STA_DISASSOC, STA_DEAUTH, STA_REMOVE,
124 STA_DISASSOC_FROM_CLI
137 int acct_session_started;
138 int acct_terminate_cause;
139 int acct_interim_interval;
140 unsigned int acct_interim_errors;
143 u32 last_rx_bytes_hi;
144 u32 last_rx_bytes_lo;
145 u32 last_tx_bytes_hi;
146 u32 last_tx_bytes_lo;
151 struct rsn_preauth_interface *preauth_iface;
166 #ifdef CONFIG_IEEE80211W 169 int sa_query_timed_out;
170 u8 *sa_query_trans_id;
176 #ifdef CONFIG_INTERWORKING 177 #define GAS_DIALOG_MAX 8 185 u8 remediation_method;
186 char *remediation_url;
187 struct wpabuf *hs20_deauth_req;
188 char *hs20_session_info_url;
189 int hs20_disassoc_timer;
198 unsigned int mesh_sae_pmksa_caching:1;
218 u8 rrm_enabled_capa[5];
220 #ifdef CONFIG_TAXONOMY 221 struct wpabuf *probe_ie_taxonomy;
222 struct wpabuf *assoc_ie_taxonomy;
226 u8 fils_snonce[FILS_NONCE_LEN];
227 u8 fils_session[FILS_SESSION_LEN];
238 #define AP_MAX_INACTIVITY (5 * 60) 239 #define AP_DISASSOC_DELAY (3) 240 #define AP_DEAUTH_DELAY (1) 243 #define AP_MAX_INACTIVITY_AFTER_DISASSOC (1 * 30) 245 #define AP_MAX_INACTIVITY_AFTER_DEAUTH (1 * 5) 260 void ap_handle_timer(
void *eloop_ctx,
void *timeout_ctx);
262 u32 session_timeout);
264 u32 session_timeout);
265 void ap_sta_no_session_timeout(
struct hostapd_data *hapd,
267 void ap_sta_session_warning_timeout(
struct hostapd_data *hapd,
268 struct sta_info *sta,
int warning_time);
285 const u8 *addr, u16 reason);
288 struct sta_info *sta,
int authorized);
289 static inline int ap_sta_is_authorized(
struct sta_info *sta)
291 return sta->flags & WLAN_STA_AUTHORIZED;
296 void ap_sta_clear_disconnect_timeouts(
struct hostapd_data *hapd,
299 int ap_sta_flags_txt(u32 flags,
char *buf,
size_t buflen);
300 void ap_sta_delayed_1x_auth_fail_disconnect(
struct hostapd_data *hapd,
302 int ap_sta_pending_delayed_1x_auth_fail_disconnect(
struct hostapd_data *hapd,
Definition: sta_info.h:66
Definition: wpa_auth_i.h:24
Definition: sta_info.h:61
Definition: ieee802_11_defs.h:944
Definition: ap_config.h:137
Definition: ieee802_11_defs.h:978
struct eapol_state_machine - Per-Supplicant Authenticator state machines
Definition: eapol_auth_sm_i.h:39
struct dl_list - Doubly-linked list
Definition: list.h:15
Definition: gas_serv.h:64
struct eapol_sm - Internal data for EAPOL state machines
Definition: eapol_supp_sm.c:31
struct wpa_sm - Internal WPA state machine data
Definition: wpa_i.h:21
struct hostapd_data - hostapd per-BSS data structure
Definition: hostapd.h:118
Definition: sta_info.h:52