1e28a4053SRui Paulo /* 2e28a4053SRui Paulo * hostapd / Configuration definitions and helpers functions 3325151a3SRui Paulo * Copyright (c) 2003-2015, Jouni Malinen <j@w1.fi> 4e28a4053SRui Paulo * 5f05cddf9SRui Paulo * This software may be distributed under the terms of the BSD license. 6f05cddf9SRui Paulo * See README for more details. 7e28a4053SRui Paulo */ 8e28a4053SRui Paulo 9e28a4053SRui Paulo #ifndef HOSTAPD_CONFIG_H 10e28a4053SRui Paulo #define HOSTAPD_CONFIG_H 11e28a4053SRui Paulo 12e28a4053SRui Paulo #include "common/defs.h" 13780fb4a2SCy Schubert #include "utils/list.h" 14e28a4053SRui Paulo #include "ip_addr.h" 15e28a4053SRui Paulo #include "common/wpa_common.h" 16325151a3SRui Paulo #include "common/ieee802_11_defs.h" 17f05cddf9SRui Paulo #include "common/ieee802_11_common.h" 18206b73d0SCy Schubert #include "crypto/sha256.h" 19f05cddf9SRui Paulo #include "wps/wps.h" 20325151a3SRui Paulo #include "fst/fst.h" 21780fb4a2SCy Schubert #include "vlan.h" 22e28a4053SRui Paulo 235b9c547cSRui Paulo /** 245b9c547cSRui Paulo * mesh_conf - local MBSS state and settings 255b9c547cSRui Paulo */ 265b9c547cSRui Paulo struct mesh_conf { 275b9c547cSRui Paulo u8 meshid[32]; 285b9c547cSRui Paulo u8 meshid_len; 295b9c547cSRui Paulo /* Active Path Selection Protocol Identifier */ 305b9c547cSRui Paulo u8 mesh_pp_id; 315b9c547cSRui Paulo /* Active Path Selection Metric Identifier */ 325b9c547cSRui Paulo u8 mesh_pm_id; 335b9c547cSRui Paulo /* Congestion Control Mode Identifier */ 345b9c547cSRui Paulo u8 mesh_cc_id; 355b9c547cSRui Paulo /* Synchronization Protocol Identifier */ 365b9c547cSRui Paulo u8 mesh_sp_id; 375b9c547cSRui Paulo /* Authentication Protocol Identifier */ 385b9c547cSRui Paulo u8 mesh_auth_id; 39325151a3SRui Paulo u8 *rsn_ie; 40325151a3SRui Paulo int rsn_ie_len; 415b9c547cSRui Paulo #define MESH_CONF_SEC_NONE BIT(0) 425b9c547cSRui Paulo #define MESH_CONF_SEC_AUTH BIT(1) 435b9c547cSRui Paulo #define MESH_CONF_SEC_AMPE BIT(2) 445b9c547cSRui Paulo unsigned int security; 45780fb4a2SCy Schubert enum mfp_options ieee80211w; 464bc52338SCy Schubert int ocv; 47780fb4a2SCy Schubert unsigned int pairwise_cipher; 48780fb4a2SCy Schubert unsigned int group_cipher; 49780fb4a2SCy Schubert unsigned int mgmt_group_cipher; 505b9c547cSRui Paulo int dot11MeshMaxRetries; 515b9c547cSRui Paulo int dot11MeshRetryTimeout; /* msec */ 525b9c547cSRui Paulo int dot11MeshConfirmTimeout; /* msec */ 535b9c547cSRui Paulo int dot11MeshHoldingTimeout; /* msec */ 545b9c547cSRui Paulo }; 555b9c547cSRui Paulo 56e28a4053SRui Paulo #define MAX_STA_COUNT 2007 57e28a4053SRui Paulo #define MAX_VLAN_ID 4094 58e28a4053SRui Paulo 59e28a4053SRui Paulo typedef u8 macaddr[ETH_ALEN]; 60e28a4053SRui Paulo 61e28a4053SRui Paulo struct mac_acl_entry { 62e28a4053SRui Paulo macaddr addr; 63780fb4a2SCy Schubert struct vlan_description vlan_id; 64e28a4053SRui Paulo }; 65e28a4053SRui Paulo 66e28a4053SRui Paulo struct hostapd_radius_servers; 67e28a4053SRui Paulo struct ft_remote_r0kh; 68e28a4053SRui Paulo struct ft_remote_r1kh; 69e28a4053SRui Paulo 70c1d255d3SCy Schubert #ifdef CONFIG_WEP 71e28a4053SRui Paulo #define NUM_WEP_KEYS 4 72e28a4053SRui Paulo struct hostapd_wep_keys { 73e28a4053SRui Paulo u8 idx; 74e28a4053SRui Paulo u8 *key[NUM_WEP_KEYS]; 75e28a4053SRui Paulo size_t len[NUM_WEP_KEYS]; 76e28a4053SRui Paulo int keys_set; 77e28a4053SRui Paulo size_t default_len; /* key length used for dynamic key generation */ 78e28a4053SRui Paulo }; 79c1d255d3SCy Schubert #endif /* CONFIG_WEP */ 80e28a4053SRui Paulo 81e28a4053SRui Paulo typedef enum hostap_security_policy { 82e28a4053SRui Paulo SECURITY_PLAINTEXT = 0, 83c1d255d3SCy Schubert #ifdef CONFIG_WEP 84e28a4053SRui Paulo SECURITY_STATIC_WEP = 1, 85c1d255d3SCy Schubert #endif /* CONFIG_WEP */ 86e28a4053SRui Paulo SECURITY_IEEE_802_1X = 2, 87e28a4053SRui Paulo SECURITY_WPA_PSK = 3, 885b9c547cSRui Paulo SECURITY_WPA = 4, 895b9c547cSRui Paulo SECURITY_OSEN = 5 90e28a4053SRui Paulo } secpolicy; 91e28a4053SRui Paulo 92e28a4053SRui Paulo struct hostapd_ssid { 93325151a3SRui Paulo u8 ssid[SSID_MAX_LEN]; 94e28a4053SRui Paulo size_t ssid_len; 95c1d255d3SCy Schubert u32 short_ssid; 96f05cddf9SRui Paulo unsigned int ssid_set:1; 97f05cddf9SRui Paulo unsigned int utf8_ssid:1; 985b9c547cSRui Paulo unsigned int wpa_passphrase_set:1; 995b9c547cSRui Paulo unsigned int wpa_psk_set:1; 100e28a4053SRui Paulo 101e28a4053SRui Paulo char vlan[IFNAMSIZ + 1]; 102e28a4053SRui Paulo secpolicy security_policy; 103e28a4053SRui Paulo 104e28a4053SRui Paulo struct hostapd_wpa_psk *wpa_psk; 105e28a4053SRui Paulo char *wpa_passphrase; 106e28a4053SRui Paulo char *wpa_psk_file; 107c1d255d3SCy Schubert struct sae_pt *pt; 108e28a4053SRui Paulo 109c1d255d3SCy Schubert #ifdef CONFIG_WEP 110e28a4053SRui Paulo struct hostapd_wep_keys wep; 111c1d255d3SCy Schubert #endif /* CONFIG_WEP */ 112e28a4053SRui Paulo 113e28a4053SRui Paulo #define DYNAMIC_VLAN_DISABLED 0 114e28a4053SRui Paulo #define DYNAMIC_VLAN_OPTIONAL 1 115e28a4053SRui Paulo #define DYNAMIC_VLAN_REQUIRED 2 116e28a4053SRui Paulo int dynamic_vlan; 117f05cddf9SRui Paulo #define DYNAMIC_VLAN_NAMING_WITHOUT_DEVICE 0 118f05cddf9SRui Paulo #define DYNAMIC_VLAN_NAMING_WITH_DEVICE 1 119f05cddf9SRui Paulo #define DYNAMIC_VLAN_NAMING_END 2 120f05cddf9SRui Paulo int vlan_naming; 121780fb4a2SCy Schubert int per_sta_vif; 122e28a4053SRui Paulo #ifdef CONFIG_FULL_DYNAMIC_VLAN 123e28a4053SRui Paulo char *vlan_tagged_interface; 124e28a4053SRui Paulo #endif /* CONFIG_FULL_DYNAMIC_VLAN */ 125e28a4053SRui Paulo }; 126e28a4053SRui Paulo 127e28a4053SRui Paulo 128e28a4053SRui Paulo #define VLAN_ID_WILDCARD -1 129e28a4053SRui Paulo 130e28a4053SRui Paulo struct hostapd_vlan { 131e28a4053SRui Paulo struct hostapd_vlan *next; 132e28a4053SRui Paulo int vlan_id; /* VLAN ID or -1 (VLAN_ID_WILDCARD) for wildcard entry */ 133780fb4a2SCy Schubert struct vlan_description vlan_desc; 134e28a4053SRui Paulo char ifname[IFNAMSIZ + 1]; 1354bc52338SCy Schubert char bridge[IFNAMSIZ + 1]; 136325151a3SRui Paulo int configured; 137e28a4053SRui Paulo int dynamic_vlan; 138e28a4053SRui Paulo #ifdef CONFIG_FULL_DYNAMIC_VLAN 139e28a4053SRui Paulo 140e28a4053SRui Paulo #define DVLAN_CLEAN_WLAN_PORT 0x8 141e28a4053SRui Paulo int clean; 142e28a4053SRui Paulo #endif /* CONFIG_FULL_DYNAMIC_VLAN */ 143e28a4053SRui Paulo }; 144e28a4053SRui Paulo 145e28a4053SRui Paulo #define PMK_LEN 32 1464bc52338SCy Schubert #define KEYID_LEN 32 147780fb4a2SCy Schubert #define MIN_PASSPHRASE_LEN 8 148780fb4a2SCy Schubert #define MAX_PASSPHRASE_LEN 63 149f05cddf9SRui Paulo struct hostapd_sta_wpa_psk_short { 150f05cddf9SRui Paulo struct hostapd_sta_wpa_psk_short *next; 151780fb4a2SCy Schubert unsigned int is_passphrase:1; 152f05cddf9SRui Paulo u8 psk[PMK_LEN]; 153780fb4a2SCy Schubert char passphrase[MAX_PASSPHRASE_LEN + 1]; 154780fb4a2SCy Schubert int ref; /* (number of references held) - 1 */ 155f05cddf9SRui Paulo }; 156f05cddf9SRui Paulo 157e28a4053SRui Paulo struct hostapd_wpa_psk { 158e28a4053SRui Paulo struct hostapd_wpa_psk *next; 159e28a4053SRui Paulo int group; 1604bc52338SCy Schubert char keyid[KEYID_LEN]; 161c1d255d3SCy Schubert int wps; 162e28a4053SRui Paulo u8 psk[PMK_LEN]; 163e28a4053SRui Paulo u8 addr[ETH_ALEN]; 1645b9c547cSRui Paulo u8 p2p_dev_addr[ETH_ALEN]; 1654bc52338SCy Schubert int vlan_id; 166e28a4053SRui Paulo }; 167e28a4053SRui Paulo 168e28a4053SRui Paulo struct hostapd_eap_user { 169e28a4053SRui Paulo struct hostapd_eap_user *next; 170e28a4053SRui Paulo u8 *identity; 171e28a4053SRui Paulo size_t identity_len; 172e28a4053SRui Paulo struct { 173e28a4053SRui Paulo int vendor; 174e28a4053SRui Paulo u32 method; 175f05cddf9SRui Paulo } methods[EAP_MAX_METHODS]; 176e28a4053SRui Paulo u8 *password; 177e28a4053SRui Paulo size_t password_len; 17885732ac8SCy Schubert u8 *salt; 17985732ac8SCy Schubert size_t salt_len; /* non-zero when password is salted */ 180e28a4053SRui Paulo int phase2; 181e28a4053SRui Paulo int force_version; 182e28a4053SRui Paulo unsigned int wildcard_prefix:1; 183e28a4053SRui Paulo unsigned int password_hash:1; /* whether password is hashed with 184e28a4053SRui Paulo * nt_password_hash() */ 1855b9c547cSRui Paulo unsigned int remediation:1; 1865b9c547cSRui Paulo unsigned int macacl:1; 187e28a4053SRui Paulo int ttls_auth; /* EAP_TTLS_AUTH_* bitfield */ 1885b9c547cSRui Paulo struct hostapd_radius_attr *accept_attr; 18985732ac8SCy Schubert u32 t_c_timestamp; 190e28a4053SRui Paulo }; 191e28a4053SRui Paulo 192f05cddf9SRui Paulo struct hostapd_radius_attr { 193f05cddf9SRui Paulo u8 type; 194f05cddf9SRui Paulo struct wpabuf *val; 195f05cddf9SRui Paulo struct hostapd_radius_attr *next; 196f05cddf9SRui Paulo }; 197e28a4053SRui Paulo 198f05cddf9SRui Paulo 199f05cddf9SRui Paulo #define NUM_TX_QUEUES 4 200f05cddf9SRui Paulo #define MAX_ROAMING_CONSORTIUM_LEN 15 201f05cddf9SRui Paulo 202f05cddf9SRui Paulo struct hostapd_roaming_consortium { 203f05cddf9SRui Paulo u8 len; 204f05cddf9SRui Paulo u8 oi[MAX_ROAMING_CONSORTIUM_LEN]; 205e28a4053SRui Paulo }; 206e28a4053SRui Paulo 207f05cddf9SRui Paulo struct hostapd_lang_string { 208f05cddf9SRui Paulo u8 lang[3]; 209f05cddf9SRui Paulo u8 name_len; 210f05cddf9SRui Paulo u8 name[252]; 211f05cddf9SRui Paulo }; 212f05cddf9SRui Paulo 21385732ac8SCy Schubert struct hostapd_venue_url { 21485732ac8SCy Schubert u8 venue_number; 21585732ac8SCy Schubert u8 url_len; 21685732ac8SCy Schubert u8 url[254]; 21785732ac8SCy Schubert }; 21885732ac8SCy Schubert 219f05cddf9SRui Paulo #define MAX_NAI_REALMS 10 220f05cddf9SRui Paulo #define MAX_NAI_REALMLEN 255 221f05cddf9SRui Paulo #define MAX_NAI_EAP_METHODS 5 222f05cddf9SRui Paulo #define MAX_NAI_AUTH_TYPES 4 223f05cddf9SRui Paulo struct hostapd_nai_realm_data { 224f05cddf9SRui Paulo u8 encoding; 225f05cddf9SRui Paulo char realm_buf[MAX_NAI_REALMLEN + 1]; 226f05cddf9SRui Paulo char *realm[MAX_NAI_REALMS]; 227f05cddf9SRui Paulo u8 eap_method_count; 228f05cddf9SRui Paulo struct hostapd_nai_realm_eap { 229f05cddf9SRui Paulo u8 eap_method; 230f05cddf9SRui Paulo u8 num_auths; 231f05cddf9SRui Paulo u8 auth_id[MAX_NAI_AUTH_TYPES]; 232f05cddf9SRui Paulo u8 auth_val[MAX_NAI_AUTH_TYPES]; 233f05cddf9SRui Paulo } eap_method[MAX_NAI_EAP_METHODS]; 234f05cddf9SRui Paulo }; 235e28a4053SRui Paulo 236780fb4a2SCy Schubert struct anqp_element { 237780fb4a2SCy Schubert struct dl_list list; 238780fb4a2SCy Schubert u16 infoid; 239780fb4a2SCy Schubert struct wpabuf *payload; 240780fb4a2SCy Schubert }; 241780fb4a2SCy Schubert 24285732ac8SCy Schubert struct fils_realm { 24385732ac8SCy Schubert struct dl_list list; 24485732ac8SCy Schubert u8 hash[2]; 24585732ac8SCy Schubert char realm[]; 24685732ac8SCy Schubert }; 24785732ac8SCy Schubert 24885732ac8SCy Schubert struct sae_password_entry { 24985732ac8SCy Schubert struct sae_password_entry *next; 25085732ac8SCy Schubert char *password; 25185732ac8SCy Schubert char *identifier; 25285732ac8SCy Schubert u8 peer_addr[ETH_ALEN]; 2534bc52338SCy Schubert int vlan_id; 254c1d255d3SCy Schubert struct sae_pt *pt; 255c1d255d3SCy Schubert struct sae_pk *pk; 25685732ac8SCy Schubert }; 257780fb4a2SCy Schubert 258206b73d0SCy Schubert struct dpp_controller_conf { 259206b73d0SCy Schubert struct dpp_controller_conf *next; 260206b73d0SCy Schubert u8 pkhash[SHA256_MAC_LEN]; 261206b73d0SCy Schubert struct hostapd_ip_addr ipaddr; 262206b73d0SCy Schubert }; 263206b73d0SCy Schubert 264206b73d0SCy Schubert struct airtime_sta_weight { 265206b73d0SCy Schubert struct airtime_sta_weight *next; 266206b73d0SCy Schubert unsigned int weight; 267206b73d0SCy Schubert u8 addr[ETH_ALEN]; 268206b73d0SCy Schubert }; 269206b73d0SCy Schubert 270c1d255d3SCy Schubert #define EXT_CAPA_MAX_LEN 15 271c1d255d3SCy Schubert 272e28a4053SRui Paulo /** 273e28a4053SRui Paulo * struct hostapd_bss_config - Per-BSS configuration 274e28a4053SRui Paulo */ 275e28a4053SRui Paulo struct hostapd_bss_config { 276e28a4053SRui Paulo char iface[IFNAMSIZ + 1]; 277e28a4053SRui Paulo char bridge[IFNAMSIZ + 1]; 2785b9c547cSRui Paulo char vlan_bridge[IFNAMSIZ + 1]; 279f05cddf9SRui Paulo char wds_bridge[IFNAMSIZ + 1]; 280e28a4053SRui Paulo 281e28a4053SRui Paulo enum hostapd_logger_level logger_syslog_level, logger_stdout_level; 282e28a4053SRui Paulo 283e28a4053SRui Paulo unsigned int logger_syslog; /* module bitfield */ 284e28a4053SRui Paulo unsigned int logger_stdout; /* module bitfield */ 285e28a4053SRui Paulo 286e28a4053SRui Paulo int max_num_sta; /* maximum number of STAs in station table */ 287e28a4053SRui Paulo 288e28a4053SRui Paulo int dtim_period; 28985732ac8SCy Schubert unsigned int bss_load_update_period; 29085732ac8SCy Schubert unsigned int chan_util_avg_period; 291e28a4053SRui Paulo 292e28a4053SRui Paulo int ieee802_1x; /* use IEEE 802.1X */ 293e28a4053SRui Paulo int eapol_version; 294e28a4053SRui Paulo int eap_server; /* Use internal EAP server instead of external 295e28a4053SRui Paulo * RADIUS server */ 296e28a4053SRui Paulo struct hostapd_eap_user *eap_user; 297f05cddf9SRui Paulo char *eap_user_sqlite; 298e28a4053SRui Paulo char *eap_sim_db; 299780fb4a2SCy Schubert unsigned int eap_sim_db_timeout; 3005b9c547cSRui Paulo int eap_server_erp; /* Whether ERP is enabled on internal EAP server */ 301e28a4053SRui Paulo struct hostapd_ip_addr own_ip_addr; 302e28a4053SRui Paulo char *nas_identifier; 303e28a4053SRui Paulo struct hostapd_radius_servers *radius; 304e28a4053SRui Paulo int acct_interim_interval; 305f05cddf9SRui Paulo int radius_request_cui; 306f05cddf9SRui Paulo struct hostapd_radius_attr *radius_auth_req_attr; 307f05cddf9SRui Paulo struct hostapd_radius_attr *radius_acct_req_attr; 308206b73d0SCy Schubert char *radius_req_attr_sqlite; 309f05cddf9SRui Paulo int radius_das_port; 310f05cddf9SRui Paulo unsigned int radius_das_time_window; 311f05cddf9SRui Paulo int radius_das_require_event_timestamp; 312780fb4a2SCy Schubert int radius_das_require_message_authenticator; 313f05cddf9SRui Paulo struct hostapd_ip_addr radius_das_client_addr; 314f05cddf9SRui Paulo u8 *radius_das_shared_secret; 315f05cddf9SRui Paulo size_t radius_das_shared_secret_len; 316e28a4053SRui Paulo 317e28a4053SRui Paulo struct hostapd_ssid ssid; 318e28a4053SRui Paulo 319e28a4053SRui Paulo char *eap_req_id_text; /* optional displayable message sent with 320e28a4053SRui Paulo * EAP Request-Identity */ 321e28a4053SRui Paulo size_t eap_req_id_text_len; 322e28a4053SRui Paulo int eapol_key_index_workaround; 323e28a4053SRui Paulo 324c1d255d3SCy Schubert #ifdef CONFIG_WEP 325e28a4053SRui Paulo size_t default_wep_key_len; 326e28a4053SRui Paulo int individual_wep_key_len; 327e28a4053SRui Paulo int wep_rekeying_period; 328e28a4053SRui Paulo int broadcast_key_idx_min, broadcast_key_idx_max; 329c1d255d3SCy Schubert #endif /* CONFIG_WEP */ 330e28a4053SRui Paulo int eap_reauth_period; 3315b9c547cSRui Paulo int erp_send_reauth_start; 3325b9c547cSRui Paulo char *erp_domain; 333e28a4053SRui Paulo 33485732ac8SCy Schubert enum macaddr_acl { 335e28a4053SRui Paulo ACCEPT_UNLESS_DENIED = 0, 336e28a4053SRui Paulo DENY_UNLESS_ACCEPTED = 1, 337e28a4053SRui Paulo USE_EXTERNAL_RADIUS_AUTH = 2 338e28a4053SRui Paulo } macaddr_acl; 339e28a4053SRui Paulo struct mac_acl_entry *accept_mac; 340e28a4053SRui Paulo int num_accept_mac; 341e28a4053SRui Paulo struct mac_acl_entry *deny_mac; 342e28a4053SRui Paulo int num_deny_mac; 343e28a4053SRui Paulo int wds_sta; 344f05cddf9SRui Paulo int isolate; 3455b9c547cSRui Paulo int start_disabled; 346e28a4053SRui Paulo 347e28a4053SRui Paulo int auth_algs; /* bitfield of allowed IEEE 802.11 authentication 348e28a4053SRui Paulo * algorithms, WPA_AUTH_ALG_{OPEN,SHARED,LEAP} */ 349e28a4053SRui Paulo 350e28a4053SRui Paulo int wpa; /* bitfield of WPA_PROTO_WPA, WPA_PROTO_RSN */ 351c1d255d3SCy Schubert int extended_key_id; 352e28a4053SRui Paulo int wpa_key_mgmt; 353e28a4053SRui Paulo enum mfp_options ieee80211w; 3545b9c547cSRui Paulo int group_mgmt_cipher; 355c1d255d3SCy Schubert int beacon_prot; 356e28a4053SRui Paulo /* dot11AssociationSAQueryMaximumTimeout (in TUs) */ 357e28a4053SRui Paulo unsigned int assoc_sa_query_max_timeout; 358e28a4053SRui Paulo /* dot11AssociationSAQueryRetryTimeout (in TUs) */ 359e28a4053SRui Paulo int assoc_sa_query_retry_timeout; 3604bc52338SCy Schubert #ifdef CONFIG_OCV 3614bc52338SCy Schubert int ocv; /* Operating Channel Validation */ 3624bc52338SCy Schubert #endif /* CONFIG_OCV */ 363f05cddf9SRui Paulo enum { 364f05cddf9SRui Paulo PSK_RADIUS_IGNORED = 0, 365f05cddf9SRui Paulo PSK_RADIUS_ACCEPTED = 1, 366f05cddf9SRui Paulo PSK_RADIUS_REQUIRED = 2 367f05cddf9SRui Paulo } wpa_psk_radius; 368e28a4053SRui Paulo int wpa_pairwise; 36985732ac8SCy Schubert int group_cipher; /* wpa_group value override from configuation */ 370e28a4053SRui Paulo int wpa_group; 371e28a4053SRui Paulo int wpa_group_rekey; 37285732ac8SCy Schubert int wpa_group_rekey_set; 373e28a4053SRui Paulo int wpa_strict_rekey; 374e28a4053SRui Paulo int wpa_gmk_rekey; 375e28a4053SRui Paulo int wpa_ptk_rekey; 376c1d255d3SCy Schubert enum ptk0_rekey_handling wpa_deny_ptk0_rekey; 37785732ac8SCy Schubert u32 wpa_group_update_count; 37885732ac8SCy Schubert u32 wpa_pairwise_update_count; 37985732ac8SCy Schubert int wpa_disable_eapol_key_retries; 380e28a4053SRui Paulo int rsn_pairwise; 381e28a4053SRui Paulo int rsn_preauth; 382e28a4053SRui Paulo char *rsn_preauth_interfaces; 383e28a4053SRui Paulo 38485732ac8SCy Schubert #ifdef CONFIG_IEEE80211R_AP 385e28a4053SRui Paulo /* IEEE 802.11r - Fast BSS Transition */ 386e28a4053SRui Paulo u8 mobility_domain[MOBILITY_DOMAIN_ID_LEN]; 387e28a4053SRui Paulo u8 r1_key_holder[FT_R1KH_ID_LEN]; 38885732ac8SCy Schubert u32 r0_key_lifetime; /* PMK-R0 lifetime seconds */ 38985732ac8SCy Schubert int rkh_pos_timeout; 39085732ac8SCy Schubert int rkh_neg_timeout; 39185732ac8SCy Schubert int rkh_pull_timeout; /* ms */ 39285732ac8SCy Schubert int rkh_pull_retries; 393e28a4053SRui Paulo u32 reassociation_deadline; 394e28a4053SRui Paulo struct ft_remote_r0kh *r0kh_list; 395e28a4053SRui Paulo struct ft_remote_r1kh *r1kh_list; 396e28a4053SRui Paulo int pmk_r1_push; 397f05cddf9SRui Paulo int ft_over_ds; 39885732ac8SCy Schubert int ft_psk_generate_local; 39985732ac8SCy Schubert int r1_max_key_lifetime; 40085732ac8SCy Schubert #endif /* CONFIG_IEEE80211R_AP */ 401e28a4053SRui Paulo 402e28a4053SRui Paulo char *ctrl_interface; /* directory for UNIX domain sockets */ 403e28a4053SRui Paulo #ifndef CONFIG_NATIVE_WINDOWS 404e28a4053SRui Paulo gid_t ctrl_interface_gid; 405e28a4053SRui Paulo #endif /* CONFIG_NATIVE_WINDOWS */ 406e28a4053SRui Paulo int ctrl_interface_gid_set; 407e28a4053SRui Paulo 408e28a4053SRui Paulo char *ca_cert; 409e28a4053SRui Paulo char *server_cert; 410206b73d0SCy Schubert char *server_cert2; 411e28a4053SRui Paulo char *private_key; 412206b73d0SCy Schubert char *private_key2; 413e28a4053SRui Paulo char *private_key_passwd; 414206b73d0SCy Schubert char *private_key_passwd2; 4154bc52338SCy Schubert char *check_cert_subject; 416e28a4053SRui Paulo int check_crl; 4174bc52338SCy Schubert int check_crl_strict; 4184bc52338SCy Schubert unsigned int crl_reload_interval; 419325151a3SRui Paulo unsigned int tls_session_lifetime; 42085732ac8SCy Schubert unsigned int tls_flags; 421c1d255d3SCy Schubert unsigned int max_auth_rounds; 422c1d255d3SCy Schubert unsigned int max_auth_rounds_short; 4235b9c547cSRui Paulo char *ocsp_stapling_response; 424780fb4a2SCy Schubert char *ocsp_stapling_response_multi; 425e28a4053SRui Paulo char *dh_file; 4265b9c547cSRui Paulo char *openssl_ciphers; 4274bc52338SCy Schubert char *openssl_ecdh_curves; 428e28a4053SRui Paulo u8 *pac_opaque_encr_key; 429e28a4053SRui Paulo u8 *eap_fast_a_id; 430e28a4053SRui Paulo size_t eap_fast_a_id_len; 431e28a4053SRui Paulo char *eap_fast_a_id_info; 432e28a4053SRui Paulo int eap_fast_prov; 433e28a4053SRui Paulo int pac_key_lifetime; 434e28a4053SRui Paulo int pac_key_refresh_time; 435206b73d0SCy Schubert int eap_teap_auth; 436206b73d0SCy Schubert int eap_teap_pac_no_inner; 437c1d255d3SCy Schubert int eap_teap_separate_result; 438c1d255d3SCy Schubert int eap_teap_id; 439e28a4053SRui Paulo int eap_sim_aka_result_ind; 440206b73d0SCy Schubert int eap_sim_id; 441e28a4053SRui Paulo int tnc; 442f05cddf9SRui Paulo int fragment_size; 443f05cddf9SRui Paulo u16 pwd_group; 444e28a4053SRui Paulo 445e28a4053SRui Paulo char *radius_server_clients; 446e28a4053SRui Paulo int radius_server_auth_port; 4475b9c547cSRui Paulo int radius_server_acct_port; 448e28a4053SRui Paulo int radius_server_ipv6; 449e28a4053SRui Paulo 450e28a4053SRui Paulo int use_pae_group_addr; /* Whether to send EAPOL frames to PAE group 451e28a4053SRui Paulo * address instead of individual address 452e28a4053SRui Paulo * (for driver_wired.c). 453e28a4053SRui Paulo */ 454e28a4053SRui Paulo 455e28a4053SRui Paulo int ap_max_inactivity; 456e28a4053SRui Paulo int ignore_broadcast_ssid; 457780fb4a2SCy Schubert int no_probe_resp_if_max_sta; 458e28a4053SRui Paulo 459e28a4053SRui Paulo int wmm_enabled; 460e28a4053SRui Paulo int wmm_uapsd; 461e28a4053SRui Paulo 4625b9c547cSRui Paulo struct hostapd_vlan *vlan; 463e28a4053SRui Paulo 464e28a4053SRui Paulo macaddr bssid; 465e28a4053SRui Paulo 466e28a4053SRui Paulo /* 467e28a4053SRui Paulo * Maximum listen interval that STAs can use when associating with this 468e28a4053SRui Paulo * BSS. If a STA tries to use larger value, the association will be 469e28a4053SRui Paulo * denied with status code 51. 470e28a4053SRui Paulo */ 471e28a4053SRui Paulo u16 max_listen_interval; 472e28a4053SRui Paulo 473f05cddf9SRui Paulo int disable_pmksa_caching; 474e28a4053SRui Paulo int okc; /* Opportunistic Key Caching */ 475e28a4053SRui Paulo 476e28a4053SRui Paulo int wps_state; 477e28a4053SRui Paulo #ifdef CONFIG_WPS 4785b9c547cSRui Paulo int wps_independent; 479e28a4053SRui Paulo int ap_setup_locked; 480e28a4053SRui Paulo u8 uuid[16]; 481e28a4053SRui Paulo char *wps_pin_requests; 482e28a4053SRui Paulo char *device_name; 483e28a4053SRui Paulo char *manufacturer; 484e28a4053SRui Paulo char *model_name; 485e28a4053SRui Paulo char *model_number; 486e28a4053SRui Paulo char *serial_number; 487f05cddf9SRui Paulo u8 device_type[WPS_DEV_TYPE_LEN]; 488e28a4053SRui Paulo char *config_methods; 489e28a4053SRui Paulo u8 os_version[4]; 490e28a4053SRui Paulo char *ap_pin; 491e28a4053SRui Paulo int skip_cred_build; 492e28a4053SRui Paulo u8 *extra_cred; 493e28a4053SRui Paulo size_t extra_cred_len; 494e28a4053SRui Paulo int wps_cred_processing; 4954bc52338SCy Schubert int wps_cred_add_sae; 4965b9c547cSRui Paulo int force_per_enrollee_psk; 497e28a4053SRui Paulo u8 *ap_settings; 498e28a4053SRui Paulo size_t ap_settings_len; 4994bc52338SCy Schubert struct hostapd_ssid multi_ap_backhaul_ssid; 500e28a4053SRui Paulo char *upnp_iface; 501e28a4053SRui Paulo char *friendly_name; 502e28a4053SRui Paulo char *manufacturer_url; 503e28a4053SRui Paulo char *model_description; 504e28a4053SRui Paulo char *model_url; 505e28a4053SRui Paulo char *upc; 506f05cddf9SRui Paulo struct wpabuf *wps_vendor_ext[MAX_WPS_VENDOR_EXTENSIONS]; 507c1d255d3SCy Schubert struct wpabuf *wps_application_ext; 5085b9c547cSRui Paulo int wps_nfc_pw_from_config; 509f05cddf9SRui Paulo int wps_nfc_dev_pw_id; 510f05cddf9SRui Paulo struct wpabuf *wps_nfc_dh_pubkey; 511f05cddf9SRui Paulo struct wpabuf *wps_nfc_dh_privkey; 512f05cddf9SRui Paulo struct wpabuf *wps_nfc_dev_pw; 513e28a4053SRui Paulo #endif /* CONFIG_WPS */ 514f05cddf9SRui Paulo int pbc_in_m1; 5155b9c547cSRui Paulo char *server_id; 516f05cddf9SRui Paulo 517f05cddf9SRui Paulo #define P2P_ENABLED BIT(0) 518f05cddf9SRui Paulo #define P2P_GROUP_OWNER BIT(1) 519f05cddf9SRui Paulo #define P2P_GROUP_FORMATION BIT(2) 520f05cddf9SRui Paulo #define P2P_MANAGE BIT(3) 521f05cddf9SRui Paulo #define P2P_ALLOW_CROSS_CONNECTION BIT(4) 522f05cddf9SRui Paulo int p2p; 5235b9c547cSRui Paulo #ifdef CONFIG_P2P 5245b9c547cSRui Paulo u8 ip_addr_go[4]; 5255b9c547cSRui Paulo u8 ip_addr_mask[4]; 5265b9c547cSRui Paulo u8 ip_addr_start[4]; 5275b9c547cSRui Paulo u8 ip_addr_end[4]; 5285b9c547cSRui Paulo #endif /* CONFIG_P2P */ 529f05cddf9SRui Paulo 530f05cddf9SRui Paulo int disassoc_low_ack; 531f05cddf9SRui Paulo int skip_inactivity_poll; 532f05cddf9SRui Paulo 533f05cddf9SRui Paulo #define TDLS_PROHIBIT BIT(0) 534f05cddf9SRui Paulo #define TDLS_PROHIBIT_CHAN_SWITCH BIT(1) 535f05cddf9SRui Paulo int tdls; 536c1d255d3SCy Schubert bool disable_11n; 537c1d255d3SCy Schubert bool disable_11ac; 538c1d255d3SCy Schubert bool disable_11ax; 539f05cddf9SRui Paulo 540f05cddf9SRui Paulo /* IEEE 802.11v */ 541f05cddf9SRui Paulo int time_advertisement; 542f05cddf9SRui Paulo char *time_zone; 543f05cddf9SRui Paulo int wnm_sleep_mode; 54485732ac8SCy Schubert int wnm_sleep_mode_no_keys; 545f05cddf9SRui Paulo int bss_transition; 546f05cddf9SRui Paulo 547f05cddf9SRui Paulo /* IEEE 802.11u - Interworking */ 548f05cddf9SRui Paulo int interworking; 549f05cddf9SRui Paulo int access_network_type; 550f05cddf9SRui Paulo int internet; 551f05cddf9SRui Paulo int asra; 552f05cddf9SRui Paulo int esr; 553f05cddf9SRui Paulo int uesa; 554f05cddf9SRui Paulo int venue_info_set; 555f05cddf9SRui Paulo u8 venue_group; 556f05cddf9SRui Paulo u8 venue_type; 557f05cddf9SRui Paulo u8 hessid[ETH_ALEN]; 558f05cddf9SRui Paulo 559f05cddf9SRui Paulo /* IEEE 802.11u - Roaming Consortium list */ 560f05cddf9SRui Paulo unsigned int roaming_consortium_count; 561f05cddf9SRui Paulo struct hostapd_roaming_consortium *roaming_consortium; 562f05cddf9SRui Paulo 563f05cddf9SRui Paulo /* IEEE 802.11u - Venue Name duples */ 564f05cddf9SRui Paulo unsigned int venue_name_count; 565f05cddf9SRui Paulo struct hostapd_lang_string *venue_name; 566f05cddf9SRui Paulo 56785732ac8SCy Schubert /* Venue URL duples */ 56885732ac8SCy Schubert unsigned int venue_url_count; 56985732ac8SCy Schubert struct hostapd_venue_url *venue_url; 57085732ac8SCy Schubert 571f05cddf9SRui Paulo /* IEEE 802.11u - Network Authentication Type */ 572f05cddf9SRui Paulo u8 *network_auth_type; 573f05cddf9SRui Paulo size_t network_auth_type_len; 574f05cddf9SRui Paulo 575f05cddf9SRui Paulo /* IEEE 802.11u - IP Address Type Availability */ 576f05cddf9SRui Paulo u8 ipaddr_type_availability; 577f05cddf9SRui Paulo u8 ipaddr_type_configured; 578f05cddf9SRui Paulo 579f05cddf9SRui Paulo /* IEEE 802.11u - 3GPP Cellular Network */ 580f05cddf9SRui Paulo u8 *anqp_3gpp_cell_net; 581f05cddf9SRui Paulo size_t anqp_3gpp_cell_net_len; 582f05cddf9SRui Paulo 583f05cddf9SRui Paulo /* IEEE 802.11u - Domain Name */ 584f05cddf9SRui Paulo u8 *domain_name; 585f05cddf9SRui Paulo size_t domain_name_len; 586f05cddf9SRui Paulo 587f05cddf9SRui Paulo unsigned int nai_realm_count; 588f05cddf9SRui Paulo struct hostapd_nai_realm_data *nai_realm_data; 589f05cddf9SRui Paulo 590780fb4a2SCy Schubert struct dl_list anqp_elem; /* list of struct anqp_element */ 591780fb4a2SCy Schubert 592f05cddf9SRui Paulo u16 gas_comeback_delay; 59385732ac8SCy Schubert size_t gas_frag_limit; 594780fb4a2SCy Schubert int gas_address3; 595f05cddf9SRui Paulo 5965b9c547cSRui Paulo u8 qos_map_set[16 + 2 * 21]; 5975b9c547cSRui Paulo unsigned int qos_map_set_len; 5985b9c547cSRui Paulo 5995b9c547cSRui Paulo int osen; 6005b9c547cSRui Paulo int proxy_arp; 601325151a3SRui Paulo int na_mcast_to_ucast; 602206b73d0SCy Schubert 603f05cddf9SRui Paulo #ifdef CONFIG_HS20 604f05cddf9SRui Paulo int hs20; 6054bc52338SCy Schubert int hs20_release; 606f05cddf9SRui Paulo int disable_dgaf; 6075b9c547cSRui Paulo u16 anqp_domain_id; 608f05cddf9SRui Paulo unsigned int hs20_oper_friendly_name_count; 609f05cddf9SRui Paulo struct hostapd_lang_string *hs20_oper_friendly_name; 610f05cddf9SRui Paulo u8 *hs20_wan_metrics; 611f05cddf9SRui Paulo u8 *hs20_connection_capability; 612f05cddf9SRui Paulo size_t hs20_connection_capability_len; 613f05cddf9SRui Paulo u8 *hs20_operating_class; 614f05cddf9SRui Paulo u8 hs20_operating_class_len; 6155b9c547cSRui Paulo struct hs20_icon { 6165b9c547cSRui Paulo u16 width; 6175b9c547cSRui Paulo u16 height; 6185b9c547cSRui Paulo char language[3]; 6195b9c547cSRui Paulo char type[256]; 6205b9c547cSRui Paulo char name[256]; 6215b9c547cSRui Paulo char file[256]; 6225b9c547cSRui Paulo } *hs20_icons; 6235b9c547cSRui Paulo size_t hs20_icons_count; 624325151a3SRui Paulo u8 osu_ssid[SSID_MAX_LEN]; 6255b9c547cSRui Paulo size_t osu_ssid_len; 6265b9c547cSRui Paulo struct hs20_osu_provider { 6275b9c547cSRui Paulo unsigned int friendly_name_count; 6285b9c547cSRui Paulo struct hostapd_lang_string *friendly_name; 6295b9c547cSRui Paulo char *server_uri; 6305b9c547cSRui Paulo int *method_list; 6315b9c547cSRui Paulo char **icons; 6325b9c547cSRui Paulo size_t icons_count; 6335b9c547cSRui Paulo char *osu_nai; 63485732ac8SCy Schubert char *osu_nai2; 6355b9c547cSRui Paulo unsigned int service_desc_count; 6365b9c547cSRui Paulo struct hostapd_lang_string *service_desc; 6375b9c547cSRui Paulo } *hs20_osu_providers, *last_osu; 6385b9c547cSRui Paulo size_t hs20_osu_providers_count; 63985732ac8SCy Schubert size_t hs20_osu_providers_nai_count; 64085732ac8SCy Schubert char **hs20_operator_icon; 64185732ac8SCy Schubert size_t hs20_operator_icon_count; 6425b9c547cSRui Paulo unsigned int hs20_deauth_req_timeout; 6435b9c547cSRui Paulo char *subscr_remediation_url; 6445b9c547cSRui Paulo u8 subscr_remediation_method; 6454bc52338SCy Schubert char *hs20_sim_provisioning_url; 64685732ac8SCy Schubert char *t_c_filename; 64785732ac8SCy Schubert u32 t_c_timestamp; 64885732ac8SCy Schubert char *t_c_server_url; 649f05cddf9SRui Paulo #endif /* CONFIG_HS20 */ 650f05cddf9SRui Paulo 651f05cddf9SRui Paulo u8 wps_rf_bands; /* RF bands for WPS (WPS_RF_*) */ 652f05cddf9SRui Paulo 653f05cddf9SRui Paulo #ifdef CONFIG_RADIUS_TEST 654f05cddf9SRui Paulo char *dump_msk_file; 655f05cddf9SRui Paulo #endif /* CONFIG_RADIUS_TEST */ 656f05cddf9SRui Paulo 657f05cddf9SRui Paulo struct wpabuf *vendor_elements; 658780fb4a2SCy Schubert struct wpabuf *assocresp_elements; 6595b9c547cSRui Paulo 660c1d255d3SCy Schubert unsigned int anti_clogging_threshold; 66185732ac8SCy Schubert unsigned int sae_sync; 66285732ac8SCy Schubert int sae_require_mfp; 663c1d255d3SCy Schubert int sae_confirm_immediate; 664c1d255d3SCy Schubert int sae_pwe; 6655b9c547cSRui Paulo int *sae_groups; 66685732ac8SCy Schubert struct sae_password_entry *sae_passwords; 6675b9c547cSRui Paulo 6685b9c547cSRui Paulo char *wowlan_triggers; /* Wake-on-WLAN triggers */ 6695b9c547cSRui Paulo 6705b9c547cSRui Paulo #ifdef CONFIG_TESTING_OPTIONS 6715b9c547cSRui Paulo u8 bss_load_test[5]; 6725b9c547cSRui Paulo u8 bss_load_test_set; 673325151a3SRui Paulo struct wpabuf *own_ie_override; 67485732ac8SCy Schubert int sae_reflection_attack; 675c1d255d3SCy Schubert int sae_commit_status; 676c1d255d3SCy Schubert int sae_pk_omit; 677c1d255d3SCy Schubert int sae_pk_password_check_skip; 67885732ac8SCy Schubert struct wpabuf *sae_commit_override; 679c1d255d3SCy Schubert struct wpabuf *rsne_override_eapol; 680c1d255d3SCy Schubert struct wpabuf *rsnxe_override_eapol; 681c1d255d3SCy Schubert struct wpabuf *rsne_override_ft; 682c1d255d3SCy Schubert struct wpabuf *rsnxe_override_ft; 683c1d255d3SCy Schubert struct wpabuf *gtk_rsc_override; 684c1d255d3SCy Schubert struct wpabuf *igtk_rsc_override; 685c1d255d3SCy Schubert int no_beacon_rsnxe; 686c1d255d3SCy Schubert int skip_prune_assoc; 687c1d255d3SCy Schubert int ft_rsnxe_used; 688c1d255d3SCy Schubert unsigned int oci_freq_override_eapol_m3; 689c1d255d3SCy Schubert unsigned int oci_freq_override_eapol_g1; 690c1d255d3SCy Schubert unsigned int oci_freq_override_saquery_req; 691c1d255d3SCy Schubert unsigned int oci_freq_override_saquery_resp; 692c1d255d3SCy Schubert unsigned int oci_freq_override_ft_assoc; 693c1d255d3SCy Schubert unsigned int oci_freq_override_fils_assoc; 694c1d255d3SCy Schubert unsigned int oci_freq_override_wnm_sleep; 6955b9c547cSRui Paulo #endif /* CONFIG_TESTING_OPTIONS */ 6965b9c547cSRui Paulo 6975b9c547cSRui Paulo #define MESH_ENABLED BIT(0) 6985b9c547cSRui Paulo int mesh; 6995b9c547cSRui Paulo 700780fb4a2SCy Schubert u8 radio_measurements[RRM_CAPABILITIES_IE_LEN]; 7015b9c547cSRui Paulo 7025b9c547cSRui Paulo int vendor_vht; 703780fb4a2SCy Schubert int use_sta_nsts; 704325151a3SRui Paulo 705325151a3SRui Paulo char *no_probe_resp_if_seen_on; 706325151a3SRui Paulo char *no_auth_if_seen_on; 707780fb4a2SCy Schubert 708780fb4a2SCy Schubert int pbss; 709780fb4a2SCy Schubert 710780fb4a2SCy Schubert #ifdef CONFIG_MBO 711780fb4a2SCy Schubert int mbo_enabled; 71285732ac8SCy Schubert /** 71385732ac8SCy Schubert * oce - Enable OCE in AP and/or STA-CFON mode 71485732ac8SCy Schubert * - BIT(0) is Reserved 71585732ac8SCy Schubert * - Set BIT(1) to enable OCE in STA-CFON mode 71685732ac8SCy Schubert * - Set BIT(2) to enable OCE in AP mode 71785732ac8SCy Schubert */ 71885732ac8SCy Schubert unsigned int oce; 71985732ac8SCy Schubert int mbo_cell_data_conn_pref; 720780fb4a2SCy Schubert #endif /* CONFIG_MBO */ 721780fb4a2SCy Schubert 722780fb4a2SCy Schubert int ftm_responder; 723780fb4a2SCy Schubert int ftm_initiator; 72485732ac8SCy Schubert 72585732ac8SCy Schubert #ifdef CONFIG_FILS 72685732ac8SCy Schubert u8 fils_cache_id[FILS_CACHE_ID_LEN]; 72785732ac8SCy Schubert int fils_cache_id_set; 72885732ac8SCy Schubert struct dl_list fils_realms; /* list of struct fils_realm */ 72985732ac8SCy Schubert int fils_dh_group; 73085732ac8SCy Schubert struct hostapd_ip_addr dhcp_server; 73185732ac8SCy Schubert int dhcp_rapid_commit_proxy; 73285732ac8SCy Schubert unsigned int fils_hlp_wait_time; 73385732ac8SCy Schubert u16 dhcp_server_port; 73485732ac8SCy Schubert u16 dhcp_relay_port; 735c1d255d3SCy Schubert u32 fils_discovery_min_int; 736c1d255d3SCy Schubert u32 fils_discovery_max_int; 73785732ac8SCy Schubert #endif /* CONFIG_FILS */ 73885732ac8SCy Schubert 73985732ac8SCy Schubert int multicast_to_unicast; 74085732ac8SCy Schubert 74185732ac8SCy Schubert int broadcast_deauth; 74285732ac8SCy Schubert 743c1d255d3SCy Schubert int notify_mgmt_frames; 744c1d255d3SCy Schubert 74585732ac8SCy Schubert #ifdef CONFIG_DPP 746c1d255d3SCy Schubert char *dpp_name; 747c1d255d3SCy Schubert char *dpp_mud_url; 74885732ac8SCy Schubert char *dpp_connector; 74985732ac8SCy Schubert struct wpabuf *dpp_netaccesskey; 75085732ac8SCy Schubert unsigned int dpp_netaccesskey_expiry; 75185732ac8SCy Schubert struct wpabuf *dpp_csign; 752206b73d0SCy Schubert #ifdef CONFIG_DPP2 753206b73d0SCy Schubert struct dpp_controller_conf *dpp_controller; 754c1d255d3SCy Schubert int dpp_configurator_connectivity; 755c1d255d3SCy Schubert int dpp_pfs; 756206b73d0SCy Schubert #endif /* CONFIG_DPP2 */ 75785732ac8SCy Schubert #endif /* CONFIG_DPP */ 75885732ac8SCy Schubert 75985732ac8SCy Schubert #ifdef CONFIG_OWE 76085732ac8SCy Schubert macaddr owe_transition_bssid; 76185732ac8SCy Schubert u8 owe_transition_ssid[SSID_MAX_LEN]; 76285732ac8SCy Schubert size_t owe_transition_ssid_len; 76385732ac8SCy Schubert char owe_transition_ifname[IFNAMSIZ + 1]; 76485732ac8SCy Schubert int *owe_groups; 765c1d255d3SCy Schubert int owe_ptk_workaround; 76685732ac8SCy Schubert #endif /* CONFIG_OWE */ 76785732ac8SCy Schubert 76885732ac8SCy Schubert int coloc_intf_reporting; 7694bc52338SCy Schubert 7704bc52338SCy Schubert u8 send_probe_response; 7714bc52338SCy Schubert 772c1d255d3SCy Schubert u8 transition_disable; 773c1d255d3SCy Schubert 7744bc52338SCy Schubert #define BACKHAUL_BSS 1 7754bc52338SCy Schubert #define FRONTHAUL_BSS 2 7764bc52338SCy Schubert int multi_ap; /* bitmap of BACKHAUL_BSS, FRONTHAUL_BSS */ 777206b73d0SCy Schubert 778206b73d0SCy Schubert #ifdef CONFIG_AIRTIME_POLICY 779206b73d0SCy Schubert unsigned int airtime_weight; 780206b73d0SCy Schubert int airtime_limit; 781206b73d0SCy Schubert struct airtime_sta_weight *airtime_weight_list; 782206b73d0SCy Schubert #endif /* CONFIG_AIRTIME_POLICY */ 783206b73d0SCy Schubert 784206b73d0SCy Schubert #ifdef CONFIG_MACSEC 785206b73d0SCy Schubert /** 786206b73d0SCy Schubert * macsec_policy - Determines the policy for MACsec secure session 787206b73d0SCy Schubert * 788206b73d0SCy Schubert * 0: MACsec not in use (default) 789206b73d0SCy Schubert * 1: MACsec enabled - Should secure, accept key server's advice to 790206b73d0SCy Schubert * determine whether to use a secure session or not. 791206b73d0SCy Schubert */ 792206b73d0SCy Schubert int macsec_policy; 793206b73d0SCy Schubert 794206b73d0SCy Schubert /** 795206b73d0SCy Schubert * macsec_integ_only - Determines how MACsec are transmitted 796206b73d0SCy Schubert * 797206b73d0SCy Schubert * This setting applies only when MACsec is in use, i.e., 798206b73d0SCy Schubert * - macsec_policy is enabled 799206b73d0SCy Schubert * - the key server has decided to enable MACsec 800206b73d0SCy Schubert * 801206b73d0SCy Schubert * 0: Encrypt traffic (default) 802206b73d0SCy Schubert * 1: Integrity only 803206b73d0SCy Schubert */ 804206b73d0SCy Schubert int macsec_integ_only; 805206b73d0SCy Schubert 806206b73d0SCy Schubert /** 807206b73d0SCy Schubert * macsec_replay_protect - Enable MACsec replay protection 808206b73d0SCy Schubert * 809206b73d0SCy Schubert * This setting applies only when MACsec is in use, i.e., 810206b73d0SCy Schubert * - macsec_policy is enabled 811206b73d0SCy Schubert * - the key server has decided to enable MACsec 812206b73d0SCy Schubert * 813206b73d0SCy Schubert * 0: Replay protection disabled (default) 814206b73d0SCy Schubert * 1: Replay protection enabled 815206b73d0SCy Schubert */ 816206b73d0SCy Schubert int macsec_replay_protect; 817206b73d0SCy Schubert 818206b73d0SCy Schubert /** 819206b73d0SCy Schubert * macsec_replay_window - MACsec replay protection window 820206b73d0SCy Schubert * 821206b73d0SCy Schubert * A window in which replay is tolerated, to allow receipt of frames 822206b73d0SCy Schubert * that have been misordered by the network. 823206b73d0SCy Schubert * 824206b73d0SCy Schubert * This setting applies only when MACsec replay protection active, i.e., 825206b73d0SCy Schubert * - macsec_replay_protect is enabled 826206b73d0SCy Schubert * - the key server has decided to enable MACsec 827206b73d0SCy Schubert * 828206b73d0SCy Schubert * 0: No replay window, strict check (default) 829206b73d0SCy Schubert * 1..2^32-1: number of packets that could be misordered 830206b73d0SCy Schubert */ 831206b73d0SCy Schubert u32 macsec_replay_window; 832206b73d0SCy Schubert 833206b73d0SCy Schubert /** 834206b73d0SCy Schubert * macsec_port - MACsec port (in SCI) 835206b73d0SCy Schubert * 836206b73d0SCy Schubert * Port component of the SCI. 837206b73d0SCy Schubert * 838206b73d0SCy Schubert * Range: 1-65534 (default: 1) 839206b73d0SCy Schubert */ 840206b73d0SCy Schubert int macsec_port; 841206b73d0SCy Schubert 842206b73d0SCy Schubert /** 843206b73d0SCy Schubert * mka_priority - Priority of MKA Actor 844206b73d0SCy Schubert * 845206b73d0SCy Schubert * Range: 0-255 (default: 255) 846206b73d0SCy Schubert */ 847206b73d0SCy Schubert int mka_priority; 848206b73d0SCy Schubert 849206b73d0SCy Schubert /** 850206b73d0SCy Schubert * mka_ckn - MKA pre-shared CKN 851206b73d0SCy Schubert */ 852206b73d0SCy Schubert #define MACSEC_CKN_MAX_LEN 32 853206b73d0SCy Schubert size_t mka_ckn_len; 854206b73d0SCy Schubert u8 mka_ckn[MACSEC_CKN_MAX_LEN]; 855206b73d0SCy Schubert 856206b73d0SCy Schubert /** 857206b73d0SCy Schubert * mka_cak - MKA pre-shared CAK 858206b73d0SCy Schubert */ 859206b73d0SCy Schubert #define MACSEC_CAK_MAX_LEN 32 860206b73d0SCy Schubert size_t mka_cak_len; 861206b73d0SCy Schubert u8 mka_cak[MACSEC_CAK_MAX_LEN]; 862206b73d0SCy Schubert 863206b73d0SCy Schubert #define MKA_PSK_SET_CKN BIT(0) 864206b73d0SCy Schubert #define MKA_PSK_SET_CAK BIT(1) 865206b73d0SCy Schubert #define MKA_PSK_SET (MKA_PSK_SET_CKN | MKA_PSK_SET_CAK) 866206b73d0SCy Schubert /** 867206b73d0SCy Schubert * mka_psk_set - Whether mka_ckn and mka_cak are set 868206b73d0SCy Schubert */ 869206b73d0SCy Schubert u8 mka_psk_set; 870206b73d0SCy Schubert #endif /* CONFIG_MACSEC */ 871c1d255d3SCy Schubert 872c1d255d3SCy Schubert #ifdef CONFIG_PASN 873c1d255d3SCy Schubert #ifdef CONFIG_TESTING_OPTIONS 874c1d255d3SCy Schubert /* 875c1d255d3SCy Schubert * Normally, KDK should be derived if and only if both sides support 876c1d255d3SCy Schubert * secure LTF. Allow forcing KDK derivation for testing purposes. 877c1d255d3SCy Schubert */ 878c1d255d3SCy Schubert int force_kdk_derivation; 879c1d255d3SCy Schubert 880c1d255d3SCy Schubert /* If set, corrupt the MIC in the 2nd Authentication frame of PASN */ 881c1d255d3SCy Schubert int pasn_corrupt_mic; 882c1d255d3SCy Schubert #endif /* CONFIG_TESTING_OPTIONS */ 883c1d255d3SCy Schubert 884c1d255d3SCy Schubert int *pasn_groups; 885c1d255d3SCy Schubert 886c1d255d3SCy Schubert /* 887c1d255d3SCy Schubert * The time in TUs after which the non-AP STA is requested to retry the 888c1d255d3SCy Schubert * PASN authentication in case there are too many parallel operations. 889c1d255d3SCy Schubert */ 890c1d255d3SCy Schubert u16 pasn_comeback_after; 891c1d255d3SCy Schubert #endif /* CONFIG_PASN */ 892c1d255d3SCy Schubert 893c1d255d3SCy Schubert unsigned int unsol_bcast_probe_resp_interval; 894c1d255d3SCy Schubert 895c1d255d3SCy Schubert u8 ext_capa_mask[EXT_CAPA_MAX_LEN]; 896c1d255d3SCy Schubert u8 ext_capa[EXT_CAPA_MAX_LEN]; 897*4b72b91aSCy Schubert 898*4b72b91aSCy Schubert u8 rnr; 899e28a4053SRui Paulo }; 900e28a4053SRui Paulo 90185732ac8SCy Schubert /** 90285732ac8SCy Schubert * struct he_phy_capabilities_info - HE PHY capabilities 90385732ac8SCy Schubert */ 90485732ac8SCy Schubert struct he_phy_capabilities_info { 905c1d255d3SCy Schubert bool he_su_beamformer; 906c1d255d3SCy Schubert bool he_su_beamformee; 907c1d255d3SCy Schubert bool he_mu_beamformer; 90885732ac8SCy Schubert }; 90985732ac8SCy Schubert 91085732ac8SCy Schubert /** 91185732ac8SCy Schubert * struct he_operation - HE operation 91285732ac8SCy Schubert */ 91385732ac8SCy Schubert struct he_operation { 91485732ac8SCy Schubert u8 he_bss_color; 915c1d255d3SCy Schubert u8 he_bss_color_disabled; 916c1d255d3SCy Schubert u8 he_bss_color_partial; 91785732ac8SCy Schubert u8 he_default_pe_duration; 91885732ac8SCy Schubert u8 he_twt_required; 919c1d255d3SCy Schubert u8 he_twt_responder; 920206b73d0SCy Schubert u16 he_rts_threshold; 921*4b72b91aSCy Schubert u8 he_er_su_disable; 922206b73d0SCy Schubert u16 he_basic_mcs_nss_set; 923206b73d0SCy Schubert }; 924206b73d0SCy Schubert 925206b73d0SCy Schubert /** 926206b73d0SCy Schubert * struct spatial_reuse - Spatial reuse 927206b73d0SCy Schubert */ 928206b73d0SCy Schubert struct spatial_reuse { 929206b73d0SCy Schubert u8 sr_control; 930206b73d0SCy Schubert u8 non_srg_obss_pd_max_offset; 931206b73d0SCy Schubert u8 srg_obss_pd_min_offset; 932206b73d0SCy Schubert u8 srg_obss_pd_max_offset; 933c1d255d3SCy Schubert u8 srg_bss_color_bitmap[8]; 934c1d255d3SCy Schubert u8 srg_partial_bssid_bitmap[8]; 93585732ac8SCy Schubert }; 936e28a4053SRui Paulo 937e28a4053SRui Paulo /** 938e28a4053SRui Paulo * struct hostapd_config - Per-radio interface configuration 939e28a4053SRui Paulo */ 940e28a4053SRui Paulo struct hostapd_config { 9415b9c547cSRui Paulo struct hostapd_bss_config **bss, *last_bss; 942e28a4053SRui Paulo size_t num_bss; 943e28a4053SRui Paulo 944e28a4053SRui Paulo u16 beacon_int; 945e28a4053SRui Paulo int rts_threshold; 946e28a4053SRui Paulo int fragm_threshold; 947c1d255d3SCy Schubert u8 op_class; 948e28a4053SRui Paulo u8 channel; 949c1d255d3SCy Schubert int enable_edmg; 950c1d255d3SCy Schubert u8 edmg_channel; 951325151a3SRui Paulo u8 acs; 952325151a3SRui Paulo struct wpa_freq_range_list acs_ch_list; 953c1d255d3SCy Schubert struct wpa_freq_range_list acs_freq_list; 954c1d255d3SCy Schubert u8 acs_freq_list_present; 95585732ac8SCy Schubert int acs_exclude_dfs; 956e28a4053SRui Paulo enum hostapd_hw_mode hw_mode; /* HOSTAPD_MODE_IEEE80211A, .. */ 957c1d255d3SCy Schubert int acs_exclude_6ghz_non_psc; 958e28a4053SRui Paulo enum { 959e28a4053SRui Paulo LONG_PREAMBLE = 0, 960e28a4053SRui Paulo SHORT_PREAMBLE = 1 961e28a4053SRui Paulo } preamble; 962e28a4053SRui Paulo 963e28a4053SRui Paulo int *supported_rates; 964e28a4053SRui Paulo int *basic_rates; 96585732ac8SCy Schubert unsigned int beacon_rate; 96685732ac8SCy Schubert enum beacon_rate_type rate_type; 967e28a4053SRui Paulo 968e28a4053SRui Paulo const struct wpa_driver_ops *driver; 9695b9c547cSRui Paulo char *driver_params; 970e28a4053SRui Paulo 971e28a4053SRui Paulo int ap_table_max_size; 972e28a4053SRui Paulo int ap_table_expiration_time; 973e28a4053SRui Paulo 974325151a3SRui Paulo unsigned int track_sta_max_num; 975325151a3SRui Paulo unsigned int track_sta_max_age; 976325151a3SRui Paulo 977e28a4053SRui Paulo char country[3]; /* first two octets: country code as described in 978e28a4053SRui Paulo * ISO/IEC 3166-1. Third octet: 979e28a4053SRui Paulo * ' ' (ascii 32): all environments 980e28a4053SRui Paulo * 'O': Outdoor environemnt only 981e28a4053SRui Paulo * 'I': Indoor environment only 98285732ac8SCy Schubert * 'X': Used with noncountry entity ("XXX") 98385732ac8SCy Schubert * 0x00..0x31: identifying IEEE 802.11 standard 98485732ac8SCy Schubert * Annex E table (0x04 = global table) 985e28a4053SRui Paulo */ 986e28a4053SRui Paulo 987e28a4053SRui Paulo int ieee80211d; 988e28a4053SRui Paulo 9895b9c547cSRui Paulo int ieee80211h; /* DFS */ 9905b9c547cSRui Paulo 9915b9c547cSRui Paulo /* 9925b9c547cSRui Paulo * Local power constraint is an octet encoded as an unsigned integer in 9935b9c547cSRui Paulo * units of decibels. Invalid value -1 indicates that Power Constraint 9945b9c547cSRui Paulo * element will not be added. 9955b9c547cSRui Paulo */ 9965b9c547cSRui Paulo int local_pwr_constraint; 9975b9c547cSRui Paulo 9985b9c547cSRui Paulo /* Control Spectrum Management bit */ 9995b9c547cSRui Paulo int spectrum_mgmt_required; 10005b9c547cSRui Paulo 1001e28a4053SRui Paulo struct hostapd_tx_queue_params tx_queue[NUM_TX_QUEUES]; 1002e28a4053SRui Paulo 1003e28a4053SRui Paulo /* 1004e28a4053SRui Paulo * WMM AC parameters, in same order as 802.1D, i.e. 1005e28a4053SRui Paulo * 0 = BE (best effort) 1006e28a4053SRui Paulo * 1 = BK (background) 1007e28a4053SRui Paulo * 2 = VI (video) 1008e28a4053SRui Paulo * 3 = VO (voice) 1009e28a4053SRui Paulo */ 1010e28a4053SRui Paulo struct hostapd_wmm_ac_params wmm_ac_params[4]; 1011e28a4053SRui Paulo 1012e28a4053SRui Paulo int ht_op_mode_fixed; 1013e28a4053SRui Paulo u16 ht_capab; 1014e28a4053SRui Paulo int ieee80211n; 1015e28a4053SRui Paulo int secondary_channel; 1016325151a3SRui Paulo int no_pri_sec_switch; 1017f05cddf9SRui Paulo int require_ht; 10185b9c547cSRui Paulo int obss_interval; 1019f05cddf9SRui Paulo u32 vht_capab; 1020f05cddf9SRui Paulo int ieee80211ac; 1021f05cddf9SRui Paulo int require_vht; 1022f05cddf9SRui Paulo u8 vht_oper_chwidth; 1023f05cddf9SRui Paulo u8 vht_oper_centr_freq_seg0_idx; 1024f05cddf9SRui Paulo u8 vht_oper_centr_freq_seg1_idx; 102585732ac8SCy Schubert u8 ht40_plus_minus_allowed; 10265b9c547cSRui Paulo 1027780fb4a2SCy Schubert /* Use driver-generated interface addresses when adding multiple BSSs */ 1028780fb4a2SCy Schubert u8 use_driver_iface_addr; 1029780fb4a2SCy Schubert 1030325151a3SRui Paulo #ifdef CONFIG_FST 1031325151a3SRui Paulo struct fst_iface_cfg fst_cfg; 1032325151a3SRui Paulo #endif /* CONFIG_FST */ 1033325151a3SRui Paulo 10345b9c547cSRui Paulo #ifdef CONFIG_P2P 10355b9c547cSRui Paulo u8 p2p_go_ctwindow; 10365b9c547cSRui Paulo #endif /* CONFIG_P2P */ 10375b9c547cSRui Paulo 10385b9c547cSRui Paulo #ifdef CONFIG_TESTING_OPTIONS 10395b9c547cSRui Paulo double ignore_probe_probability; 10405b9c547cSRui Paulo double ignore_auth_probability; 10415b9c547cSRui Paulo double ignore_assoc_probability; 10425b9c547cSRui Paulo double ignore_reassoc_probability; 10435b9c547cSRui Paulo double corrupt_gtk_rekey_mic_probability; 1044780fb4a2SCy Schubert int ecsa_ie_only; 10455b9c547cSRui Paulo #endif /* CONFIG_TESTING_OPTIONS */ 10465b9c547cSRui Paulo 10475b9c547cSRui Paulo #ifdef CONFIG_ACS 10485b9c547cSRui Paulo unsigned int acs_num_scans; 10495b9c547cSRui Paulo struct acs_bias { 10505b9c547cSRui Paulo int channel; 10515b9c547cSRui Paulo double bias; 10525b9c547cSRui Paulo } *acs_chan_bias; 10535b9c547cSRui Paulo unsigned int num_acs_chan_bias; 10545b9c547cSRui Paulo #endif /* CONFIG_ACS */ 1055780fb4a2SCy Schubert 1056780fb4a2SCy Schubert struct wpabuf *lci; 1057780fb4a2SCy Schubert struct wpabuf *civic; 105885732ac8SCy Schubert int stationary_ap; 105985732ac8SCy Schubert 106085732ac8SCy Schubert int ieee80211ax; 106185732ac8SCy Schubert #ifdef CONFIG_IEEE80211AX 106285732ac8SCy Schubert struct he_phy_capabilities_info he_phy_capab; 106385732ac8SCy Schubert struct he_operation he_op; 10644bc52338SCy Schubert struct ieee80211_he_mu_edca_parameter_set he_mu_edca; 1065206b73d0SCy Schubert struct spatial_reuse spr; 1066206b73d0SCy Schubert u8 he_oper_chwidth; 1067206b73d0SCy Schubert u8 he_oper_centr_freq_seg0_idx; 1068206b73d0SCy Schubert u8 he_oper_centr_freq_seg1_idx; 1069c1d255d3SCy Schubert u8 he_6ghz_max_mpdu; 1070c1d255d3SCy Schubert u8 he_6ghz_max_ampdu_len_exp; 1071c1d255d3SCy Schubert u8 he_6ghz_rx_ant_pat; 1072c1d255d3SCy Schubert u8 he_6ghz_tx_ant_pat; 107385732ac8SCy Schubert #endif /* CONFIG_IEEE80211AX */ 107485732ac8SCy Schubert 107585732ac8SCy Schubert /* VHT enable/disable config from CHAN_SWITCH */ 107685732ac8SCy Schubert #define CH_SWITCH_VHT_ENABLED BIT(0) 107785732ac8SCy Schubert #define CH_SWITCH_VHT_DISABLED BIT(1) 107885732ac8SCy Schubert unsigned int ch_switch_vht_config; 10794bc52338SCy Schubert 1080c1d255d3SCy Schubert /* HE enable/disable config from CHAN_SWITCH */ 1081c1d255d3SCy Schubert #define CH_SWITCH_HE_ENABLED BIT(0) 1082c1d255d3SCy Schubert #define CH_SWITCH_HE_DISABLED BIT(1) 1083c1d255d3SCy Schubert unsigned int ch_switch_he_config; 1084c1d255d3SCy Schubert 10854bc52338SCy Schubert int rssi_reject_assoc_rssi; 10864bc52338SCy Schubert int rssi_reject_assoc_timeout; 1087c1d255d3SCy Schubert int rssi_ignore_probe_request; 1088206b73d0SCy Schubert 1089206b73d0SCy Schubert #ifdef CONFIG_AIRTIME_POLICY 1090206b73d0SCy Schubert enum { 1091206b73d0SCy Schubert AIRTIME_MODE_OFF = 0, 1092206b73d0SCy Schubert AIRTIME_MODE_STATIC = 1, 1093206b73d0SCy Schubert AIRTIME_MODE_DYNAMIC = 2, 1094206b73d0SCy Schubert AIRTIME_MODE_LIMIT = 3, 1095206b73d0SCy Schubert __AIRTIME_MODE_MAX, 1096206b73d0SCy Schubert } airtime_mode; 1097206b73d0SCy Schubert unsigned int airtime_update_interval; 1098206b73d0SCy Schubert #define AIRTIME_MODE_MAX (__AIRTIME_MODE_MAX - 1) 1099206b73d0SCy Schubert #endif /* CONFIG_AIRTIME_POLICY */ 1100e28a4053SRui Paulo }; 1101e28a4053SRui Paulo 1102e28a4053SRui Paulo 1103206b73d0SCy Schubert static inline u8 hostapd_get_oper_chwidth(struct hostapd_config *conf) 1104206b73d0SCy Schubert { 1105206b73d0SCy Schubert #ifdef CONFIG_IEEE80211AX 1106206b73d0SCy Schubert if (conf->ieee80211ax) 1107206b73d0SCy Schubert return conf->he_oper_chwidth; 1108206b73d0SCy Schubert #endif /* CONFIG_IEEE80211AX */ 1109206b73d0SCy Schubert return conf->vht_oper_chwidth; 1110206b73d0SCy Schubert } 1111206b73d0SCy Schubert 1112206b73d0SCy Schubert static inline void 1113206b73d0SCy Schubert hostapd_set_oper_chwidth(struct hostapd_config *conf, u8 oper_chwidth) 1114206b73d0SCy Schubert { 1115206b73d0SCy Schubert #ifdef CONFIG_IEEE80211AX 1116206b73d0SCy Schubert if (conf->ieee80211ax) 1117206b73d0SCy Schubert conf->he_oper_chwidth = oper_chwidth; 1118206b73d0SCy Schubert #endif /* CONFIG_IEEE80211AX */ 1119206b73d0SCy Schubert conf->vht_oper_chwidth = oper_chwidth; 1120206b73d0SCy Schubert } 1121206b73d0SCy Schubert 1122206b73d0SCy Schubert static inline u8 1123206b73d0SCy Schubert hostapd_get_oper_centr_freq_seg0_idx(struct hostapd_config *conf) 1124206b73d0SCy Schubert { 1125206b73d0SCy Schubert #ifdef CONFIG_IEEE80211AX 1126206b73d0SCy Schubert if (conf->ieee80211ax) 1127206b73d0SCy Schubert return conf->he_oper_centr_freq_seg0_idx; 1128206b73d0SCy Schubert #endif /* CONFIG_IEEE80211AX */ 1129206b73d0SCy Schubert return conf->vht_oper_centr_freq_seg0_idx; 1130206b73d0SCy Schubert } 1131206b73d0SCy Schubert 1132206b73d0SCy Schubert static inline void 1133206b73d0SCy Schubert hostapd_set_oper_centr_freq_seg0_idx(struct hostapd_config *conf, 1134206b73d0SCy Schubert u8 oper_centr_freq_seg0_idx) 1135206b73d0SCy Schubert { 1136206b73d0SCy Schubert #ifdef CONFIG_IEEE80211AX 1137206b73d0SCy Schubert if (conf->ieee80211ax) 1138206b73d0SCy Schubert conf->he_oper_centr_freq_seg0_idx = oper_centr_freq_seg0_idx; 1139206b73d0SCy Schubert #endif /* CONFIG_IEEE80211AX */ 1140206b73d0SCy Schubert conf->vht_oper_centr_freq_seg0_idx = oper_centr_freq_seg0_idx; 1141206b73d0SCy Schubert } 1142206b73d0SCy Schubert 1143206b73d0SCy Schubert static inline u8 1144206b73d0SCy Schubert hostapd_get_oper_centr_freq_seg1_idx(struct hostapd_config *conf) 1145206b73d0SCy Schubert { 1146206b73d0SCy Schubert #ifdef CONFIG_IEEE80211AX 1147206b73d0SCy Schubert if (conf->ieee80211ax) 1148206b73d0SCy Schubert return conf->he_oper_centr_freq_seg1_idx; 1149206b73d0SCy Schubert #endif /* CONFIG_IEEE80211AX */ 1150206b73d0SCy Schubert return conf->vht_oper_centr_freq_seg1_idx; 1151206b73d0SCy Schubert } 1152206b73d0SCy Schubert 1153206b73d0SCy Schubert static inline void 1154206b73d0SCy Schubert hostapd_set_oper_centr_freq_seg1_idx(struct hostapd_config *conf, 1155206b73d0SCy Schubert u8 oper_centr_freq_seg1_idx) 1156206b73d0SCy Schubert { 1157206b73d0SCy Schubert #ifdef CONFIG_IEEE80211AX 1158206b73d0SCy Schubert if (conf->ieee80211ax) 1159206b73d0SCy Schubert conf->he_oper_centr_freq_seg1_idx = oper_centr_freq_seg1_idx; 1160206b73d0SCy Schubert #endif /* CONFIG_IEEE80211AX */ 1161206b73d0SCy Schubert conf->vht_oper_centr_freq_seg1_idx = oper_centr_freq_seg1_idx; 1162206b73d0SCy Schubert } 1163206b73d0SCy Schubert 1164206b73d0SCy Schubert 1165e28a4053SRui Paulo int hostapd_mac_comp(const void *a, const void *b); 1166e28a4053SRui Paulo struct hostapd_config * hostapd_config_defaults(void); 1167e28a4053SRui Paulo void hostapd_config_defaults_bss(struct hostapd_bss_config *bss); 1168206b73d0SCy Schubert void hostapd_config_free_radius_attr(struct hostapd_radius_attr *attr); 11695b9c547cSRui Paulo void hostapd_config_free_eap_user(struct hostapd_eap_user *user); 117085732ac8SCy Schubert void hostapd_config_free_eap_users(struct hostapd_eap_user *user); 11715b9c547cSRui Paulo void hostapd_config_clear_wpa_psk(struct hostapd_wpa_psk **p); 11725b9c547cSRui Paulo void hostapd_config_free_bss(struct hostapd_bss_config *conf); 1173e28a4053SRui Paulo void hostapd_config_free(struct hostapd_config *conf); 1174e28a4053SRui Paulo int hostapd_maclist_found(struct mac_acl_entry *list, int num_entries, 1175780fb4a2SCy Schubert const u8 *addr, struct vlan_description *vlan_id); 1176e28a4053SRui Paulo int hostapd_rate_found(int *list, int rate); 1177e28a4053SRui Paulo const u8 * hostapd_get_psk(const struct hostapd_bss_config *conf, 11785b9c547cSRui Paulo const u8 *addr, const u8 *p2p_dev_addr, 11794bc52338SCy Schubert const u8 *prev_psk, int *vlan_id); 1180e28a4053SRui Paulo int hostapd_setup_wpa_psk(struct hostapd_bss_config *conf); 1181780fb4a2SCy Schubert int hostapd_vlan_valid(struct hostapd_vlan *vlan, 1182780fb4a2SCy Schubert struct vlan_description *vlan_desc); 1183e28a4053SRui Paulo const char * hostapd_get_vlan_id_ifname(struct hostapd_vlan *vlan, 1184e28a4053SRui Paulo int vlan_id); 1185f05cddf9SRui Paulo struct hostapd_radius_attr * 1186f05cddf9SRui Paulo hostapd_config_get_radius_attr(struct hostapd_radius_attr *attr, u8 type); 1187206b73d0SCy Schubert struct hostapd_radius_attr * hostapd_parse_radius_attr(const char *value); 11885b9c547cSRui Paulo int hostapd_config_check(struct hostapd_config *conf, int full_config); 11895b9c547cSRui Paulo void hostapd_set_security_params(struct hostapd_bss_config *bss, 11905b9c547cSRui Paulo int full_config); 11914bc52338SCy Schubert int hostapd_sae_pw_id_in_use(struct hostapd_bss_config *conf); 1192c1d255d3SCy Schubert bool hostapd_sae_pk_in_use(struct hostapd_bss_config *conf); 1193c1d255d3SCy Schubert bool hostapd_sae_pk_exclusively(struct hostapd_bss_config *conf); 1194c1d255d3SCy Schubert int hostapd_setup_sae_pt(struct hostapd_bss_config *conf); 1195e28a4053SRui Paulo 1196e28a4053SRui Paulo #endif /* HOSTAPD_CONFIG_H */ 1197