139beb93cSSam Leffler /* 239beb93cSSam Leffler * WPA Supplicant / Configuration file structures 3f05cddf9SRui Paulo * Copyright (c) 2003-2012, Jouni Malinen <j@w1.fi> 439beb93cSSam Leffler * 5f05cddf9SRui Paulo * This software may be distributed under the terms of the BSD license. 6f05cddf9SRui Paulo * See README for more details. 739beb93cSSam Leffler */ 839beb93cSSam Leffler 939beb93cSSam Leffler #ifndef CONFIG_H 1039beb93cSSam Leffler #define CONFIG_H 1139beb93cSSam Leffler 1239beb93cSSam Leffler #define DEFAULT_EAPOL_VERSION 1 1339beb93cSSam Leffler #ifdef CONFIG_NO_SCAN_PROCESSING 1439beb93cSSam Leffler #define DEFAULT_AP_SCAN 2 1539beb93cSSam Leffler #else /* CONFIG_NO_SCAN_PROCESSING */ 1639beb93cSSam Leffler #define DEFAULT_AP_SCAN 1 1739beb93cSSam Leffler #endif /* CONFIG_NO_SCAN_PROCESSING */ 185b9c547cSRui Paulo #define DEFAULT_USER_MPM 1 195b9c547cSRui Paulo #define DEFAULT_MAX_PEER_LINKS 99 205b9c547cSRui Paulo #define DEFAULT_MESH_MAX_INACTIVITY 300 2132a95656SCy Schubert #define DEFAULT_MESH_FWDING 1 22325151a3SRui Paulo /* 23325151a3SRui Paulo * The default dot11RSNASAERetransPeriod is defined as 40 ms in the standard, 24325151a3SRui Paulo * but use 1000 ms in practice to avoid issues on low power CPUs. 25325151a3SRui Paulo */ 26325151a3SRui Paulo #define DEFAULT_DOT11_RSNA_SAE_RETRANS_PERIOD 1000 2739beb93cSSam Leffler #define DEFAULT_FAST_REAUTH 1 28f05cddf9SRui Paulo #define DEFAULT_P2P_GO_INTENT 7 29f05cddf9SRui Paulo #define DEFAULT_P2P_INTRA_BSS 1 30f05cddf9SRui Paulo #define DEFAULT_P2P_GO_MAX_INACTIVITY (5 * 60) 315b9c547cSRui Paulo #define DEFAULT_P2P_OPTIMIZE_LISTEN_CHAN 0 32e28a4053SRui Paulo #define DEFAULT_BSS_MAX_COUNT 200 33f05cddf9SRui Paulo #define DEFAULT_BSS_EXPIRATION_AGE 180 34f05cddf9SRui Paulo #define DEFAULT_BSS_EXPIRATION_SCAN_COUNT 2 35f05cddf9SRui Paulo #define DEFAULT_MAX_NUM_STA 128 3685732ac8SCy Schubert #define DEFAULT_AP_ISOLATE 0 37f05cddf9SRui Paulo #define DEFAULT_ACCESS_NETWORK_TYPE 15 385b9c547cSRui Paulo #define DEFAULT_SCAN_CUR_FREQ 0 395b9c547cSRui Paulo #define DEFAULT_P2P_SEARCH_DELAY 500 405b9c547cSRui Paulo #define DEFAULT_RAND_ADDR_LIFETIME 60 415b9c547cSRui Paulo #define DEFAULT_KEY_MGMT_OFFLOAD 1 425b9c547cSRui Paulo #define DEFAULT_CERT_IN_CB 1 435b9c547cSRui Paulo #define DEFAULT_P2P_GO_CTWINDOW 0 44780fb4a2SCy Schubert #define DEFAULT_WPA_RSC_RELAXATION 1 45780fb4a2SCy Schubert #define DEFAULT_MBO_CELL_CAPA MBO_CELL_CAPA_NOT_SUPPORTED 4685732ac8SCy Schubert #define DEFAULT_DISASSOC_IMMINENT_RSSI_THRESHOLD -75 4785732ac8SCy Schubert #define DEFAULT_OCE_SUPPORT OCE_STA 48c1d255d3SCy Schubert #define DEFAULT_EXTENDED_KEY_ID 0 49c1d255d3SCy Schubert #define DEFAULT_SCAN_RES_VALID_FOR_CONNECT 5 50*a90b9d01SCy Schubert #define DEFAULT_MLD_CONNECT_BAND_PREF MLD_CONNECT_BAND_PREF_AUTO 5139beb93cSSam Leffler 5239beb93cSSam Leffler #include "config_ssid.h" 53f05cddf9SRui Paulo #include "wps/wps.h" 54325151a3SRui Paulo #include "common/ieee802_11_defs.h" 55f05cddf9SRui Paulo #include "common/ieee802_11_common.h" 5639beb93cSSam Leffler 5739beb93cSSam Leffler 5885732ac8SCy Schubert #define MAX_ROAMING_CONS 36 5985732ac8SCy Schubert #define MAX_ROAMING_CONS_OI_LEN 15 6085732ac8SCy Schubert 61f05cddf9SRui Paulo struct wpa_cred { 62f05cddf9SRui Paulo /** 63f05cddf9SRui Paulo * next - Next credential in the list 64f05cddf9SRui Paulo * 65f05cddf9SRui Paulo * This pointer can be used to iterate over all credentials. The head 66f05cddf9SRui Paulo * of this list is stored in the cred field of struct wpa_config. 67f05cddf9SRui Paulo */ 68f05cddf9SRui Paulo struct wpa_cred *next; 69f05cddf9SRui Paulo 70f05cddf9SRui Paulo /** 71f05cddf9SRui Paulo * id - Unique id for the credential 72f05cddf9SRui Paulo * 73f05cddf9SRui Paulo * This identifier is used as a unique identifier for each credential 74f05cddf9SRui Paulo * block when using the control interface. Each credential is allocated 75f05cddf9SRui Paulo * an id when it is being created, either when reading the 76f05cddf9SRui Paulo * configuration file or when a new credential is added through the 77f05cddf9SRui Paulo * control interface. 78f05cddf9SRui Paulo */ 79f05cddf9SRui Paulo int id; 80f05cddf9SRui Paulo 81f05cddf9SRui Paulo /** 825b9c547cSRui Paulo * temporary - Whether this credential is temporary and not to be saved 835b9c547cSRui Paulo */ 845b9c547cSRui Paulo int temporary; 855b9c547cSRui Paulo 865b9c547cSRui Paulo /** 87f05cddf9SRui Paulo * priority - Priority group 88f05cddf9SRui Paulo * 89f05cddf9SRui Paulo * By default, all networks and credentials get the same priority group 90f05cddf9SRui Paulo * (0). This field can be used to give higher priority for credentials 91f05cddf9SRui Paulo * (and similarly in struct wpa_ssid for network blocks) to change the 92f05cddf9SRui Paulo * Interworking automatic networking selection behavior. The matching 93f05cddf9SRui Paulo * network (based on either an enabled network block or a credential) 94f05cddf9SRui Paulo * with the highest priority value will be selected. 95f05cddf9SRui Paulo */ 96f05cddf9SRui Paulo int priority; 97f05cddf9SRui Paulo 98f05cddf9SRui Paulo /** 99f05cddf9SRui Paulo * pcsc - Use PC/SC and SIM/USIM card 100f05cddf9SRui Paulo */ 101f05cddf9SRui Paulo int pcsc; 102f05cddf9SRui Paulo 103f05cddf9SRui Paulo /** 104f05cddf9SRui Paulo * realm - Home Realm for Interworking 105f05cddf9SRui Paulo */ 106f05cddf9SRui Paulo char *realm; 107f05cddf9SRui Paulo 108f05cddf9SRui Paulo /** 109f05cddf9SRui Paulo * username - Username for Interworking network selection 110f05cddf9SRui Paulo */ 111f05cddf9SRui Paulo char *username; 112f05cddf9SRui Paulo 113f05cddf9SRui Paulo /** 114f05cddf9SRui Paulo * password - Password for Interworking network selection 115f05cddf9SRui Paulo */ 116f05cddf9SRui Paulo char *password; 117f05cddf9SRui Paulo 118f05cddf9SRui Paulo /** 119f05cddf9SRui Paulo * ext_password - Whether password is a name for external storage 120f05cddf9SRui Paulo */ 121f05cddf9SRui Paulo int ext_password; 122f05cddf9SRui Paulo 123f05cddf9SRui Paulo /** 124f05cddf9SRui Paulo * ca_cert - CA certificate for Interworking network selection 125f05cddf9SRui Paulo */ 126f05cddf9SRui Paulo char *ca_cert; 127f05cddf9SRui Paulo 128f05cddf9SRui Paulo /** 129f05cddf9SRui Paulo * client_cert - File path to client certificate file (PEM/DER) 130f05cddf9SRui Paulo * 131f05cddf9SRui Paulo * This field is used with Interworking networking selection for a case 132f05cddf9SRui Paulo * where client certificate/private key is used for authentication 133f05cddf9SRui Paulo * (EAP-TLS). Full path to the file should be used since working 134f05cddf9SRui Paulo * directory may change when wpa_supplicant is run in the background. 135f05cddf9SRui Paulo * 136f05cddf9SRui Paulo * Alternatively, a named configuration blob can be used by setting 137f05cddf9SRui Paulo * this to blob://blob_name. 138f05cddf9SRui Paulo */ 139f05cddf9SRui Paulo char *client_cert; 140f05cddf9SRui Paulo 141f05cddf9SRui Paulo /** 142f05cddf9SRui Paulo * private_key - File path to client private key file (PEM/DER/PFX) 143f05cddf9SRui Paulo * 144f05cddf9SRui Paulo * When PKCS#12/PFX file (.p12/.pfx) is used, client_cert should be 145f05cddf9SRui Paulo * commented out. Both the private key and certificate will be read 146f05cddf9SRui Paulo * from the PKCS#12 file in this case. Full path to the file should be 147f05cddf9SRui Paulo * used since working directory may change when wpa_supplicant is run 148f05cddf9SRui Paulo * in the background. 149f05cddf9SRui Paulo * 150f05cddf9SRui Paulo * Windows certificate store can be used by leaving client_cert out and 151f05cddf9SRui Paulo * configuring private_key in one of the following formats: 152f05cddf9SRui Paulo * 153f05cddf9SRui Paulo * cert://substring_to_match 154f05cddf9SRui Paulo * 155f05cddf9SRui Paulo * hash://certificate_thumbprint_in_hex 156f05cddf9SRui Paulo * 157f05cddf9SRui Paulo * For example: private_key="hash://63093aa9c47f56ae88334c7b65a4" 158f05cddf9SRui Paulo * 159f05cddf9SRui Paulo * Note that when running wpa_supplicant as an application, the user 160f05cddf9SRui Paulo * certificate store (My user account) is used, whereas computer store 161f05cddf9SRui Paulo * (Computer account) is used when running wpasvc as a service. 162f05cddf9SRui Paulo * 163f05cddf9SRui Paulo * Alternatively, a named configuration blob can be used by setting 164f05cddf9SRui Paulo * this to blob://blob_name. 165f05cddf9SRui Paulo */ 166f05cddf9SRui Paulo char *private_key; 167f05cddf9SRui Paulo 168f05cddf9SRui Paulo /** 169f05cddf9SRui Paulo * private_key_passwd - Password for private key file 170f05cddf9SRui Paulo */ 171f05cddf9SRui Paulo char *private_key_passwd; 172f05cddf9SRui Paulo 173f05cddf9SRui Paulo /** 174f05cddf9SRui Paulo * imsi - IMSI in <MCC> | <MNC> | '-' | <MSIN> format 175f05cddf9SRui Paulo */ 176f05cddf9SRui Paulo char *imsi; 177f05cddf9SRui Paulo 178f05cddf9SRui Paulo /** 179f05cddf9SRui Paulo * milenage - Milenage parameters for SIM/USIM simulator in 180f05cddf9SRui Paulo * <Ki>:<OPc>:<SQN> format 181f05cddf9SRui Paulo */ 182f05cddf9SRui Paulo char *milenage; 183f05cddf9SRui Paulo 184f05cddf9SRui Paulo /** 185*a90b9d01SCy Schubert * imsi_privacy_cert - IMSI privacy certificate 186*a90b9d01SCy Schubert * 187*a90b9d01SCy Schubert * This field is used with EAP-SIM/AKA/AKA' to encrypt the permanent 188*a90b9d01SCy Schubert * identity (IMSI) to improve privacy. The referenced PEM-encoded 189*a90b9d01SCy Schubert * X.509v3 certificate needs to include a 2048-bit RSA public key and 190*a90b9d01SCy Schubert * this is from the operator who authenticates the SIM/USIM. 191*a90b9d01SCy Schubert */ 192*a90b9d01SCy Schubert char *imsi_privacy_cert; 193*a90b9d01SCy Schubert 194*a90b9d01SCy Schubert /** 195*a90b9d01SCy Schubert * imsi_privacy_attr - IMSI privacy attribute 196*a90b9d01SCy Schubert * 197*a90b9d01SCy Schubert * This field is used to help the EAP-SIM/AKA/AKA' server to identify 198*a90b9d01SCy Schubert * the used certificate (and as such, the matching private key). This 199*a90b9d01SCy Schubert * is set to an attribute in name=value format if the operator needs 200*a90b9d01SCy Schubert * this information. 201*a90b9d01SCy Schubert */ 202*a90b9d01SCy Schubert char *imsi_privacy_attr; 203*a90b9d01SCy Schubert 204*a90b9d01SCy Schubert /** 20532a95656SCy Schubert * engine - Use an engine for private key operations 20632a95656SCy Schubert */ 20732a95656SCy Schubert int engine; 20832a95656SCy Schubert 20932a95656SCy Schubert /** 21032a95656SCy Schubert * engine_id - String identifying the engine to use 21132a95656SCy Schubert */ 21232a95656SCy Schubert char *engine_id; 21332a95656SCy Schubert 21432a95656SCy Schubert /** 21532a95656SCy Schubert * ca_cert_id - The CA certificate identifier when using an engine 21632a95656SCy Schubert */ 21732a95656SCy Schubert char *ca_cert_id; 21832a95656SCy Schubert 21932a95656SCy Schubert /** 22032a95656SCy Schubert * cert_id - The certificate identifier when using an engine 22132a95656SCy Schubert */ 22232a95656SCy Schubert char *cert_id; 22332a95656SCy Schubert 22432a95656SCy Schubert /** 22532a95656SCy Schubert * key_id - The private key identifier when using an engine 22632a95656SCy Schubert */ 22732a95656SCy Schubert char *key_id; 22832a95656SCy Schubert 22932a95656SCy Schubert /** 2305b9c547cSRui Paulo * domain_suffix_match - Constraint for server domain name 2315b9c547cSRui Paulo * 2325b9c547cSRui Paulo * If set, this FQDN is used as a suffix match requirement for the AAA 2335b9c547cSRui Paulo * server certificate in SubjectAltName dNSName element(s). If a 2345b9c547cSRui Paulo * matching dNSName is found, this constraint is met. If no dNSName 2355b9c547cSRui Paulo * values are present, this constraint is matched against SubjectName CN 2365b9c547cSRui Paulo * using same suffix match comparison. Suffix match here means that the 2375b9c547cSRui Paulo * host/domain name is compared one label at a time starting from the 2385b9c547cSRui Paulo * top-level domain and all the labels in @domain_suffix_match shall be 2395b9c547cSRui Paulo * included in the certificate. The certificate may include additional 2405b9c547cSRui Paulo * sub-level labels in addition to the required labels. 2415b9c547cSRui Paulo * 2425b9c547cSRui Paulo * For example, domain_suffix_match=example.com would match 2435b9c547cSRui Paulo * test.example.com but would not match test-example.com. 2445b9c547cSRui Paulo */ 2455b9c547cSRui Paulo char *domain_suffix_match; 2465b9c547cSRui Paulo 2475b9c547cSRui Paulo /** 2485b9c547cSRui Paulo * domain - Home service provider FQDN(s) 249f05cddf9SRui Paulo * 250f05cddf9SRui Paulo * This is used to compare against the Domain Name List to figure out 2515b9c547cSRui Paulo * whether the AP is operated by the Home SP. Multiple domain entries 2525b9c547cSRui Paulo * can be used to configure alternative FQDNs that will be considered 2535b9c547cSRui Paulo * home networks. 254f05cddf9SRui Paulo */ 2555b9c547cSRui Paulo char **domain; 2565b9c547cSRui Paulo 2575b9c547cSRui Paulo /** 2585b9c547cSRui Paulo * num_domain - Number of FQDNs in the domain array 2595b9c547cSRui Paulo */ 2605b9c547cSRui Paulo size_t num_domain; 261f05cddf9SRui Paulo 262f05cddf9SRui Paulo /** 263*a90b9d01SCy Schubert * home_ois - Home OIs 264f05cddf9SRui Paulo * 265*a90b9d01SCy Schubert * If num_home_ois is non-zero, this field contains the set of Home OIs 266*a90b9d01SCy Schubert * that can be use to determine which access points support 267*a90b9d01SCy Schubert * authentication with this credential. These are an alternative to the 268*a90b9d01SCy Schubert * use of the realm parameter. When using Home OIs to match the network, 269*a90b9d01SCy Schubert * the EAP parameters need to be pre-configured with the credentials 270*a90b9d01SCy Schubert * since the NAI Realm information may not be available or fetched. 271*a90b9d01SCy Schubert * A successful authentication with the access point is possible as soon 272*a90b9d01SCy Schubert * as at least one Home OI from the list matches an OI in the Roaming 273*a90b9d01SCy Schubert * Consortium list advertised by the access point. 274*a90b9d01SCy Schubert * (Hotspot 2.0 PerProviderSubscription/<X+>/HomeSP/HomeOIList/<X+>/HomeOI) 275f05cddf9SRui Paulo */ 276*a90b9d01SCy Schubert u8 home_ois[MAX_ROAMING_CONS][MAX_ROAMING_CONS_OI_LEN]; 277f05cddf9SRui Paulo 278f05cddf9SRui Paulo /** 279*a90b9d01SCy Schubert * home_ois_len - Length of home_ois[i] 280f05cddf9SRui Paulo */ 281*a90b9d01SCy Schubert size_t home_ois_len[MAX_ROAMING_CONS]; 282f05cddf9SRui Paulo 28385732ac8SCy Schubert /** 284*a90b9d01SCy Schubert * num_home_ois - Number of entries in home_ois 285*a90b9d01SCy Schubert */ 286*a90b9d01SCy Schubert unsigned int num_home_ois; 287*a90b9d01SCy Schubert 288*a90b9d01SCy Schubert /** 289*a90b9d01SCy Schubert * required_home_ois - Required Home OI(s) 29085732ac8SCy Schubert * 291*a90b9d01SCy Schubert * If required_home_ois_len is non-zero, this field contains the set of 292*a90b9d01SCy Schubert * Home OI(s) that are required to be advertised by the AP for the 293*a90b9d01SCy Schubert * credential to be considered matching. 294*a90b9d01SCy Schubert * (Hotspot 2.0 PerProviderSubscription/<X+>/HomeSP/HomeOIList/<X+>/HomeOIRequired) 29585732ac8SCy Schubert */ 296*a90b9d01SCy Schubert u8 required_home_ois[MAX_ROAMING_CONS][MAX_ROAMING_CONS_OI_LEN]; 29785732ac8SCy Schubert 29885732ac8SCy Schubert /** 299*a90b9d01SCy Schubert * required_home_ois_len - Length of required_home_ois 30085732ac8SCy Schubert */ 301*a90b9d01SCy Schubert size_t required_home_ois_len[MAX_ROAMING_CONS]; 302*a90b9d01SCy Schubert 303*a90b9d01SCy Schubert /** 304*a90b9d01SCy Schubert * num_required_home_ois - Number of entries in required_home_ois 305*a90b9d01SCy Schubert */ 306*a90b9d01SCy Schubert unsigned int num_required_home_ois; 3075b9c547cSRui Paulo 308f05cddf9SRui Paulo /** 30985732ac8SCy Schubert * roaming_consortiums - Roaming Consortium OI(s) memberships 31085732ac8SCy Schubert * 31185732ac8SCy Schubert * This field contains one or more OIs identifying the roaming 31285732ac8SCy Schubert * consortiums of which the provider is a member. The list is sorted 31385732ac8SCy Schubert * from the most preferred one to the least preferred one. A match 31485732ac8SCy Schubert * between the Roaming Consortium OIs advertised by an AP and the OIs 31585732ac8SCy Schubert * in this list indicates that successful authentication is possible. 31685732ac8SCy Schubert * (Hotspot 2.0 PerProviderSubscription/<X+>/HomeSP/RoamingConsortiumOI) 31785732ac8SCy Schubert */ 31885732ac8SCy Schubert u8 roaming_consortiums[MAX_ROAMING_CONS][MAX_ROAMING_CONS_OI_LEN]; 31985732ac8SCy Schubert 32085732ac8SCy Schubert /** 32185732ac8SCy Schubert * roaming_consortiums_len - Length on roaming_consortiums[i] 32285732ac8SCy Schubert */ 32385732ac8SCy Schubert size_t roaming_consortiums_len[MAX_ROAMING_CONS]; 32485732ac8SCy Schubert 32585732ac8SCy Schubert /** 32685732ac8SCy Schubert * num_roaming_consortiums - Number of entries in roaming_consortiums 32785732ac8SCy Schubert */ 32885732ac8SCy Schubert unsigned int num_roaming_consortiums; 32985732ac8SCy Schubert 33085732ac8SCy Schubert /** 331f05cddf9SRui Paulo * eap_method - EAP method to use 332f05cddf9SRui Paulo * 333f05cddf9SRui Paulo * Pre-configured EAP method to use with this credential or %NULL to 334f05cddf9SRui Paulo * indicate no EAP method is selected, i.e., the method will be 335f05cddf9SRui Paulo * selected automatically based on ANQP information. 336f05cddf9SRui Paulo */ 337f05cddf9SRui Paulo struct eap_method_type *eap_method; 338f05cddf9SRui Paulo 339f05cddf9SRui Paulo /** 340f05cddf9SRui Paulo * phase1 - Phase 1 (outer authentication) parameters 341f05cddf9SRui Paulo * 342f05cddf9SRui Paulo * Pre-configured EAP parameters or %NULL. 343f05cddf9SRui Paulo */ 344f05cddf9SRui Paulo char *phase1; 345f05cddf9SRui Paulo 346f05cddf9SRui Paulo /** 347f05cddf9SRui Paulo * phase2 - Phase 2 (inner authentication) parameters 348f05cddf9SRui Paulo * 349f05cddf9SRui Paulo * Pre-configured EAP parameters or %NULL. 350f05cddf9SRui Paulo */ 351f05cddf9SRui Paulo char *phase2; 352f05cddf9SRui Paulo 353f05cddf9SRui Paulo struct excluded_ssid { 354325151a3SRui Paulo u8 ssid[SSID_MAX_LEN]; 355f05cddf9SRui Paulo size_t ssid_len; 356f05cddf9SRui Paulo } *excluded_ssid; 357f05cddf9SRui Paulo size_t num_excluded_ssid; 3585b9c547cSRui Paulo 3595b9c547cSRui Paulo struct roaming_partner { 3605b9c547cSRui Paulo char fqdn[128]; 3615b9c547cSRui Paulo int exact_match; 3625b9c547cSRui Paulo u8 priority; 3635b9c547cSRui Paulo char country[3]; 3645b9c547cSRui Paulo } *roaming_partner; 3655b9c547cSRui Paulo size_t num_roaming_partner; 3665b9c547cSRui Paulo 3675b9c547cSRui Paulo int update_identifier; 3685b9c547cSRui Paulo 3695b9c547cSRui Paulo /** 3705b9c547cSRui Paulo * provisioning_sp - FQDN of the SP that provisioned the credential 3715b9c547cSRui Paulo */ 3725b9c547cSRui Paulo char *provisioning_sp; 3735b9c547cSRui Paulo 3745b9c547cSRui Paulo /** 3755b9c547cSRui Paulo * sp_priority - Credential priority within a provisioning SP 3765b9c547cSRui Paulo * 3775b9c547cSRui Paulo * This is the priority of the credential among all credentials 3785b9c547cSRui Paulo * provisionined by the same SP (i.e., for entries that have identical 3795b9c547cSRui Paulo * provisioning_sp value). The range of this priority is 0-255 with 0 3805b9c547cSRui Paulo * being the highest and 255 the lower priority. 3815b9c547cSRui Paulo */ 3825b9c547cSRui Paulo int sp_priority; 3835b9c547cSRui Paulo 3845b9c547cSRui Paulo unsigned int min_dl_bandwidth_home; 3855b9c547cSRui Paulo unsigned int min_ul_bandwidth_home; 3865b9c547cSRui Paulo unsigned int min_dl_bandwidth_roaming; 3875b9c547cSRui Paulo unsigned int min_ul_bandwidth_roaming; 3885b9c547cSRui Paulo 3895b9c547cSRui Paulo /** 3905b9c547cSRui Paulo * max_bss_load - Maximum BSS Load Channel Utilization (1..255) 3915b9c547cSRui Paulo * This value is used as the maximum channel utilization for network 3925b9c547cSRui Paulo * selection purposes for home networks. If the AP does not advertise 3935b9c547cSRui Paulo * BSS Load or if the limit would prevent any connection, this 3945b9c547cSRui Paulo * constraint will be ignored. 3955b9c547cSRui Paulo */ 3965b9c547cSRui Paulo unsigned int max_bss_load; 3975b9c547cSRui Paulo 398c1d255d3SCy Schubert size_t num_req_conn_capab; 3995b9c547cSRui Paulo u8 *req_conn_capab_proto; 4005b9c547cSRui Paulo int **req_conn_capab_port; 4015b9c547cSRui Paulo 4025b9c547cSRui Paulo /** 4035b9c547cSRui Paulo * ocsp - Whether to use/require OCSP to check server certificate 4045b9c547cSRui Paulo * 4055b9c547cSRui Paulo * 0 = do not use OCSP stapling (TLS certificate status extension) 4065b9c547cSRui Paulo * 1 = try to use OCSP stapling, but not require response 4075b9c547cSRui Paulo * 2 = require valid OCSP stapling response 4085b9c547cSRui Paulo */ 4095b9c547cSRui Paulo int ocsp; 4105b9c547cSRui Paulo 4115b9c547cSRui Paulo /** 4125b9c547cSRui Paulo * sim_num - User selected SIM identifier 4135b9c547cSRui Paulo * 4145b9c547cSRui Paulo * This variable is used for identifying which SIM is used if the system 4155b9c547cSRui Paulo * has more than one. 4165b9c547cSRui Paulo */ 4175b9c547cSRui Paulo int sim_num; 418f05cddf9SRui Paulo }; 419f05cddf9SRui Paulo 420f05cddf9SRui Paulo 421f05cddf9SRui Paulo #define CFG_CHANGED_DEVICE_NAME BIT(0) 422f05cddf9SRui Paulo #define CFG_CHANGED_CONFIG_METHODS BIT(1) 423f05cddf9SRui Paulo #define CFG_CHANGED_DEVICE_TYPE BIT(2) 424f05cddf9SRui Paulo #define CFG_CHANGED_OS_VERSION BIT(3) 425f05cddf9SRui Paulo #define CFG_CHANGED_UUID BIT(4) 426f05cddf9SRui Paulo #define CFG_CHANGED_COUNTRY BIT(5) 427f05cddf9SRui Paulo #define CFG_CHANGED_SEC_DEVICE_TYPE BIT(6) 428f05cddf9SRui Paulo #define CFG_CHANGED_P2P_SSID_POSTFIX BIT(7) 429f05cddf9SRui Paulo #define CFG_CHANGED_WPS_STRING BIT(8) 430f05cddf9SRui Paulo #define CFG_CHANGED_P2P_INTRA_BSS BIT(9) 431f05cddf9SRui Paulo #define CFG_CHANGED_VENDOR_EXTENSION BIT(10) 432f05cddf9SRui Paulo #define CFG_CHANGED_P2P_LISTEN_CHANNEL BIT(11) 433f05cddf9SRui Paulo #define CFG_CHANGED_P2P_OPER_CHANNEL BIT(12) 434f05cddf9SRui Paulo #define CFG_CHANGED_P2P_PREF_CHAN BIT(13) 435f05cddf9SRui Paulo #define CFG_CHANGED_EXT_PW_BACKEND BIT(14) 4365b9c547cSRui Paulo #define CFG_CHANGED_NFC_PASSWORD_TOKEN BIT(15) 4375b9c547cSRui Paulo #define CFG_CHANGED_P2P_PASSPHRASE_LEN BIT(16) 438780fb4a2SCy Schubert #define CFG_CHANGED_SCHED_SCAN_PLANS BIT(17) 43985732ac8SCy Schubert #define CFG_CHANGED_WOWLAN_TRIGGERS BIT(18) 440206b73d0SCy Schubert #define CFG_CHANGED_DISABLE_BTM BIT(19) 441c1d255d3SCy Schubert #define CFG_CHANGED_BGSCAN BIT(20) 442*a90b9d01SCy Schubert #define CFG_CHANGED_FT_PREPEND_PMKID BIT(21) 443f05cddf9SRui Paulo 44439beb93cSSam Leffler /** 44539beb93cSSam Leffler * struct wpa_config - wpa_supplicant configuration data 44639beb93cSSam Leffler * 44739beb93cSSam Leffler * This data structure is presents the per-interface (radio) configuration 44839beb93cSSam Leffler * data. In many cases, there is only one struct wpa_config instance, but if 44939beb93cSSam Leffler * more than one network interface is being controlled, one instance is used 45039beb93cSSam Leffler * for each. 45139beb93cSSam Leffler */ 45239beb93cSSam Leffler struct wpa_config { 45339beb93cSSam Leffler /** 45439beb93cSSam Leffler * ssid - Head of the global network list 45539beb93cSSam Leffler * 45639beb93cSSam Leffler * This is the head for the list of all the configured networks. 45739beb93cSSam Leffler */ 45839beb93cSSam Leffler struct wpa_ssid *ssid; 45939beb93cSSam Leffler 46039beb93cSSam Leffler /** 46139beb93cSSam Leffler * pssid - Per-priority network lists (in priority order) 46239beb93cSSam Leffler */ 46339beb93cSSam Leffler struct wpa_ssid **pssid; 46439beb93cSSam Leffler 46539beb93cSSam Leffler /** 46639beb93cSSam Leffler * num_prio - Number of different priorities used in the pssid lists 46739beb93cSSam Leffler * 46839beb93cSSam Leffler * This indicates how many per-priority network lists are included in 46939beb93cSSam Leffler * pssid. 47039beb93cSSam Leffler */ 471c1d255d3SCy Schubert size_t num_prio; 47239beb93cSSam Leffler 47339beb93cSSam Leffler /** 474f05cddf9SRui Paulo * cred - Head of the credential list 475f05cddf9SRui Paulo * 476f05cddf9SRui Paulo * This is the head for the list of all the configured credentials. 477f05cddf9SRui Paulo */ 478f05cddf9SRui Paulo struct wpa_cred *cred; 479f05cddf9SRui Paulo 480f05cddf9SRui Paulo /** 48139beb93cSSam Leffler * eapol_version - IEEE 802.1X/EAPOL version number 48239beb93cSSam Leffler * 48339beb93cSSam Leffler * wpa_supplicant is implemented based on IEEE Std 802.1X-2004 which 48439beb93cSSam Leffler * defines EAPOL version 2. However, there are many APs that do not 48539beb93cSSam Leffler * handle the new version number correctly (they seem to drop the 48639beb93cSSam Leffler * frames completely). In order to make wpa_supplicant interoperate 48739beb93cSSam Leffler * with these APs, the version number is set to 1 by default. This 48839beb93cSSam Leffler * configuration value can be used to set it to the new version (2). 48939beb93cSSam Leffler */ 49039beb93cSSam Leffler int eapol_version; 49139beb93cSSam Leffler 49239beb93cSSam Leffler /** 49339beb93cSSam Leffler * ap_scan - AP scanning/selection 49439beb93cSSam Leffler * 49539beb93cSSam Leffler * By default, wpa_supplicant requests driver to perform AP 49639beb93cSSam Leffler * scanning and then uses the scan results to select a 49739beb93cSSam Leffler * suitable AP. Another alternative is to allow the driver to 49839beb93cSSam Leffler * take care of AP scanning and selection and use 49939beb93cSSam Leffler * wpa_supplicant just to process EAPOL frames based on IEEE 50039beb93cSSam Leffler * 802.11 association information from the driver. 50139beb93cSSam Leffler * 50239beb93cSSam Leffler * 1: wpa_supplicant initiates scanning and AP selection (default). 50339beb93cSSam Leffler * 50439beb93cSSam Leffler * 0: Driver takes care of scanning, AP selection, and IEEE 802.11 50539beb93cSSam Leffler * association parameters (e.g., WPA IE generation); this mode can 50639beb93cSSam Leffler * also be used with non-WPA drivers when using IEEE 802.1X mode; 50739beb93cSSam Leffler * do not try to associate with APs (i.e., external program needs 50839beb93cSSam Leffler * to control association). This mode must also be used when using 50939beb93cSSam Leffler * wired Ethernet drivers. 51039beb93cSSam Leffler * 51139beb93cSSam Leffler * 2: like 0, but associate with APs using security policy and SSID 51239beb93cSSam Leffler * (but not BSSID); this can be used, e.g., with ndiswrapper and NDIS 51339beb93cSSam Leffler * drivers to enable operation with hidden SSIDs and optimized roaming; 51439beb93cSSam Leffler * in this mode, the network blocks in the configuration are tried 51539beb93cSSam Leffler * one by one until the driver reports successful association; each 51639beb93cSSam Leffler * network block should have explicit security policy (i.e., only one 51739beb93cSSam Leffler * option in the lists) for key_mgmt, pairwise, group, proto variables. 518325151a3SRui Paulo * 519325151a3SRui Paulo * Note: ap_scan=2 should not be used with the nl80211 driver interface 520325151a3SRui Paulo * (the current Linux interface). ap_scan=1 is optimized work working 521325151a3SRui Paulo * with nl80211. For finding networks using hidden SSID, scan_ssid=1 in 522325151a3SRui Paulo * the network block can be used with nl80211. 52339beb93cSSam Leffler */ 52439beb93cSSam Leffler int ap_scan; 52539beb93cSSam Leffler 52639beb93cSSam Leffler /** 5275b9c547cSRui Paulo * bgscan - Background scan and roaming parameters or %NULL if none 5285b9c547cSRui Paulo * 5295b9c547cSRui Paulo * This is an optional set of parameters for background scanning and 5305b9c547cSRui Paulo * roaming within a network (ESS). For more detailed information see 5315b9c547cSRui Paulo * ssid block documentation. 5325b9c547cSRui Paulo * 5335b9c547cSRui Paulo * The variable defines default bgscan behavior for all BSS station 5345b9c547cSRui Paulo * networks except for those which have their own bgscan configuration. 5355b9c547cSRui Paulo */ 5365b9c547cSRui Paulo char *bgscan; 5375b9c547cSRui Paulo 5385b9c547cSRui Paulo /** 539f05cddf9SRui Paulo * disable_scan_offload - Disable automatic offloading of scan requests 540f05cddf9SRui Paulo * 541f05cddf9SRui Paulo * By default, %wpa_supplicant tries to offload scanning if the driver 542f05cddf9SRui Paulo * indicates support for this (sched_scan). This configuration 543f05cddf9SRui Paulo * parameter can be used to disable this offloading mechanism. 544f05cddf9SRui Paulo */ 545f05cddf9SRui Paulo int disable_scan_offload; 546f05cddf9SRui Paulo 547f05cddf9SRui Paulo /** 54839beb93cSSam Leffler * ctrl_interface - Parameters for the control interface 54939beb93cSSam Leffler * 55039beb93cSSam Leffler * If this is specified, %wpa_supplicant will open a control interface 55139beb93cSSam Leffler * that is available for external programs to manage %wpa_supplicant. 55239beb93cSSam Leffler * The meaning of this string depends on which control interface 553f05cddf9SRui Paulo * mechanism is used. For all cases, the existence of this parameter 55439beb93cSSam Leffler * in configuration is used to determine whether the control interface 55539beb93cSSam Leffler * is enabled. 55639beb93cSSam Leffler * 55739beb93cSSam Leffler * For UNIX domain sockets (default on Linux and BSD): This is a 55839beb93cSSam Leffler * directory that will be created for UNIX domain sockets for listening 55939beb93cSSam Leffler * to requests from external programs (CLI/GUI, etc.) for status 56039beb93cSSam Leffler * information and configuration. The socket file will be named based 56139beb93cSSam Leffler * on the interface name, so multiple %wpa_supplicant processes can be 56239beb93cSSam Leffler * run at the same time if more than one interface is used. 56339beb93cSSam Leffler * /var/run/wpa_supplicant is the recommended directory for sockets and 56439beb93cSSam Leffler * by default, wpa_cli will use it when trying to connect with 56539beb93cSSam Leffler * %wpa_supplicant. 56639beb93cSSam Leffler * 56739beb93cSSam Leffler * Access control for the control interface can be configured 56839beb93cSSam Leffler * by setting the directory to allow only members of a group 56939beb93cSSam Leffler * to use sockets. This way, it is possible to run 57039beb93cSSam Leffler * %wpa_supplicant as root (since it needs to change network 57139beb93cSSam Leffler * configuration and open raw sockets) and still allow GUI/CLI 57239beb93cSSam Leffler * components to be run as non-root users. However, since the 57339beb93cSSam Leffler * control interface can be used to change the network 57439beb93cSSam Leffler * configuration, this access needs to be protected in many 57539beb93cSSam Leffler * cases. By default, %wpa_supplicant is configured to use gid 57639beb93cSSam Leffler * 0 (root). If you want to allow non-root users to use the 57739beb93cSSam Leffler * control interface, add a new group and change this value to 57839beb93cSSam Leffler * match with that group. Add users that should have control 57939beb93cSSam Leffler * interface access to this group. 58039beb93cSSam Leffler * 58139beb93cSSam Leffler * When configuring both the directory and group, use following format: 58239beb93cSSam Leffler * DIR=/var/run/wpa_supplicant GROUP=wheel 58339beb93cSSam Leffler * DIR=/var/run/wpa_supplicant GROUP=0 58439beb93cSSam Leffler * (group can be either group name or gid) 58539beb93cSSam Leffler * 58639beb93cSSam Leffler * For UDP connections (default on Windows): The value will be ignored. 58739beb93cSSam Leffler * This variable is just used to select that the control interface is 58839beb93cSSam Leffler * to be created. The value can be set to, e.g., udp 58939beb93cSSam Leffler * (ctrl_interface=udp). 59039beb93cSSam Leffler * 59139beb93cSSam Leffler * For Windows Named Pipe: This value can be used to set the security 59239beb93cSSam Leffler * descriptor for controlling access to the control interface. Security 59339beb93cSSam Leffler * descriptor can be set using Security Descriptor String Format (see 59439beb93cSSam Leffler * http://msdn.microsoft.com/library/default.asp?url=/library/en-us/secauthz/security/security_descriptor_string_format.asp). 59539beb93cSSam Leffler * The descriptor string needs to be prefixed with SDDL=. For example, 59639beb93cSSam Leffler * ctrl_interface=SDDL=D: would set an empty DACL (which will reject 59739beb93cSSam Leffler * all connections). 59839beb93cSSam Leffler */ 59939beb93cSSam Leffler char *ctrl_interface; 60039beb93cSSam Leffler 60139beb93cSSam Leffler /** 60239beb93cSSam Leffler * ctrl_interface_group - Control interface group (DEPRECATED) 60339beb93cSSam Leffler * 60439beb93cSSam Leffler * This variable is only used for backwards compatibility. Group for 60539beb93cSSam Leffler * UNIX domain sockets should now be specified using GROUP=group in 60639beb93cSSam Leffler * ctrl_interface variable. 60739beb93cSSam Leffler */ 60839beb93cSSam Leffler char *ctrl_interface_group; 60939beb93cSSam Leffler 61039beb93cSSam Leffler /** 61139beb93cSSam Leffler * fast_reauth - EAP fast re-authentication (session resumption) 61239beb93cSSam Leffler * 61339beb93cSSam Leffler * By default, fast re-authentication is enabled for all EAP methods 61439beb93cSSam Leffler * that support it. This variable can be used to disable fast 61539beb93cSSam Leffler * re-authentication (by setting fast_reauth=0). Normally, there is no 61639beb93cSSam Leffler * need to disable fast re-authentication. 61739beb93cSSam Leffler */ 61839beb93cSSam Leffler int fast_reauth; 61939beb93cSSam Leffler 620*a90b9d01SCy Schubert #ifndef CONFIG_OPENSC_ENGINE_PATH 62139beb93cSSam Leffler /** 62239beb93cSSam Leffler * opensc_engine_path - Path to the OpenSSL engine for opensc 62339beb93cSSam Leffler * 62439beb93cSSam Leffler * This is an OpenSSL specific configuration option for loading OpenSC 62539beb93cSSam Leffler * engine (engine_opensc.so); if %NULL, this engine is not loaded. 62639beb93cSSam Leffler */ 62739beb93cSSam Leffler char *opensc_engine_path; 628*a90b9d01SCy Schubert #endif /* CONFIG_OPENSC_ENGINE_PATH */ 62939beb93cSSam Leffler 630*a90b9d01SCy Schubert #ifndef CONFIG_PKCS11_ENGINE_PATH 63139beb93cSSam Leffler /** 63239beb93cSSam Leffler * pkcs11_engine_path - Path to the OpenSSL engine for PKCS#11 63339beb93cSSam Leffler * 63439beb93cSSam Leffler * This is an OpenSSL specific configuration option for loading PKCS#11 63539beb93cSSam Leffler * engine (engine_pkcs11.so); if %NULL, this engine is not loaded. 63639beb93cSSam Leffler */ 63739beb93cSSam Leffler char *pkcs11_engine_path; 638*a90b9d01SCy Schubert #endif /* CONFIG_PKCS11_ENGINE_PATH */ 63939beb93cSSam Leffler 640*a90b9d01SCy Schubert #ifndef CONFIG_PKCS11_MODULE_PATH 64139beb93cSSam Leffler /** 64239beb93cSSam Leffler * pkcs11_module_path - Path to the OpenSSL OpenSC/PKCS#11 module 64339beb93cSSam Leffler * 64439beb93cSSam Leffler * This is an OpenSSL specific configuration option for configuring 64539beb93cSSam Leffler * path to OpenSC/PKCS#11 engine (opensc-pkcs11.so); if %NULL, this 64639beb93cSSam Leffler * module is not loaded. 64739beb93cSSam Leffler */ 64839beb93cSSam Leffler char *pkcs11_module_path; 649*a90b9d01SCy Schubert #endif /* CONFIG_PKCS11_MODULE_PATH */ 65039beb93cSSam Leffler 65139beb93cSSam Leffler /** 6525b9c547cSRui Paulo * openssl_ciphers - OpenSSL cipher string 6535b9c547cSRui Paulo * 6545b9c547cSRui Paulo * This is an OpenSSL specific configuration option for configuring the 6555b9c547cSRui Paulo * default ciphers. If not set, "DEFAULT:!EXP:!LOW" is used as the 6565b9c547cSRui Paulo * default. 6575b9c547cSRui Paulo */ 6585b9c547cSRui Paulo char *openssl_ciphers; 6595b9c547cSRui Paulo 6605b9c547cSRui Paulo /** 661f05cddf9SRui Paulo * pcsc_reader - PC/SC reader name prefix 662f05cddf9SRui Paulo * 663f05cddf9SRui Paulo * If not %NULL, PC/SC reader with a name that matches this prefix is 664f05cddf9SRui Paulo * initialized for SIM/USIM access. Empty string can be used to match 665f05cddf9SRui Paulo * the first available reader. 666f05cddf9SRui Paulo */ 667f05cddf9SRui Paulo char *pcsc_reader; 668f05cddf9SRui Paulo 669f05cddf9SRui Paulo /** 670f05cddf9SRui Paulo * pcsc_pin - PIN for USIM, GSM SIM, and smartcards 671f05cddf9SRui Paulo * 672f05cddf9SRui Paulo * This field is used to configure PIN for SIM/USIM for EAP-SIM and 673f05cddf9SRui Paulo * EAP-AKA. If left out, this will be asked through control interface. 674f05cddf9SRui Paulo */ 675f05cddf9SRui Paulo char *pcsc_pin; 676f05cddf9SRui Paulo 677f05cddf9SRui Paulo /** 6785b9c547cSRui Paulo * external_sim - Use external processing for SIM/USIM operations 6795b9c547cSRui Paulo */ 6805b9c547cSRui Paulo int external_sim; 6815b9c547cSRui Paulo 6825b9c547cSRui Paulo /** 68339beb93cSSam Leffler * driver_param - Driver interface parameters 68439beb93cSSam Leffler * 68539beb93cSSam Leffler * This text string is passed to the selected driver interface with the 68639beb93cSSam Leffler * optional struct wpa_driver_ops::set_param() handler. This can be 68739beb93cSSam Leffler * used to configure driver specific options without having to add new 68839beb93cSSam Leffler * driver interface functionality. 68939beb93cSSam Leffler */ 69039beb93cSSam Leffler char *driver_param; 69139beb93cSSam Leffler 69239beb93cSSam Leffler /** 69339beb93cSSam Leffler * dot11RSNAConfigPMKLifetime - Maximum lifetime of a PMK 69439beb93cSSam Leffler * 69539beb93cSSam Leffler * dot11 MIB variable for the maximum lifetime of a PMK in the PMK 69639beb93cSSam Leffler * cache (unit: seconds). 69739beb93cSSam Leffler */ 69839beb93cSSam Leffler unsigned int dot11RSNAConfigPMKLifetime; 69939beb93cSSam Leffler 70039beb93cSSam Leffler /** 70139beb93cSSam Leffler * dot11RSNAConfigPMKReauthThreshold - PMK re-authentication threshold 70239beb93cSSam Leffler * 70339beb93cSSam Leffler * dot11 MIB variable for the percentage of the PMK lifetime 70439beb93cSSam Leffler * that should expire before an IEEE 802.1X reauthentication occurs. 70539beb93cSSam Leffler */ 70639beb93cSSam Leffler unsigned int dot11RSNAConfigPMKReauthThreshold; 70739beb93cSSam Leffler 70839beb93cSSam Leffler /** 70939beb93cSSam Leffler * dot11RSNAConfigSATimeout - Security association timeout 71039beb93cSSam Leffler * 71139beb93cSSam Leffler * dot11 MIB variable for the maximum time a security association 71239beb93cSSam Leffler * shall take to set up (unit: seconds). 71339beb93cSSam Leffler */ 71439beb93cSSam Leffler unsigned int dot11RSNAConfigSATimeout; 71539beb93cSSam Leffler 71639beb93cSSam Leffler /** 717*a90b9d01SCy Schubert * ft_prepend_pmkid - Whether to prepend PMKR1Name with PMKIDs 718*a90b9d01SCy Schubert * 719*a90b9d01SCy Schubert * This control whether PMKR1Name is prepended to the PMKID list 720*a90b9d01SCy Schubert * insread of replacing the full list when constructing RSNE for 721*a90b9d01SCy Schubert * EAPOL-Key msg 2/4 for FT cases. */ 722*a90b9d01SCy Schubert bool ft_prepend_pmkid; 723*a90b9d01SCy Schubert 724*a90b9d01SCy Schubert /** 72539beb93cSSam Leffler * update_config - Is wpa_supplicant allowed to update configuration 72639beb93cSSam Leffler * 72739beb93cSSam Leffler * This variable control whether wpa_supplicant is allow to re-write 72839beb93cSSam Leffler * its configuration with wpa_config_write(). If this is zero, 72939beb93cSSam Leffler * configuration data is only changed in memory and the external data 730c1d255d3SCy Schubert * is not overridden. If this is non-zero, wpa_supplicant will update 73139beb93cSSam Leffler * the configuration data (e.g., a file) whenever configuration is 73239beb93cSSam Leffler * changed. This update may replace the old configuration which can 73339beb93cSSam Leffler * remove comments from it in case of a text file configuration. 73439beb93cSSam Leffler */ 73539beb93cSSam Leffler int update_config; 73639beb93cSSam Leffler 73739beb93cSSam Leffler /** 73839beb93cSSam Leffler * blobs - Configuration blobs 73939beb93cSSam Leffler */ 74039beb93cSSam Leffler struct wpa_config_blob *blobs; 74139beb93cSSam Leffler 74239beb93cSSam Leffler /** 74339beb93cSSam Leffler * uuid - Universally Unique IDentifier (UUID; see RFC 4122) for WPS 74439beb93cSSam Leffler */ 74539beb93cSSam Leffler u8 uuid[16]; 74639beb93cSSam Leffler 74739beb93cSSam Leffler /** 74885732ac8SCy Schubert * auto_uuid - Automatic UUID behavior 74985732ac8SCy Schubert * 0 = generate static value based on the local MAC address (default) 75085732ac8SCy Schubert * 1 = generate a random UUID every time wpa_supplicant starts 75185732ac8SCy Schubert */ 75285732ac8SCy Schubert int auto_uuid; 75385732ac8SCy Schubert 75485732ac8SCy Schubert /** 75539beb93cSSam Leffler * device_name - Device Name (WPS) 75639beb93cSSam Leffler * User-friendly description of device; up to 32 octets encoded in 75739beb93cSSam Leffler * UTF-8 75839beb93cSSam Leffler */ 75939beb93cSSam Leffler char *device_name; 76039beb93cSSam Leffler 76139beb93cSSam Leffler /** 76239beb93cSSam Leffler * manufacturer - Manufacturer (WPS) 76339beb93cSSam Leffler * The manufacturer of the device (up to 64 ASCII characters) 76439beb93cSSam Leffler */ 76539beb93cSSam Leffler char *manufacturer; 76639beb93cSSam Leffler 76739beb93cSSam Leffler /** 76839beb93cSSam Leffler * model_name - Model Name (WPS) 76939beb93cSSam Leffler * Model of the device (up to 32 ASCII characters) 77039beb93cSSam Leffler */ 77139beb93cSSam Leffler char *model_name; 77239beb93cSSam Leffler 77339beb93cSSam Leffler /** 77439beb93cSSam Leffler * model_number - Model Number (WPS) 77539beb93cSSam Leffler * Additional device description (up to 32 ASCII characters) 77639beb93cSSam Leffler */ 77739beb93cSSam Leffler char *model_number; 77839beb93cSSam Leffler 77939beb93cSSam Leffler /** 78039beb93cSSam Leffler * serial_number - Serial Number (WPS) 78139beb93cSSam Leffler * Serial number of the device (up to 32 characters) 78239beb93cSSam Leffler */ 78339beb93cSSam Leffler char *serial_number; 78439beb93cSSam Leffler 78539beb93cSSam Leffler /** 78639beb93cSSam Leffler * device_type - Primary Device Type (WPS) 78739beb93cSSam Leffler */ 788f05cddf9SRui Paulo u8 device_type[WPS_DEV_TYPE_LEN]; 78939beb93cSSam Leffler 79039beb93cSSam Leffler /** 791e28a4053SRui Paulo * config_methods - Config Methods 792e28a4053SRui Paulo * 793e28a4053SRui Paulo * This is a space-separated list of supported WPS configuration 794f05cddf9SRui Paulo * methods. For example, "label virtual_display virtual_push_button 795f05cddf9SRui Paulo * keypad". 796e28a4053SRui Paulo * Available methods: usba ethernet label display ext_nfc_token 797f05cddf9SRui Paulo * int_nfc_token nfc_interface push_button keypad 798f05cddf9SRui Paulo * virtual_display physical_display 799f05cddf9SRui Paulo * virtual_push_button physical_push_button. 800e28a4053SRui Paulo */ 801e28a4053SRui Paulo char *config_methods; 802e28a4053SRui Paulo 803e28a4053SRui Paulo /** 80439beb93cSSam Leffler * os_version - OS Version (WPS) 80539beb93cSSam Leffler * 4-octet operating system version number 80639beb93cSSam Leffler */ 80739beb93cSSam Leffler u8 os_version[4]; 80839beb93cSSam Leffler 80939beb93cSSam Leffler /** 81039beb93cSSam Leffler * country - Country code 81139beb93cSSam Leffler * 81239beb93cSSam Leffler * This is the ISO/IEC alpha2 country code for which we are operating 81339beb93cSSam Leffler * in 81439beb93cSSam Leffler */ 81539beb93cSSam Leffler char country[2]; 81639beb93cSSam Leffler 81739beb93cSSam Leffler /** 81839beb93cSSam Leffler * wps_cred_processing - Credential processing 81939beb93cSSam Leffler * 82039beb93cSSam Leffler * 0 = process received credentials internally 82139beb93cSSam Leffler * 1 = do not process received credentials; just pass them over 82239beb93cSSam Leffler * ctrl_iface to external program(s) 82339beb93cSSam Leffler * 2 = process received credentials internally and pass them over 82439beb93cSSam Leffler * ctrl_iface to external program(s) 82539beb93cSSam Leffler */ 82639beb93cSSam Leffler int wps_cred_processing; 827e28a4053SRui Paulo 8284bc52338SCy Schubert /** 8294bc52338SCy Schubert * wps_cred_add_sae - Whether to enable SAE automatically for WPS 8304bc52338SCy Schubert * 8314bc52338SCy Schubert * 0 = only add the explicitly listed WPA2-PSK configuration 8324bc52338SCy Schubert * 1 = add both the WPA2-PSK and SAE configuration and enable PMF so 8334bc52338SCy Schubert * that the station gets configured in WPA3-Personal transition mode 8344bc52338SCy Schubert * (supports both WPA2-Personal (PSK) and WPA3-Personal (SAE) APs). 8354bc52338SCy Schubert */ 8364bc52338SCy Schubert int wps_cred_add_sae; 8374bc52338SCy Schubert 838f05cddf9SRui Paulo #define MAX_SEC_DEVICE_TYPES 5 839f05cddf9SRui Paulo /** 840f05cddf9SRui Paulo * sec_device_types - Secondary Device Types (P2P) 841f05cddf9SRui Paulo */ 842f05cddf9SRui Paulo u8 sec_device_type[MAX_SEC_DEVICE_TYPES][WPS_DEV_TYPE_LEN]; 843f05cddf9SRui Paulo int num_sec_device_types; 844f05cddf9SRui Paulo 845f05cddf9SRui Paulo int p2p_listen_reg_class; 846f05cddf9SRui Paulo int p2p_listen_channel; 847f05cddf9SRui Paulo int p2p_oper_reg_class; 848f05cddf9SRui Paulo int p2p_oper_channel; 849f05cddf9SRui Paulo int p2p_go_intent; 850f05cddf9SRui Paulo char *p2p_ssid_postfix; 851f05cddf9SRui Paulo int persistent_reconnect; 852f05cddf9SRui Paulo int p2p_intra_bss; 853f05cddf9SRui Paulo unsigned int num_p2p_pref_chan; 854f05cddf9SRui Paulo struct p2p_channel *p2p_pref_chan; 8555b9c547cSRui Paulo struct wpa_freq_range_list p2p_no_go_freq; 8565b9c547cSRui Paulo int p2p_add_cli_chan; 8575b9c547cSRui Paulo int p2p_ignore_shared_freq; 8585b9c547cSRui Paulo int p2p_optimize_listen_chan; 859f05cddf9SRui Paulo 860c1d255d3SCy Schubert int p2p_6ghz_disable; 861c1d255d3SCy Schubert 862f05cddf9SRui Paulo struct wpabuf *wps_vendor_ext_m1; 863f05cddf9SRui Paulo 864f05cddf9SRui Paulo #define MAX_WPS_VENDOR_EXT 10 865f05cddf9SRui Paulo /** 866f05cddf9SRui Paulo * wps_vendor_ext - Vendor extension attributes in WPS 867f05cddf9SRui Paulo */ 868f05cddf9SRui Paulo struct wpabuf *wps_vendor_ext[MAX_WPS_VENDOR_EXT]; 869f05cddf9SRui Paulo 870f05cddf9SRui Paulo /** 871f05cddf9SRui Paulo * p2p_group_idle - Maximum idle time in seconds for P2P group 872f05cddf9SRui Paulo * 873f05cddf9SRui Paulo * This value controls how long a P2P group is maintained after there 874f05cddf9SRui Paulo * is no other members in the group. As a GO, this means no associated 875f05cddf9SRui Paulo * stations in the group. As a P2P client, this means no GO seen in 876f05cddf9SRui Paulo * scan results. The maximum idle time is specified in seconds with 0 877f05cddf9SRui Paulo * indicating no time limit, i.e., the P2P group remains in active 878f05cddf9SRui Paulo * state indefinitely until explicitly removed. As a P2P client, the 879f05cddf9SRui Paulo * maximum idle time of P2P_MAX_CLIENT_IDLE seconds is enforced, i.e., 880f05cddf9SRui Paulo * this parameter is mainly meant for GO use and for P2P client, it can 881f05cddf9SRui Paulo * only be used to reduce the default timeout to smaller value. A 882f05cddf9SRui Paulo * special value -1 can be used to configure immediate removal of the 883f05cddf9SRui Paulo * group for P2P client role on any disconnection after the data 884f05cddf9SRui Paulo * connection has been established. 885f05cddf9SRui Paulo */ 886f05cddf9SRui Paulo int p2p_group_idle; 887f05cddf9SRui Paulo 888e28a4053SRui Paulo /** 889325151a3SRui Paulo * p2p_go_freq_change_policy - The GO frequency change policy 890325151a3SRui Paulo * 891325151a3SRui Paulo * This controls the behavior of the GO when there is a change in the 892325151a3SRui Paulo * map of the currently used frequencies in case more than one channel 893325151a3SRui Paulo * is supported. 894325151a3SRui Paulo * 895325151a3SRui Paulo * @P2P_GO_FREQ_MOVE_SCM: Prefer working in a single channel mode if 896325151a3SRui Paulo * possible. In case the GO is the only interface using its frequency 897325151a3SRui Paulo * and there are other station interfaces on other frequencies, the GO 898325151a3SRui Paulo * will migrate to one of these frequencies. 899325151a3SRui Paulo * 900325151a3SRui Paulo * @P2P_GO_FREQ_MOVE_SCM_PEER_SUPPORTS: Same as P2P_GO_FREQ_MOVE_SCM, 901325151a3SRui Paulo * but a transition is possible only in case one of the other used 902325151a3SRui Paulo * frequencies is one of the frequencies in the intersection of the 903325151a3SRui Paulo * frequency list of the local device and the peer device. 904325151a3SRui Paulo * 905325151a3SRui Paulo * @P2P_GO_FREQ_MOVE_STAY: Prefer to stay on the current frequency. 906780fb4a2SCy Schubert * 907780fb4a2SCy Schubert * @P2P_GO_FREQ_MOVE_SCM_ECSA: Same as 908780fb4a2SCy Schubert * P2P_GO_FREQ_MOVE_SCM_PEER_SUPPORTS but a transition is possible only 909780fb4a2SCy Schubert * if all the group members advertise eCSA support. 910325151a3SRui Paulo */ 911325151a3SRui Paulo enum { 912325151a3SRui Paulo P2P_GO_FREQ_MOVE_SCM = 0, 913325151a3SRui Paulo P2P_GO_FREQ_MOVE_SCM_PEER_SUPPORTS = 1, 914325151a3SRui Paulo P2P_GO_FREQ_MOVE_STAY = 2, 915780fb4a2SCy Schubert P2P_GO_FREQ_MOVE_SCM_ECSA = 3, 916780fb4a2SCy Schubert P2P_GO_FREQ_MOVE_MAX = P2P_GO_FREQ_MOVE_SCM_ECSA, 917325151a3SRui Paulo } p2p_go_freq_change_policy; 918325151a3SRui Paulo 919325151a3SRui Paulo #define DEFAULT_P2P_GO_FREQ_MOVE P2P_GO_FREQ_MOVE_STAY 920325151a3SRui Paulo 921325151a3SRui Paulo /** 9225b9c547cSRui Paulo * p2p_passphrase_len - Passphrase length (8..63) for P2P GO 9235b9c547cSRui Paulo * 9245b9c547cSRui Paulo * This parameter controls the length of the random passphrase that is 9255b9c547cSRui Paulo * generated at the GO. 9265b9c547cSRui Paulo */ 9275b9c547cSRui Paulo unsigned int p2p_passphrase_len; 9285b9c547cSRui Paulo 9295b9c547cSRui Paulo /** 930e28a4053SRui Paulo * bss_max_count - Maximum number of BSS entries to keep in memory 931e28a4053SRui Paulo */ 932e28a4053SRui Paulo unsigned int bss_max_count; 933e28a4053SRui Paulo 934e28a4053SRui Paulo /** 935f05cddf9SRui Paulo * bss_expiration_age - BSS entry age after which it can be expired 936f05cddf9SRui Paulo * 937f05cddf9SRui Paulo * This value controls the time in seconds after which a BSS entry 938f05cddf9SRui Paulo * gets removed if it has not been updated or is not in use. 939f05cddf9SRui Paulo */ 940f05cddf9SRui Paulo unsigned int bss_expiration_age; 941f05cddf9SRui Paulo 942f05cddf9SRui Paulo /** 943f05cddf9SRui Paulo * bss_expiration_scan_count - Expire BSS after number of scans 944f05cddf9SRui Paulo * 945f05cddf9SRui Paulo * If the BSS entry has not been seen in this many scans, it will be 946f05cddf9SRui Paulo * removed. A value of 1 means that entry is removed after the first 947f05cddf9SRui Paulo * scan in which the BSSID is not seen. Larger values can be used 948f05cddf9SRui Paulo * to avoid BSS entries disappearing if they are not visible in 949f05cddf9SRui Paulo * every scan (e.g., low signal quality or interference). 950f05cddf9SRui Paulo */ 951f05cddf9SRui Paulo unsigned int bss_expiration_scan_count; 952f05cddf9SRui Paulo 953f05cddf9SRui Paulo /** 954e28a4053SRui Paulo * filter_ssids - SSID-based scan result filtering 955e28a4053SRui Paulo * 956e28a4053SRui Paulo * 0 = do not filter scan results 957e28a4053SRui Paulo * 1 = only include configured SSIDs in scan results/BSS table 958e28a4053SRui Paulo */ 959e28a4053SRui Paulo int filter_ssids; 960f05cddf9SRui Paulo 961f05cddf9SRui Paulo /** 962f05cddf9SRui Paulo * filter_rssi - RSSI-based scan result filtering 963f05cddf9SRui Paulo * 964f05cddf9SRui Paulo * 0 = do not filter scan results 965f05cddf9SRui Paulo * -n = filter scan results below -n dBm 966f05cddf9SRui Paulo */ 967f05cddf9SRui Paulo int filter_rssi; 968f05cddf9SRui Paulo 969f05cddf9SRui Paulo /** 970f05cddf9SRui Paulo * max_num_sta - Maximum number of STAs in an AP/P2P GO 971f05cddf9SRui Paulo */ 972f05cddf9SRui Paulo unsigned int max_num_sta; 973f05cddf9SRui Paulo 974f05cddf9SRui Paulo /** 97585732ac8SCy Schubert * ap_isolate - Whether to use client isolation feature 97685732ac8SCy Schubert * 97785732ac8SCy Schubert * Client isolation can be used to prevent low-level bridging of 97885732ac8SCy Schubert * frames between associated stations in the BSS. By default, 97985732ac8SCy Schubert * this bridging is allowed (ap_isolate=0); except in P2P GO case, 98085732ac8SCy Schubert * where p2p_intra_bss parameter is used to determine whether to allow 98185732ac8SCy Schubert * intra-BSS forwarding (ap_isolate = !p2p_intra_bss). 98285732ac8SCy Schubert * 98385732ac8SCy Schubert * 0 = do not enable AP isolation 98485732ac8SCy Schubert * 1 = enable AP isolation 98585732ac8SCy Schubert */ 98685732ac8SCy Schubert int ap_isolate; 98785732ac8SCy Schubert 98885732ac8SCy Schubert /** 9895b9c547cSRui Paulo * freq_list - Array of allowed scan frequencies or %NULL for all 9905b9c547cSRui Paulo * 9915b9c547cSRui Paulo * This is an optional zero-terminated array of frequencies in 9925b9c547cSRui Paulo * megahertz (MHz) to allow for narrowing scanning range. 9935b9c547cSRui Paulo */ 9945b9c547cSRui Paulo int *freq_list; 9955b9c547cSRui Paulo 9965b9c547cSRui Paulo /** 997c1d255d3SCy Schubert * initial_freq_list - like freq_list but for initial scan 998c1d255d3SCy Schubert * 999c1d255d3SCy Schubert * This is an optional zero-terminated array of frequencies in 1000c1d255d3SCy Schubert * megahertz (MHz) to allow for narrowing scanning range when 1001c1d255d3SCy Schubert * the application is started. 1002c1d255d3SCy Schubert * 1003c1d255d3SCy Schubert * This can be used to speed up initial connection time if the 1004c1d255d3SCy Schubert * channel is known ahead of time, without limiting the scanned 1005c1d255d3SCy Schubert * frequencies during normal use. 1006c1d255d3SCy Schubert */ 1007c1d255d3SCy Schubert int *initial_freq_list; 1008c1d255d3SCy Schubert 1009c1d255d3SCy Schubert /** 10105b9c547cSRui Paulo * scan_cur_freq - Whether to scan only the current channel 10115b9c547cSRui Paulo * 10125b9c547cSRui Paulo * If true, attempt to scan only the current channel if any other 10135b9c547cSRui Paulo * VIFs on this radio are already associated on a particular channel. 10145b9c547cSRui Paulo */ 10155b9c547cSRui Paulo int scan_cur_freq; 10165b9c547cSRui Paulo 10175b9c547cSRui Paulo /** 1018c1d255d3SCy Schubert * scan_res_valid_for_connect - Seconds scans are valid for association 1019c1d255d3SCy Schubert * 1020c1d255d3SCy Schubert * This configures the number of seconds old scan results are considered 1021c1d255d3SCy Schubert * valid for association. When scan results are older than this value 1022c1d255d3SCy Schubert * a new scan is triggered prior to the association. 1023c1d255d3SCy Schubert */ 1024c1d255d3SCy Schubert int scan_res_valid_for_connect; 1025c1d255d3SCy Schubert 1026c1d255d3SCy Schubert /** 1027f05cddf9SRui Paulo * changed_parameters - Bitmap of changed parameters since last update 1028f05cddf9SRui Paulo */ 1029f05cddf9SRui Paulo unsigned int changed_parameters; 1030f05cddf9SRui Paulo 1031f05cddf9SRui Paulo /** 103285732ac8SCy Schubert * disassoc_low_ack - Disassociate stations with massive packet loss 1033f05cddf9SRui Paulo */ 1034f05cddf9SRui Paulo int disassoc_low_ack; 1035f05cddf9SRui Paulo 1036f05cddf9SRui Paulo /** 1037f05cddf9SRui Paulo * interworking - Whether Interworking (IEEE 802.11u) is enabled 1038f05cddf9SRui Paulo */ 1039f05cddf9SRui Paulo int interworking; 1040f05cddf9SRui Paulo 1041f05cddf9SRui Paulo /** 1042f05cddf9SRui Paulo * access_network_type - Access Network Type 1043f05cddf9SRui Paulo * 1044f05cddf9SRui Paulo * When Interworking is enabled, scans will be limited to APs that 1045f05cddf9SRui Paulo * advertise the specified Access Network Type (0..15; with 15 1046f05cddf9SRui Paulo * indicating wildcard match). 1047f05cddf9SRui Paulo */ 1048f05cddf9SRui Paulo int access_network_type; 1049f05cddf9SRui Paulo 1050f05cddf9SRui Paulo /** 105185732ac8SCy Schubert * go_interworking - Whether Interworking for P2P GO is enabled 105285732ac8SCy Schubert */ 105385732ac8SCy Schubert int go_interworking; 105485732ac8SCy Schubert 105585732ac8SCy Schubert /** 105685732ac8SCy Schubert * go_access_network_type - P2P GO Access Network Type 105785732ac8SCy Schubert * 105885732ac8SCy Schubert * This indicates which access network type to advertise if Interworking 105985732ac8SCy Schubert * is enabled for P2P GO. 106085732ac8SCy Schubert */ 106185732ac8SCy Schubert int go_access_network_type; 106285732ac8SCy Schubert 106385732ac8SCy Schubert /** 106485732ac8SCy Schubert * go_internet - Interworking: Internet connectivity (0 or 1) 106585732ac8SCy Schubert */ 106685732ac8SCy Schubert int go_internet; 106785732ac8SCy Schubert 106885732ac8SCy Schubert /** 106985732ac8SCy Schubert * go_venue_group - Interworking: Venue group 107085732ac8SCy Schubert */ 107185732ac8SCy Schubert int go_venue_group; 107285732ac8SCy Schubert 107385732ac8SCy Schubert /** 107485732ac8SCy Schubert * go_venue_type: Interworking: Venue type 107585732ac8SCy Schubert */ 107685732ac8SCy Schubert int go_venue_type; 107785732ac8SCy Schubert 107885732ac8SCy Schubert /** 1079c1d255d3SCy Schubert * hessid - Homogeneous ESS identifier 1080f05cddf9SRui Paulo * 1081f05cddf9SRui Paulo * If this is set (any octet is non-zero), scans will be used to 1082f05cddf9SRui Paulo * request response only from BSSes belonging to the specified 1083f05cddf9SRui Paulo * Homogeneous ESS. This is used only if interworking is enabled. 1084f05cddf9SRui Paulo */ 1085f05cddf9SRui Paulo u8 hessid[ETH_ALEN]; 1086f05cddf9SRui Paulo 1087f05cddf9SRui Paulo /** 1088f05cddf9SRui Paulo * hs20 - Hotspot 2.0 1089f05cddf9SRui Paulo */ 1090f05cddf9SRui Paulo int hs20; 1091f05cddf9SRui Paulo 1092f05cddf9SRui Paulo /** 1093f05cddf9SRui Paulo * pbc_in_m1 - AP mode WPS probing workaround for PBC with Windows 7 1094f05cddf9SRui Paulo * 1095f05cddf9SRui Paulo * Windows 7 uses incorrect way of figuring out AP's WPS capabilities 1096f05cddf9SRui Paulo * by acting as a Registrar and using M1 from the AP. The config 1097f05cddf9SRui Paulo * methods attribute in that message is supposed to indicate only the 1098f05cddf9SRui Paulo * configuration method supported by the AP in Enrollee role, i.e., to 1099f05cddf9SRui Paulo * add an external Registrar. For that case, PBC shall not be used and 1100f05cddf9SRui Paulo * as such, the PushButton config method is removed from M1 by default. 1101f05cddf9SRui Paulo * If pbc_in_m1=1 is included in the configuration file, the PushButton 1102f05cddf9SRui Paulo * config method is left in M1 (if included in config_methods 1103f05cddf9SRui Paulo * parameter) to allow Windows 7 to use PBC instead of PIN (e.g., from 1104f05cddf9SRui Paulo * a label in the AP). 1105f05cddf9SRui Paulo */ 1106f05cddf9SRui Paulo int pbc_in_m1; 1107f05cddf9SRui Paulo 1108f05cddf9SRui Paulo /** 1109f05cddf9SRui Paulo * autoscan - Automatic scan parameters or %NULL if none 1110f05cddf9SRui Paulo * 1111f05cddf9SRui Paulo * This is an optional set of parameters for automatic scanning 1112f05cddf9SRui Paulo * within an interface in following format: 1113f05cddf9SRui Paulo * <autoscan module name>:<module parameters> 1114f05cddf9SRui Paulo */ 1115f05cddf9SRui Paulo char *autoscan; 1116f05cddf9SRui Paulo 1117f05cddf9SRui Paulo /** 11185b9c547cSRui Paulo * wps_nfc_pw_from_config - NFC Device Password was read from config 11195b9c547cSRui Paulo * 11205b9c547cSRui Paulo * This parameter can be determined whether the NFC Device Password was 11215b9c547cSRui Paulo * included in the configuration (1) or generated dynamically (0). Only 11225b9c547cSRui Paulo * the former case is re-written back to the configuration file. 11235b9c547cSRui Paulo */ 11245b9c547cSRui Paulo int wps_nfc_pw_from_config; 11255b9c547cSRui Paulo 11265b9c547cSRui Paulo /** 1127f05cddf9SRui Paulo * wps_nfc_dev_pw_id - NFC Device Password ID for password token 1128f05cddf9SRui Paulo */ 1129f05cddf9SRui Paulo int wps_nfc_dev_pw_id; 1130f05cddf9SRui Paulo 1131f05cddf9SRui Paulo /** 1132f05cddf9SRui Paulo * wps_nfc_dh_pubkey - NFC DH Public Key for password token 1133f05cddf9SRui Paulo */ 1134f05cddf9SRui Paulo struct wpabuf *wps_nfc_dh_pubkey; 1135f05cddf9SRui Paulo 1136f05cddf9SRui Paulo /** 1137f05cddf9SRui Paulo * wps_nfc_dh_privkey - NFC DH Private Key for password token 1138f05cddf9SRui Paulo */ 1139f05cddf9SRui Paulo struct wpabuf *wps_nfc_dh_privkey; 1140f05cddf9SRui Paulo 1141f05cddf9SRui Paulo /** 1142f05cddf9SRui Paulo * wps_nfc_dev_pw - NFC Device Password for password token 1143f05cddf9SRui Paulo */ 1144f05cddf9SRui Paulo struct wpabuf *wps_nfc_dev_pw; 1145f05cddf9SRui Paulo 1146f05cddf9SRui Paulo /** 1147f05cddf9SRui Paulo * ext_password_backend - External password backend or %NULL if none 1148f05cddf9SRui Paulo * 1149f05cddf9SRui Paulo * format: <backend name>[:<optional backend parameters>] 1150f05cddf9SRui Paulo */ 1151f05cddf9SRui Paulo char *ext_password_backend; 1152f05cddf9SRui Paulo 1153f05cddf9SRui Paulo /* 1154f05cddf9SRui Paulo * p2p_go_max_inactivity - Timeout in seconds to detect STA inactivity 1155f05cddf9SRui Paulo * 1156f05cddf9SRui Paulo * This timeout value is used in P2P GO mode to clean up 1157f05cddf9SRui Paulo * inactive stations. 1158f05cddf9SRui Paulo * By default: 300 seconds. 1159f05cddf9SRui Paulo */ 1160f05cddf9SRui Paulo int p2p_go_max_inactivity; 1161f05cddf9SRui Paulo 1162f05cddf9SRui Paulo struct hostapd_wmm_ac_params wmm_ac_params[4]; 1163c1d255d3SCy Schubert struct hostapd_tx_queue_params tx_queue[4]; 1164f05cddf9SRui Paulo 1165f05cddf9SRui Paulo /** 1166f05cddf9SRui Paulo * auto_interworking - Whether to use network selection automatically 1167f05cddf9SRui Paulo * 1168f05cddf9SRui Paulo * 0 = do not automatically go through Interworking network selection 1169f05cddf9SRui Paulo * (i.e., require explicit interworking_select command for this) 1170f05cddf9SRui Paulo * 1 = perform Interworking network selection if one or more 1171f05cddf9SRui Paulo * credentials have been configured and scan did not find a 1172f05cddf9SRui Paulo * matching network block 1173f05cddf9SRui Paulo */ 1174f05cddf9SRui Paulo int auto_interworking; 1175f05cddf9SRui Paulo 1176f05cddf9SRui Paulo /** 1177f05cddf9SRui Paulo * p2p_go_ht40 - Default mode for HT40 enable when operating as GO. 1178f05cddf9SRui Paulo * 1179f05cddf9SRui Paulo * This will take effect for p2p_group_add, p2p_connect, and p2p_invite. 1180f05cddf9SRui Paulo * Note that regulatory constraints and driver capabilities are 1181f05cddf9SRui Paulo * consulted anyway, so setting it to 1 can't do real harm. 1182f05cddf9SRui Paulo * By default: 0 (disabled) 1183f05cddf9SRui Paulo */ 1184f05cddf9SRui Paulo int p2p_go_ht40; 1185f05cddf9SRui Paulo 1186f05cddf9SRui Paulo /** 11875b9c547cSRui Paulo * p2p_go_vht - Default mode for VHT enable when operating as GO 11885b9c547cSRui Paulo * 11895b9c547cSRui Paulo * This will take effect for p2p_group_add, p2p_connect, and p2p_invite. 11905b9c547cSRui Paulo * Note that regulatory constraints and driver capabilities are 11915b9c547cSRui Paulo * consulted anyway, so setting it to 1 can't do real harm. 11925b9c547cSRui Paulo * By default: 0 (disabled) 11935b9c547cSRui Paulo */ 11945b9c547cSRui Paulo int p2p_go_vht; 11955b9c547cSRui Paulo 11965b9c547cSRui Paulo /** 1197c1d255d3SCy Schubert * p2p_go_edmg - Default mode for EDMG enable when operating as GO 1198c1d255d3SCy Schubert * 1199c1d255d3SCy Schubert * This will take effect for p2p_group_add, p2p_connect, and p2p_invite. 1200c1d255d3SCy Schubert * Note that regulatory constraints and driver capabilities are 1201c1d255d3SCy Schubert * consulted anyway, so setting it to 1 can't do real harm. 1202c1d255d3SCy Schubert * By default: 0 (disabled) 1203c1d255d3SCy Schubert */ 1204c1d255d3SCy Schubert int p2p_go_edmg; 1205c1d255d3SCy Schubert 1206c1d255d3SCy Schubert /** 12074bc52338SCy Schubert * p2p_go_he - Default mode for 11ax HE enable when operating as GO 12084bc52338SCy Schubert * 12094bc52338SCy Schubert * This will take effect for p2p_group_add, p2p_connect, and p2p_invite. 12104bc52338SCy Schubert * Note that regulatory constraints and driver capabilities are 12114bc52338SCy Schubert * consulted anyway, so setting it to 1 can't do real harm. 12124bc52338SCy Schubert * By default: 0 (disabled) 12134bc52338SCy Schubert */ 12144bc52338SCy Schubert int p2p_go_he; 12154bc52338SCy Schubert 12164bc52338SCy Schubert /** 12175b9c547cSRui Paulo * p2p_go_ctwindow - CTWindow to use when operating as GO 12185b9c547cSRui Paulo * 12195b9c547cSRui Paulo * By default: 0 (no CTWindow). Values 0-127 can be used to indicate 12205b9c547cSRui Paulo * the length of the CTWindow in TUs. 12215b9c547cSRui Paulo */ 12225b9c547cSRui Paulo int p2p_go_ctwindow; 12235b9c547cSRui Paulo 12245b9c547cSRui Paulo /** 1225f05cddf9SRui Paulo * p2p_disabled - Whether P2P operations are disabled for this interface 1226f05cddf9SRui Paulo */ 1227f05cddf9SRui Paulo int p2p_disabled; 1228f05cddf9SRui Paulo 1229f05cddf9SRui Paulo /** 1230f05cddf9SRui Paulo * p2p_no_group_iface - Whether group interfaces can be used 1231f05cddf9SRui Paulo * 1232f05cddf9SRui Paulo * By default, wpa_supplicant will create a separate interface for P2P 1233f05cddf9SRui Paulo * group operations if the driver supports this. This functionality can 1234f05cddf9SRui Paulo * be disabled by setting this parameter to 1. In that case, the same 1235f05cddf9SRui Paulo * interface that was used for the P2P management operations is used 1236f05cddf9SRui Paulo * also for the group operation. 1237f05cddf9SRui Paulo */ 1238f05cddf9SRui Paulo int p2p_no_group_iface; 1239f05cddf9SRui Paulo 1240f05cddf9SRui Paulo /** 1241325151a3SRui Paulo * p2p_cli_probe - Enable/disable P2P CLI probe request handling 1242325151a3SRui Paulo * 1243325151a3SRui Paulo * If this parameter is set to 1, a connected P2P Client will receive 1244325151a3SRui Paulo * and handle Probe Request frames. Setting this parameter to 0 1245325151a3SRui Paulo * disables this option. Default value: 0. 1246325151a3SRui Paulo * 1247325151a3SRui Paulo * Note: Setting this property at run time takes effect on the following 1248325151a3SRui Paulo * interface state transition to/from the WPA_COMPLETED state. 1249325151a3SRui Paulo */ 1250325151a3SRui Paulo int p2p_cli_probe; 1251325151a3SRui Paulo 1252325151a3SRui Paulo /** 1253f05cddf9SRui Paulo * okc - Whether to enable opportunistic key caching by default 1254f05cddf9SRui Paulo * 1255f05cddf9SRui Paulo * By default, OKC is disabled unless enabled by the per-network 1256f05cddf9SRui Paulo * proactive_key_caching=1 parameter. okc=1 can be used to change this 1257f05cddf9SRui Paulo * default behavior. 1258f05cddf9SRui Paulo */ 1259f05cddf9SRui Paulo int okc; 1260f05cddf9SRui Paulo 1261f05cddf9SRui Paulo /** 1262f05cddf9SRui Paulo * pmf - Whether to enable/require PMF by default 1263f05cddf9SRui Paulo * 1264f05cddf9SRui Paulo * By default, PMF is disabled unless enabled by the per-network 1265f05cddf9SRui Paulo * ieee80211w=1 or ieee80211w=2 parameter. pmf=1/2 can be used to change 1266780fb4a2SCy Schubert * this default behavior for RSN network (this is not applicable for 1267780fb4a2SCy Schubert * non-RSN cases). 1268f05cddf9SRui Paulo */ 1269f05cddf9SRui Paulo enum mfp_options pmf; 12705b9c547cSRui Paulo 12715b9c547cSRui Paulo /** 1272*a90b9d01SCy Schubert * sae_check_mfp - Whether to limit SAE based on PMF capabilities 1273*a90b9d01SCy Schubert * 1274*a90b9d01SCy Schubert * With this check SAE key_mgmt will not be selected if PMF is 1275*a90b9d01SCy Schubert * not enabled. 1276*a90b9d01SCy Schubert * Scenarios where enabling this check will limit SAE: 1277*a90b9d01SCy Schubert * 1) ieee8011w=0 is set for the network. 1278*a90b9d01SCy Schubert * 2) The AP does not have PMF enabled. 1279*a90b9d01SCy Schubert * 3) ieee8011w for the network is the default(3), pmf=1 is enabled 1280*a90b9d01SCy Schubert * globally and the device does not support the BIP cipher. 1281*a90b9d01SCy Schubert * 1282*a90b9d01SCy Schubert * Useful to allow the BIP cipher check that occurs for ieee80211w=3 1283*a90b9d01SCy Schubert * and pmf=1 to also avoid using SAE key_mgmt. 1284*a90b9d01SCy Schubert * Useful when hardware does not support BIP to still to allow 1285*a90b9d01SCy Schubert * connecting to sae_require_mfp=1 WPA2+WPA3-Personal transition mode 1286*a90b9d01SCy Schubert *access points by automatically selecting PSK instead of SAE. 1287*a90b9d01SCy Schubert */ 1288*a90b9d01SCy Schubert int sae_check_mfp; 1289*a90b9d01SCy Schubert 1290*a90b9d01SCy Schubert /** 12915b9c547cSRui Paulo * sae_groups - Preference list of enabled groups for SAE 12925b9c547cSRui Paulo * 12935b9c547cSRui Paulo * By default (if this parameter is not set), the mandatory group 19 12945b9c547cSRui Paulo * (ECC group defined over a 256-bit prime order field) is preferred, 12955b9c547cSRui Paulo * but other groups are also enabled. If this parameter is set, the 12965b9c547cSRui Paulo * groups will be tried in the indicated order. 12975b9c547cSRui Paulo */ 12985b9c547cSRui Paulo int *sae_groups; 12995b9c547cSRui Paulo 13005b9c547cSRui Paulo /** 1301c1d255d3SCy Schubert * sae_pwe - SAE mechanism for PWE derivation 1302c1d255d3SCy Schubert * 0 = hunting-and-pecking loop only 1303c1d255d3SCy Schubert * 1 = hash-to-element only 1304c1d255d3SCy Schubert * 2 = both hunting-and-pecking loop and hash-to-element enabled 1305c1d255d3SCy Schubert */ 1306*a90b9d01SCy Schubert enum sae_pwe sae_pwe; 1307c1d255d3SCy Schubert 1308c1d255d3SCy Schubert /** 1309c1d255d3SCy Schubert * sae_pmkid_in_assoc - Whether to include PMKID in SAE Assoc Req 1310c1d255d3SCy Schubert */ 1311c1d255d3SCy Schubert int sae_pmkid_in_assoc; 1312c1d255d3SCy Schubert 1313c1d255d3SCy Schubert /** 13145b9c547cSRui Paulo * dtim_period - Default DTIM period in Beacon intervals 13155b9c547cSRui Paulo * 13165b9c547cSRui Paulo * This parameter can be used to set the default value for network 13175b9c547cSRui Paulo * blocks that do not specify dtim_period. 13185b9c547cSRui Paulo */ 13195b9c547cSRui Paulo int dtim_period; 13205b9c547cSRui Paulo 13215b9c547cSRui Paulo /** 13225b9c547cSRui Paulo * beacon_int - Default Beacon interval in TU 13235b9c547cSRui Paulo * 13245b9c547cSRui Paulo * This parameter can be used to set the default value for network 13255b9c547cSRui Paulo * blocks that do not specify beacon_int. 13265b9c547cSRui Paulo */ 13275b9c547cSRui Paulo int beacon_int; 13285b9c547cSRui Paulo 13295b9c547cSRui Paulo /** 13305b9c547cSRui Paulo * ap_vendor_elements: Vendor specific elements for Beacon/ProbeResp 13315b9c547cSRui Paulo * 13325b9c547cSRui Paulo * This parameter can be used to define additional vendor specific 13335b9c547cSRui Paulo * elements for Beacon and Probe Response frames in AP/P2P GO mode. The 13345b9c547cSRui Paulo * format for these element(s) is a hexdump of the raw information 13355b9c547cSRui Paulo * elements (id+len+payload for one or more elements). 13365b9c547cSRui Paulo */ 13375b9c547cSRui Paulo struct wpabuf *ap_vendor_elements; 13385b9c547cSRui Paulo 13395b9c547cSRui Paulo /** 13404b72b91aSCy Schubert * ap_assocresp_elements: Vendor specific elements for (Re)Association 13414b72b91aSCy Schubert * Response frames 13424b72b91aSCy Schubert * 13434b72b91aSCy Schubert * This parameter can be used to define additional vendor specific 13444b72b91aSCy Schubert * elements for (Re)Association Response frames in AP/P2P GO mode. The 13454b72b91aSCy Schubert * format for these element(s) is a hexdump of the raw information 13464b72b91aSCy Schubert * elements (id+len+payload for one or more elements). 13474b72b91aSCy Schubert */ 13484b72b91aSCy Schubert struct wpabuf *ap_assocresp_elements; 13494b72b91aSCy Schubert 13504b72b91aSCy Schubert /** 13515b9c547cSRui Paulo * ignore_old_scan_res - Ignore scan results older than request 13525b9c547cSRui Paulo * 13535b9c547cSRui Paulo * The driver may have a cache of scan results that makes it return 13545b9c547cSRui Paulo * information that is older than our scan trigger. This parameter can 13555b9c547cSRui Paulo * be used to configure such old information to be ignored instead of 13565b9c547cSRui Paulo * allowing it to update the internal BSS table. 13575b9c547cSRui Paulo */ 13585b9c547cSRui Paulo int ignore_old_scan_res; 13595b9c547cSRui Paulo 13605b9c547cSRui Paulo /** 13615b9c547cSRui Paulo * sched_scan_interval - schedule scan interval 13625b9c547cSRui Paulo */ 13635b9c547cSRui Paulo unsigned int sched_scan_interval; 13645b9c547cSRui Paulo 13655b9c547cSRui Paulo /** 136685732ac8SCy Schubert * sched_scan_start_delay - Schedule scan start delay before first scan 136785732ac8SCy Schubert * 136885732ac8SCy Schubert * Delay (in seconds) before scheduling first scan plan cycle. The 136985732ac8SCy Schubert * driver may ignore this parameter and start immediately (or at any 137085732ac8SCy Schubert * other time), if this feature is not supported. 137185732ac8SCy Schubert */ 137285732ac8SCy Schubert unsigned int sched_scan_start_delay; 137385732ac8SCy Schubert 137485732ac8SCy Schubert /** 13755b9c547cSRui Paulo * tdls_external_control - External control for TDLS setup requests 13765b9c547cSRui Paulo * 13775b9c547cSRui Paulo * Enable TDLS mode where external programs are given the control 13785b9c547cSRui Paulo * to specify the TDLS link to get established to the driver. The 13795b9c547cSRui Paulo * driver requests the TDLS setup to the supplicant only for the 13805b9c547cSRui Paulo * specified TDLS peers. 13815b9c547cSRui Paulo */ 13825b9c547cSRui Paulo int tdls_external_control; 13835b9c547cSRui Paulo 13845b9c547cSRui Paulo u8 ip_addr_go[4]; 13855b9c547cSRui Paulo u8 ip_addr_mask[4]; 13865b9c547cSRui Paulo u8 ip_addr_start[4]; 13875b9c547cSRui Paulo u8 ip_addr_end[4]; 13885b9c547cSRui Paulo 13895b9c547cSRui Paulo /** 13905b9c547cSRui Paulo * osu_dir - OSU provider information directory 13915b9c547cSRui Paulo * 13925b9c547cSRui Paulo * If set, allow FETCH_OSU control interface command to be used to fetch 13935b9c547cSRui Paulo * OSU provider information into all APs and store the results in this 13945b9c547cSRui Paulo * directory. 13955b9c547cSRui Paulo */ 13965b9c547cSRui Paulo char *osu_dir; 13975b9c547cSRui Paulo 13985b9c547cSRui Paulo /** 13995b9c547cSRui Paulo * wowlan_triggers - Wake-on-WLAN triggers 14005b9c547cSRui Paulo * 14015b9c547cSRui Paulo * If set, these wowlan triggers will be configured. 14025b9c547cSRui Paulo */ 14035b9c547cSRui Paulo char *wowlan_triggers; 14045b9c547cSRui Paulo 14055b9c547cSRui Paulo /** 14065b9c547cSRui Paulo * p2p_search_delay - Extra delay between concurrent search iterations 14075b9c547cSRui Paulo * 14085b9c547cSRui Paulo * Add extra delay (in milliseconds) between search iterations when 14095b9c547cSRui Paulo * there is a concurrent operation to make p2p_find friendlier to 14105b9c547cSRui Paulo * concurrent operations by avoiding it from taking 100% of radio 14115b9c547cSRui Paulo * resources. 14125b9c547cSRui Paulo */ 14135b9c547cSRui Paulo unsigned int p2p_search_delay; 14145b9c547cSRui Paulo 14155b9c547cSRui Paulo /** 14165b9c547cSRui Paulo * mac_addr - MAC address policy default 14175b9c547cSRui Paulo * 14185b9c547cSRui Paulo * 0 = use permanent MAC address 14195b9c547cSRui Paulo * 1 = use random MAC address for each ESS connection 14205b9c547cSRui Paulo * 2 = like 1, but maintain OUI (with local admin bit set) 14215b9c547cSRui Paulo * 14225b9c547cSRui Paulo * By default, permanent MAC address is used unless policy is changed by 14235b9c547cSRui Paulo * the per-network mac_addr parameter. Global mac_addr=1 can be used to 14245b9c547cSRui Paulo * change this default behavior. 14255b9c547cSRui Paulo */ 1426*a90b9d01SCy Schubert enum wpas_mac_addr_style mac_addr; 14275b9c547cSRui Paulo 14285b9c547cSRui Paulo /** 14295b9c547cSRui Paulo * rand_addr_lifetime - Lifetime of random MAC address in seconds 14305b9c547cSRui Paulo */ 14315b9c547cSRui Paulo unsigned int rand_addr_lifetime; 14325b9c547cSRui Paulo 14335b9c547cSRui Paulo /** 14345b9c547cSRui Paulo * preassoc_mac_addr - Pre-association MAC address policy 14355b9c547cSRui Paulo * 14365b9c547cSRui Paulo * 0 = use permanent MAC address 14375b9c547cSRui Paulo * 1 = use random MAC address 14385b9c547cSRui Paulo * 2 = like 1, but maintain OUI (with local admin bit set) 14395b9c547cSRui Paulo */ 1440*a90b9d01SCy Schubert enum wpas_mac_addr_style preassoc_mac_addr; 14415b9c547cSRui Paulo 14425b9c547cSRui Paulo /** 14435b9c547cSRui Paulo * key_mgmt_offload - Use key management offload 14445b9c547cSRui Paulo * 14455b9c547cSRui Paulo * Key management offload should be used if the device supports it. 14465b9c547cSRui Paulo * Key management offload is the capability of a device operating as 14475b9c547cSRui Paulo * a station to do the exchange necessary to establish temporal keys 14485b9c547cSRui Paulo * during initial RSN connection, after roaming, or during a PTK 14495b9c547cSRui Paulo * rekeying operation. 14505b9c547cSRui Paulo */ 14515b9c547cSRui Paulo int key_mgmt_offload; 14525b9c547cSRui Paulo 14535b9c547cSRui Paulo /** 14545b9c547cSRui Paulo * user_mpm - MPM residency 14555b9c547cSRui Paulo * 14565b9c547cSRui Paulo * 0: MPM lives in driver. 14575b9c547cSRui Paulo * 1: wpa_supplicant handles peering and station allocation. 14585b9c547cSRui Paulo * 14595b9c547cSRui Paulo * If AMPE or SAE is enabled, the MPM is always in userspace. 14605b9c547cSRui Paulo */ 14615b9c547cSRui Paulo int user_mpm; 14625b9c547cSRui Paulo 14635b9c547cSRui Paulo /** 14645b9c547cSRui Paulo * max_peer_links - Maximum number of peer links 14655b9c547cSRui Paulo * 14665b9c547cSRui Paulo * Maximum number of mesh peering currently maintained by the STA. 14675b9c547cSRui Paulo */ 14685b9c547cSRui Paulo int max_peer_links; 14695b9c547cSRui Paulo 14705b9c547cSRui Paulo /** 14715b9c547cSRui Paulo * cert_in_cb - Whether to include a peer certificate dump in events 14725b9c547cSRui Paulo * 14735b9c547cSRui Paulo * This controls whether peer certificates for authentication server and 14745b9c547cSRui Paulo * its certificate chain are included in EAP peer certificate events. 14755b9c547cSRui Paulo */ 14765b9c547cSRui Paulo int cert_in_cb; 14775b9c547cSRui Paulo 14785b9c547cSRui Paulo /** 14795b9c547cSRui Paulo * mesh_max_inactivity - Timeout in seconds to detect STA inactivity 14805b9c547cSRui Paulo * 14815b9c547cSRui Paulo * This timeout value is used in mesh STA to clean up inactive stations. 14825b9c547cSRui Paulo * By default: 300 seconds. 14835b9c547cSRui Paulo */ 14845b9c547cSRui Paulo int mesh_max_inactivity; 14855b9c547cSRui Paulo 14865b9c547cSRui Paulo /** 148732a95656SCy Schubert * mesh_fwding - Mesh network layer-2 forwarding (dot11MeshForwarding) 148832a95656SCy Schubert * 148932a95656SCy Schubert * This controls whether to enable layer-2 forwarding. 149032a95656SCy Schubert * By default: 1: enabled 149132a95656SCy Schubert */ 149232a95656SCy Schubert int mesh_fwding; 149332a95656SCy Schubert 149432a95656SCy Schubert /** 1495325151a3SRui Paulo * dot11RSNASAERetransPeriod - Timeout to retransmit SAE Auth frame 1496325151a3SRui Paulo * 1497325151a3SRui Paulo * This timeout value is used in mesh STA to retransmit 1498325151a3SRui Paulo * SAE Authentication frame. 1499325151a3SRui Paulo * By default: 1000 milliseconds. 1500325151a3SRui Paulo */ 1501325151a3SRui Paulo int dot11RSNASAERetransPeriod; 1502325151a3SRui Paulo 1503325151a3SRui Paulo /** 15045b9c547cSRui Paulo * passive_scan - Whether to force passive scan for network connection 15055b9c547cSRui Paulo * 15065b9c547cSRui Paulo * This parameter can be used to force only passive scanning to be used 15075b9c547cSRui Paulo * for network connection cases. It should be noted that this will slow 15085b9c547cSRui Paulo * down scan operations and reduce likelihood of finding the AP. In 15095b9c547cSRui Paulo * addition, some use cases will override this due to functional 15105b9c547cSRui Paulo * requirements, e.g., for finding an AP that uses hidden SSID 15115b9c547cSRui Paulo * (scan_ssid=1) or P2P device discovery. 15125b9c547cSRui Paulo */ 15135b9c547cSRui Paulo int passive_scan; 15145b9c547cSRui Paulo 15155b9c547cSRui Paulo /** 15165b9c547cSRui Paulo * reassoc_same_bss_optim - Whether to optimize reassoc-to-same-BSS 15175b9c547cSRui Paulo */ 15185b9c547cSRui Paulo int reassoc_same_bss_optim; 1519325151a3SRui Paulo 1520325151a3SRui Paulo /** 1521325151a3SRui Paulo * wps_priority - Priority for the networks added through WPS 1522325151a3SRui Paulo * 1523325151a3SRui Paulo * This priority value will be set to each network profile that is added 1524325151a3SRui Paulo * by executing the WPS protocol. 1525325151a3SRui Paulo */ 1526325151a3SRui Paulo int wps_priority; 1527325151a3SRui Paulo 1528325151a3SRui Paulo /** 1529325151a3SRui Paulo * fst_group_id - FST group ID 1530325151a3SRui Paulo */ 1531325151a3SRui Paulo char *fst_group_id; 1532325151a3SRui Paulo 1533325151a3SRui Paulo /** 1534325151a3SRui Paulo * fst_priority - priority of the interface within the FST group 1535325151a3SRui Paulo */ 1536325151a3SRui Paulo int fst_priority; 1537325151a3SRui Paulo 1538325151a3SRui Paulo /** 1539325151a3SRui Paulo * fst_llt - default FST LLT (Link-Lost Timeout) to be used for the 1540325151a3SRui Paulo * interface. 1541325151a3SRui Paulo */ 1542325151a3SRui Paulo int fst_llt; 1543780fb4a2SCy Schubert 1544780fb4a2SCy Schubert /** 1545780fb4a2SCy Schubert * wpa_rsc_relaxation - RSC relaxation on GTK installation 1546780fb4a2SCy Schubert * 1547780fb4a2SCy Schubert * Values: 1548780fb4a2SCy Schubert * 0 - use the EAPOL-Key RSC value on GTK installation 1549780fb4a2SCy Schubert * 1 - use the null RSC if a bogus RSC value is detected in message 3 1550780fb4a2SCy Schubert * of 4-Way Handshake or message 1 of Group Key Handshake. 1551780fb4a2SCy Schubert */ 1552780fb4a2SCy Schubert int wpa_rsc_relaxation; 1553780fb4a2SCy Schubert 1554780fb4a2SCy Schubert /** 1555780fb4a2SCy Schubert * sched_scan_plans - Scan plans for scheduled scan 1556780fb4a2SCy Schubert * 1557780fb4a2SCy Schubert * Each scan plan specifies the interval between scans and the number of 1558780fb4a2SCy Schubert * iterations. The last scan plan only specifies the scan interval and 1559780fb4a2SCy Schubert * will be run infinitely. 1560780fb4a2SCy Schubert * 1561780fb4a2SCy Schubert * format: <interval:iterations> <interval2:iterations2> ... <interval> 1562780fb4a2SCy Schubert */ 1563780fb4a2SCy Schubert char *sched_scan_plans; 1564780fb4a2SCy Schubert 1565780fb4a2SCy Schubert #ifdef CONFIG_MBO 1566780fb4a2SCy Schubert /** 1567780fb4a2SCy Schubert * non_pref_chan - Non-preferred channels list, separated by spaces. 1568780fb4a2SCy Schubert * 1569780fb4a2SCy Schubert * format: op_class:chan:preference:reason<:detail> 1570780fb4a2SCy Schubert * Detail is optional. 1571780fb4a2SCy Schubert */ 1572780fb4a2SCy Schubert char *non_pref_chan; 1573780fb4a2SCy Schubert 1574780fb4a2SCy Schubert /** 1575780fb4a2SCy Schubert * mbo_cell_capa - Cellular capabilities for MBO 1576780fb4a2SCy Schubert */ 1577780fb4a2SCy Schubert enum mbo_cellular_capa mbo_cell_capa; 157885732ac8SCy Schubert 157985732ac8SCy Schubert /** 158085732ac8SCy Schubert * disassoc_imminent_rssi_threshold - RSSI threshold of candidate AP 158185732ac8SCy Schubert * when disassociation imminent is set. 158285732ac8SCy Schubert */ 158385732ac8SCy Schubert int disassoc_imminent_rssi_threshold; 158485732ac8SCy Schubert 158585732ac8SCy Schubert /** 158685732ac8SCy Schubert * oce - Enable OCE in STA and/or STA-CFON mode 158785732ac8SCy Schubert * - Set BIT(0) to enable OCE in non-AP STA mode 158885732ac8SCy Schubert * - Set BIT(1) to enable OCE in STA-CFON mode 158985732ac8SCy Schubert */ 159085732ac8SCy Schubert unsigned int oce; 1591780fb4a2SCy Schubert #endif /* CONFIG_MBO */ 1592780fb4a2SCy Schubert 1593780fb4a2SCy Schubert /** 1594780fb4a2SCy Schubert * gas_address3 - GAS Address3 field behavior 1595780fb4a2SCy Schubert * 1596780fb4a2SCy Schubert * Values: 1597780fb4a2SCy Schubert * 0 - P2P specification (Address3 = AP BSSID) 1598780fb4a2SCy Schubert * 1 = IEEE 802.11 standard compliant (Address3 = Wildcard BSSID when 1599780fb4a2SCy Schubert * sent to not-associated AP; if associated, AP BSSID) 1600780fb4a2SCy Schubert */ 1601780fb4a2SCy Schubert int gas_address3; 1602780fb4a2SCy Schubert 1603780fb4a2SCy Schubert /** 1604780fb4a2SCy Schubert * ftm_responder - Publish FTM (fine timing measurement) 1605780fb4a2SCy Schubert * responder functionality 1606780fb4a2SCy Schubert * 1607780fb4a2SCy Schubert * Values: 1608780fb4a2SCy Schubert * 0 - do not publish FTM responder functionality (Default) 1609780fb4a2SCy Schubert * 1 - publish FTM responder functionality in 1610780fb4a2SCy Schubert * bit 70 of Extended Capabilities element 1611780fb4a2SCy Schubert * Note, actual FTM responder operation is managed outside 1612780fb4a2SCy Schubert * wpa_supplicant. 1613780fb4a2SCy Schubert */ 1614780fb4a2SCy Schubert int ftm_responder; 1615780fb4a2SCy Schubert 1616780fb4a2SCy Schubert /** 1617780fb4a2SCy Schubert * ftm_initiator - Publish FTM (fine timing measurement) 1618780fb4a2SCy Schubert * initiator functionality 1619780fb4a2SCy Schubert * 1620780fb4a2SCy Schubert * Values: 1621780fb4a2SCy Schubert * 0 - do not publish FTM initiator functionality (Default) 1622780fb4a2SCy Schubert * 1 - publish FTM initiator functionality in 1623780fb4a2SCy Schubert * bit 71 of Extended Capabilities element 1624780fb4a2SCy Schubert * Note, actual FTM initiator operation is managed outside 1625780fb4a2SCy Schubert * wpa_supplicant. 1626780fb4a2SCy Schubert */ 1627780fb4a2SCy Schubert int ftm_initiator; 162885732ac8SCy Schubert 162985732ac8SCy Schubert /** 163085732ac8SCy Schubert * gas_rand_addr_lifetime - Lifetime of random MAC address for ANQP in 163185732ac8SCy Schubert * seconds 163285732ac8SCy Schubert */ 163385732ac8SCy Schubert unsigned int gas_rand_addr_lifetime; 163485732ac8SCy Schubert 163585732ac8SCy Schubert /** 163685732ac8SCy Schubert * gas_rand_mac_addr - GAS MAC address policy 163785732ac8SCy Schubert * 163885732ac8SCy Schubert * 0 = use permanent MAC address 163985732ac8SCy Schubert * 1 = use random MAC address 164085732ac8SCy Schubert * 2 = like 1, but maintain OUI (with local admin bit set) 164185732ac8SCy Schubert */ 1642*a90b9d01SCy Schubert enum wpas_mac_addr_style gas_rand_mac_addr; 164385732ac8SCy Schubert 164485732ac8SCy Schubert /** 164585732ac8SCy Schubert * dpp_config_processing - How to process DPP configuration 164685732ac8SCy Schubert * 164785732ac8SCy Schubert * 0 = report received configuration to an external program for 164885732ac8SCy Schubert * processing; do not generate any network profile internally 164985732ac8SCy Schubert * 1 = report received configuration to an external program and generate 165085732ac8SCy Schubert * a network profile internally, but do not automatically connect 165185732ac8SCy Schubert * to the created (disabled) profile; the network profile id is 165285732ac8SCy Schubert * reported to external programs 165385732ac8SCy Schubert * 2 = report received configuration to an external program, generate 165485732ac8SCy Schubert * a network profile internally, try to connect to the created 165585732ac8SCy Schubert * profile automatically 165685732ac8SCy Schubert */ 165785732ac8SCy Schubert int dpp_config_processing; 165885732ac8SCy Schubert 165985732ac8SCy Schubert /** 1660c1d255d3SCy Schubert * dpp_name - Name for Enrollee's DPP Configuration Request 1661c1d255d3SCy Schubert */ 1662c1d255d3SCy Schubert char *dpp_name; 1663c1d255d3SCy Schubert 1664c1d255d3SCy Schubert /** 1665c1d255d3SCy Schubert * dpp_mud_url - MUD URL for Enrollee's DPP Configuration Request 1666c1d255d3SCy Schubert */ 1667c1d255d3SCy Schubert char *dpp_mud_url; 1668c1d255d3SCy Schubert 1669c1d255d3SCy Schubert /** 1670*a90b9d01SCy Schubert * dpp_extra_conf_req_name - JSON node name of additional data for 1671*a90b9d01SCy Schubert * Enrollee's DPP Configuration Request 1672*a90b9d01SCy Schubert */ 1673*a90b9d01SCy Schubert char *dpp_extra_conf_req_name; 1674*a90b9d01SCy Schubert 1675*a90b9d01SCy Schubert /** 1676*a90b9d01SCy Schubert * dpp_extra_conf_req_value - JSON node data of additional data for 1677*a90b9d01SCy Schubert * Enrollee's DPP Configuration Request 1678*a90b9d01SCy Schubert */ 1679*a90b9d01SCy Schubert char *dpp_extra_conf_req_value; 1680*a90b9d01SCy Schubert 1681*a90b9d01SCy Schubert /* dpp_connector_privacy_default - Default valur for Connector privacy 1682*a90b9d01SCy Schubert * 1683*a90b9d01SCy Schubert * This value is used as the default for the dpp_connector_privacy 1684*a90b9d01SCy Schubert * network parameter for all new networks provisioned using DPP. 1685*a90b9d01SCy Schubert */ 1686*a90b9d01SCy Schubert int dpp_connector_privacy_default; 1687*a90b9d01SCy Schubert 1688*a90b9d01SCy Schubert /** 168985732ac8SCy Schubert * coloc_intf_reporting - Colocated interference reporting 169085732ac8SCy Schubert * 169185732ac8SCy Schubert * dot11CoLocIntfReportingActivated 169285732ac8SCy Schubert * 0 = disabled (false) 169385732ac8SCy Schubert * 1 = enabled (true) 169485732ac8SCy Schubert */ 169585732ac8SCy Schubert int coloc_intf_reporting; 16964bc52338SCy Schubert 16974bc52338SCy Schubert /** 16984bc52338SCy Schubert * p2p_device_random_mac_addr - P2P Device MAC address policy default 16994bc52338SCy Schubert * 1700c1d255d3SCy Schubert * 0 = use permanent MAC address (the one set by default by the device 1701c1d255d3SCy Schubert * driver). Notice that, if the device driver is configured to 1702c1d255d3SCy Schubert * always use random MAC addresses, this flag breaks reinvoking a 1703c1d255d3SCy Schubert * persistent group, so flags 1 or 2 should be used instead with 1704c1d255d3SCy Schubert * such drivers if persistent groups are used. 17054bc52338SCy Schubert * 1 = use random MAC address on creating the interface if there is no 1706c1d255d3SCy Schubert * persistent group. Besides, if a persistent group is created, 1707c1d255d3SCy Schubert * p2p_device_persistent_mac_addr is set to the MAC address of the 1708c1d255d3SCy Schubert * P2P Device interface, so that this address will be subsequently 1709c1d255d3SCy Schubert * used to change the MAC address of the P2P Device interface. With 1710c1d255d3SCy Schubert * no persistent group, the random MAC address is created by 1711c1d255d3SCy Schubert * wpa_supplicant, changing the one set by the device driver. 1712c1d255d3SCy Schubert * The device driver shall support SIOCGIFFLAGS/SIOCSIFFLAGS ioctl 1713c1d255d3SCy Schubert * interface control operations. 1714c1d255d3SCy Schubert * 2 = this flag should be used when the device driver uses random MAC 1715c1d255d3SCy Schubert * addresses by default when a P2P Device interface is created. 1716c1d255d3SCy Schubert * If p2p_device_persistent_mac_addr is set, use this MAC address 1717c1d255d3SCy Schubert * on creating the P2P Device interface. If not set, use the 1718c1d255d3SCy Schubert * default method adopted by the device driver (e.g., random MAC 1719c1d255d3SCy Schubert * address). Besides, if a persistent group is created, 1720c1d255d3SCy Schubert * p2p_device_persistent_mac_addr is set to the MAC address of the 1721c1d255d3SCy Schubert * P2P Device interface, so that this address will be subsequently 1722c1d255d3SCy Schubert * used in place of the default address set by the device driver. 1723c1d255d3SCy Schubert * (This option does not need support of SIOCGIFFLAGS/SIOCSIFFLAGS 1724c1d255d3SCy Schubert * ioctl interface control operations and uses NL80211_ATTR_MAC). 17254bc52338SCy Schubert * 17264bc52338SCy Schubert * By default, permanent MAC address is used. 17274bc52338SCy Schubert */ 17284bc52338SCy Schubert int p2p_device_random_mac_addr; 17294bc52338SCy Schubert 17304bc52338SCy Schubert /** 17314bc52338SCy Schubert * p2p_device_persistent_mac_addr - Record last used MAC address 17324bc52338SCy Schubert * 17334bc52338SCy Schubert * If there are saved persistent groups, P2P cannot generate another 17344bc52338SCy Schubert * random MAC address, and need to restore to last used MAC address. 17354bc52338SCy Schubert */ 17364bc52338SCy Schubert u8 p2p_device_persistent_mac_addr[ETH_ALEN]; 17374bc52338SCy Schubert 17384bc52338SCy Schubert /** 17394bc52338SCy Schubert * p2p_interface_random_mac_addr - P2P Interface MAC address policy default 17404bc52338SCy Schubert * 17414bc52338SCy Schubert * 0 = use permanent MAC address 17424bc52338SCy Schubert * 1 = use random MAC address on creating the interface. 17434bc52338SCy Schubert * 17444bc52338SCy Schubert * By default, permanent MAC address is used. 17454bc52338SCy Schubert */ 17464bc52338SCy Schubert int p2p_interface_random_mac_addr; 1747206b73d0SCy Schubert 1748206b73d0SCy Schubert /** 1749206b73d0SCy Schubert * disable_btm - Disable BSS transition management in STA 1750206b73d0SCy Schubert * - Set to 0 to enable BSS transition management 1751206b73d0SCy Schubert * - Set to 1 to disable BSS transition management 1752206b73d0SCy Schubert * 1753206b73d0SCy Schubert * By default BSS transition management is enabled 1754206b73d0SCy Schubert */ 1755206b73d0SCy Schubert int disable_btm; 1756c1d255d3SCy Schubert 1757c1d255d3SCy Schubert /** 1758c1d255d3SCy Schubert * extended_key_id - Extended Key ID support 1759c1d255d3SCy Schubert * 1760c1d255d3SCy Schubert * IEEE Std 802.11-2016 optionally allows to use Key ID 0 and 1 for PTK 1761c1d255d3SCy Schubert * keys with Extended Key ID. 1762c1d255d3SCy Schubert * 1763c1d255d3SCy Schubert * 0 = don't use Extended Key ID 1764c1d255d3SCy Schubert * 1 = use Extended Key ID when possible 1765c1d255d3SCy Schubert */ 1766c1d255d3SCy Schubert int extended_key_id; 1767c1d255d3SCy Schubert 1768c1d255d3SCy Schubert /** 1769c1d255d3SCy Schubert * wowlan_disconnect_on_deinit - Trigger disconnect on wpa_supplicant 1770c1d255d3SCy Schubert * interface deinit even if the driver has enabled WoWLAN. 1771c1d255d3SCy Schubert * 1772c1d255d3SCy Schubert * 0 = Do not disconnect 1773c1d255d3SCy Schubert * 1 = Trigger disconnection 1774c1d255d3SCy Schubert */ 1775c1d255d3SCy Schubert int wowlan_disconnect_on_deinit; 1776c1d255d3SCy Schubert 1777c1d255d3SCy Schubert #ifdef CONFIG_PASN 1778c1d255d3SCy Schubert #ifdef CONFIG_TESTING_OPTIONS 1779c1d255d3SCy Schubert /* 1780c1d255d3SCy Schubert * Normally, KDK should be derived if and only if both sides support 1781c1d255d3SCy Schubert * secure LTF. Allow forcing KDK derivation for testing purposes. 1782c1d255d3SCy Schubert */ 1783c1d255d3SCy Schubert int force_kdk_derivation; 1784c1d255d3SCy Schubert 1785c1d255d3SCy Schubert /* If set, corrupt the MIC in the 3rd Authentication frame of PASN */ 1786c1d255d3SCy Schubert int pasn_corrupt_mic; 1787c1d255d3SCy Schubert 1788c1d255d3SCy Schubert #endif /* CONFIG_TESTING_OPTIONS */ 1789c1d255d3SCy Schubert #endif /* CONFIG_PASN*/ 1790*a90b9d01SCy Schubert 1791*a90b9d01SCy Schubert #ifdef CONFIG_TESTING_OPTIONS 1792*a90b9d01SCy Schubert enum { 1793*a90b9d01SCy Schubert MLD_CONNECT_BAND_PREF_AUTO = 0, 1794*a90b9d01SCy Schubert MLD_CONNECT_BAND_PREF_2GHZ = 1, 1795*a90b9d01SCy Schubert MLD_CONNECT_BAND_PREF_5GHZ = 2, 1796*a90b9d01SCy Schubert MLD_CONNECT_BAND_PREF_6GHZ = 3, 1797*a90b9d01SCy Schubert MLD_CONNECT_BAND_PREF_MAX = 4, 1798*a90b9d01SCy Schubert } mld_connect_band_pref; 1799*a90b9d01SCy Schubert 1800*a90b9d01SCy Schubert u8 mld_connect_bssid_pref[ETH_ALEN]; 1801*a90b9d01SCy Schubert 1802*a90b9d01SCy Schubert int mld_force_single_link; 1803*a90b9d01SCy Schubert #endif /* CONFIG_TESTING_OPTIONS */ 180439beb93cSSam Leffler }; 180539beb93cSSam Leffler 180639beb93cSSam Leffler 180739beb93cSSam Leffler /* Prototypes for common functions from config.c */ 180839beb93cSSam Leffler 180939beb93cSSam Leffler void wpa_config_free(struct wpa_config *ssid); 181039beb93cSSam Leffler void wpa_config_free_ssid(struct wpa_ssid *ssid); 1811f05cddf9SRui Paulo void wpa_config_foreach_network(struct wpa_config *config, 1812f05cddf9SRui Paulo void (*func)(void *, struct wpa_ssid *), 1813f05cddf9SRui Paulo void *arg); 181439beb93cSSam Leffler struct wpa_ssid * wpa_config_get_network(struct wpa_config *config, int id); 181539beb93cSSam Leffler struct wpa_ssid * wpa_config_add_network(struct wpa_config *config); 181639beb93cSSam Leffler int wpa_config_remove_network(struct wpa_config *config, int id); 181739beb93cSSam Leffler void wpa_config_set_network_defaults(struct wpa_ssid *ssid); 181839beb93cSSam Leffler int wpa_config_set(struct wpa_ssid *ssid, const char *var, const char *value, 181939beb93cSSam Leffler int line); 1820f05cddf9SRui Paulo int wpa_config_set_quoted(struct wpa_ssid *ssid, const char *var, 1821f05cddf9SRui Paulo const char *value); 18225b9c547cSRui Paulo int wpa_config_dump_values(struct wpa_config *config, char *buf, 18235b9c547cSRui Paulo size_t buflen); 18245b9c547cSRui Paulo int wpa_config_get_value(const char *name, struct wpa_config *config, 18255b9c547cSRui Paulo char *buf, size_t buflen); 18265b9c547cSRui Paulo 1827e28a4053SRui Paulo char ** wpa_config_get_all(struct wpa_ssid *ssid, int get_keys); 182839beb93cSSam Leffler char * wpa_config_get(struct wpa_ssid *ssid, const char *var); 182939beb93cSSam Leffler char * wpa_config_get_no_key(struct wpa_ssid *ssid, const char *var); 183039beb93cSSam Leffler void wpa_config_update_psk(struct wpa_ssid *ssid); 183139beb93cSSam Leffler int wpa_config_add_prio_network(struct wpa_config *config, 183239beb93cSSam Leffler struct wpa_ssid *ssid); 1833e28a4053SRui Paulo int wpa_config_update_prio_list(struct wpa_config *config); 183439beb93cSSam Leffler const struct wpa_config_blob * wpa_config_get_blob(struct wpa_config *config, 183539beb93cSSam Leffler const char *name); 183639beb93cSSam Leffler void wpa_config_set_blob(struct wpa_config *config, 183739beb93cSSam Leffler struct wpa_config_blob *blob); 183839beb93cSSam Leffler void wpa_config_free_blob(struct wpa_config_blob *blob); 183939beb93cSSam Leffler int wpa_config_remove_blob(struct wpa_config *config, const char *name); 18405b9c547cSRui Paulo void wpa_config_flush_blobs(struct wpa_config *config); 184139beb93cSSam Leffler 1842f05cddf9SRui Paulo struct wpa_cred * wpa_config_get_cred(struct wpa_config *config, int id); 1843f05cddf9SRui Paulo struct wpa_cred * wpa_config_add_cred(struct wpa_config *config); 1844f05cddf9SRui Paulo int wpa_config_remove_cred(struct wpa_config *config, int id); 1845f05cddf9SRui Paulo void wpa_config_free_cred(struct wpa_cred *cred); 1846f05cddf9SRui Paulo int wpa_config_set_cred(struct wpa_cred *cred, const char *var, 1847f05cddf9SRui Paulo const char *value, int line); 18485b9c547cSRui Paulo char * wpa_config_get_cred_no_key(struct wpa_cred *cred, const char *var); 1849f05cddf9SRui Paulo 185039beb93cSSam Leffler struct wpa_config * wpa_config_alloc_empty(const char *ctrl_interface, 185139beb93cSSam Leffler const char *driver_param); 185239beb93cSSam Leffler #ifndef CONFIG_NO_STDOUT_DEBUG 185339beb93cSSam Leffler void wpa_config_debug_dump_networks(struct wpa_config *config); 185439beb93cSSam Leffler #else /* CONFIG_NO_STDOUT_DEBUG */ 185539beb93cSSam Leffler #define wpa_config_debug_dump_networks(c) do { } while (0) 185639beb93cSSam Leffler #endif /* CONFIG_NO_STDOUT_DEBUG */ 185739beb93cSSam Leffler 185839beb93cSSam Leffler 1859f05cddf9SRui Paulo /* Prototypes for common functions from config.c */ 1860f05cddf9SRui Paulo int wpa_config_process_global(struct wpa_config *config, char *pos, int line); 1861f05cddf9SRui Paulo 1862780fb4a2SCy Schubert int wpa_config_get_num_global_field_names(void); 1863780fb4a2SCy Schubert 1864780fb4a2SCy Schubert const char * wpa_config_get_global_field_name(unsigned int i, int *no_var); 1865f05cddf9SRui Paulo 186639beb93cSSam Leffler /* Prototypes for backend specific functions from the selected config_*.c */ 186739beb93cSSam Leffler 186839beb93cSSam Leffler /** 186939beb93cSSam Leffler * wpa_config_read - Read and parse configuration database 187039beb93cSSam Leffler * @name: Name of the configuration (e.g., path and file name for the 187139beb93cSSam Leffler * configuration file) 18725b9c547cSRui Paulo * @cfgp: Pointer to previously allocated configuration data or %NULL if none 1873*a90b9d01SCy Schubert * @ro: Whether to mark networks from this configuration as read-only 187439beb93cSSam Leffler * Returns: Pointer to allocated configuration data or %NULL on failure 187539beb93cSSam Leffler * 187639beb93cSSam Leffler * This function reads configuration data, parses its contents, and allocates 187739beb93cSSam Leffler * data structures needed for storing configuration information. The allocated 187839beb93cSSam Leffler * data can be freed with wpa_config_free(). 187939beb93cSSam Leffler * 188039beb93cSSam Leffler * Each configuration backend needs to implement this function. 188139beb93cSSam Leffler */ 1882*a90b9d01SCy Schubert struct wpa_config * wpa_config_read(const char *name, struct wpa_config *cfgp, 1883*a90b9d01SCy Schubert bool ro); 188439beb93cSSam Leffler 188539beb93cSSam Leffler /** 188639beb93cSSam Leffler * wpa_config_write - Write or update configuration data 188739beb93cSSam Leffler * @name: Name of the configuration (e.g., path and file name for the 188839beb93cSSam Leffler * configuration file) 188939beb93cSSam Leffler * @config: Configuration data from wpa_config_read() 189039beb93cSSam Leffler * Returns: 0 on success, -1 on failure 189139beb93cSSam Leffler * 189239beb93cSSam Leffler * This function write all configuration data into an external database (e.g., 189339beb93cSSam Leffler * a text file) in a format that can be read with wpa_config_read(). This can 189439beb93cSSam Leffler * be used to allow wpa_supplicant to update its configuration, e.g., when a 189539beb93cSSam Leffler * new network is added or a password is changed. 189639beb93cSSam Leffler * 189739beb93cSSam Leffler * Each configuration backend needs to implement this function. 189839beb93cSSam Leffler */ 189939beb93cSSam Leffler int wpa_config_write(const char *name, struct wpa_config *config); 190039beb93cSSam Leffler 190139beb93cSSam Leffler #endif /* CONFIG_H */ 1902