xref: /freebsd/contrib/wpa/wpa_supplicant/config_ssid.h (revision a90b9d0159070121c221b966469c3e36d912bf82)
139beb93cSSam Leffler /*
239beb93cSSam Leffler  * WPA Supplicant / Network configuration structures
35b9c547cSRui Paulo  * Copyright (c) 2003-2013, 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_SSID_H
1039beb93cSSam Leffler #define CONFIG_SSID_H
1139beb93cSSam Leffler 
12e28a4053SRui Paulo #include "common/defs.h"
135b9c547cSRui Paulo #include "utils/list.h"
1439beb93cSSam Leffler #include "eap_peer/eap_config.h"
1539beb93cSSam Leffler 
1639beb93cSSam Leffler 
1739beb93cSSam Leffler #define DEFAULT_EAP_WORKAROUND ((unsigned int) -1)
1839beb93cSSam Leffler #define DEFAULT_EAPOL_FLAGS (EAPOL_FLAG_REQUIRE_KEY_UNICAST | \
1939beb93cSSam Leffler 			     EAPOL_FLAG_REQUIRE_KEY_BROADCAST)
2039beb93cSSam Leffler #define DEFAULT_PROTO (WPA_PROTO_WPA | WPA_PROTO_RSN)
2139beb93cSSam Leffler #define DEFAULT_KEY_MGMT (WPA_KEY_MGMT_PSK | WPA_KEY_MGMT_IEEE8021X)
22c1d255d3SCy Schubert #ifdef CONFIG_NO_TKIP
23c1d255d3SCy Schubert #define DEFAULT_PAIRWISE (WPA_CIPHER_CCMP)
24c1d255d3SCy Schubert #define DEFAULT_GROUP (WPA_CIPHER_CCMP)
25c1d255d3SCy Schubert #else /* CONFIG_NO_TKIP */
2639beb93cSSam Leffler #define DEFAULT_PAIRWISE (WPA_CIPHER_CCMP | WPA_CIPHER_TKIP)
27325151a3SRui Paulo #define DEFAULT_GROUP (WPA_CIPHER_CCMP | WPA_CIPHER_TKIP)
28c1d255d3SCy Schubert #endif /* CONFIG_NO_TKIP */
2939beb93cSSam Leffler #define DEFAULT_FRAGMENT_SIZE 1398
3039beb93cSSam Leffler 
31f05cddf9SRui Paulo #define DEFAULT_BG_SCAN_PERIOD -1
325b9c547cSRui Paulo #define DEFAULT_MESH_MAX_RETRIES 2
335b9c547cSRui Paulo #define DEFAULT_MESH_RETRY_TIMEOUT 40
345b9c547cSRui Paulo #define DEFAULT_MESH_CONFIRM_TIMEOUT 40
355b9c547cSRui Paulo #define DEFAULT_MESH_HOLDING_TIMEOUT 40
3685732ac8SCy Schubert #define DEFAULT_MESH_RSSI_THRESHOLD 1 /* no change */
37f05cddf9SRui Paulo #define DEFAULT_DISABLE_HT 0
38f05cddf9SRui Paulo #define DEFAULT_DISABLE_HT40 0
39f05cddf9SRui Paulo #define DEFAULT_DISABLE_SGI 0
405b9c547cSRui Paulo #define DEFAULT_DISABLE_LDPC 0
414bc52338SCy Schubert #define DEFAULT_TX_STBC -1 /* no change */
424bc52338SCy Schubert #define DEFAULT_RX_STBC -1 /* no change */
43f05cddf9SRui Paulo #define DEFAULT_DISABLE_MAX_AMSDU -1 /* no change */
44f05cddf9SRui Paulo #define DEFAULT_AMPDU_FACTOR -1 /* no change */
45f05cddf9SRui Paulo #define DEFAULT_AMPDU_DENSITY -1 /* no change */
465b9c547cSRui Paulo #define DEFAULT_USER_SELECTED_SIM 1
474bc52338SCy Schubert #define DEFAULT_MAX_OPER_CHWIDTH -1
485b9c547cSRui Paulo 
494b72b91aSCy Schubert /* Consider global sae_pwe for SAE mechanism for PWE derivation */
50*a90b9d01SCy Schubert #define DEFAULT_SAE_PWE SAE_PWE_NOT_SET
514b72b91aSCy Schubert 
525b9c547cSRui Paulo struct psk_list_entry {
535b9c547cSRui Paulo 	struct dl_list list;
545b9c547cSRui Paulo 	u8 addr[ETH_ALEN];
555b9c547cSRui Paulo 	u8 psk[32];
565b9c547cSRui Paulo 	u8 p2p;
575b9c547cSRui Paulo };
58f05cddf9SRui Paulo 
59206b73d0SCy Schubert enum wpas_mode {
60206b73d0SCy Schubert 	WPAS_MODE_INFRA = 0,
61206b73d0SCy Schubert 	WPAS_MODE_IBSS = 1,
62206b73d0SCy Schubert 	WPAS_MODE_AP = 2,
63206b73d0SCy Schubert 	WPAS_MODE_P2P_GO = 3,
64206b73d0SCy Schubert 	WPAS_MODE_P2P_GROUP_FORMATION = 4,
65206b73d0SCy Schubert 	WPAS_MODE_MESH = 5,
66206b73d0SCy Schubert };
67206b73d0SCy Schubert 
68c1d255d3SCy Schubert enum sae_pk_mode {
69c1d255d3SCy Schubert 	SAE_PK_MODE_AUTOMATIC = 0,
70c1d255d3SCy Schubert 	SAE_PK_MODE_ONLY = 1,
71c1d255d3SCy Schubert 	SAE_PK_MODE_DISABLED = 2,
72c1d255d3SCy Schubert };
73c1d255d3SCy Schubert 
74*a90b9d01SCy Schubert enum wpas_mac_addr_style {
75*a90b9d01SCy Schubert 	WPAS_MAC_ADDR_STYLE_NOT_SET = -1,
76*a90b9d01SCy Schubert 	WPAS_MAC_ADDR_STYLE_PERMANENT = 0,
77*a90b9d01SCy Schubert 	WPAS_MAC_ADDR_STYLE_RANDOM = 1,
78*a90b9d01SCy Schubert 	WPAS_MAC_ADDR_STYLE_RANDOM_SAME_OUI = 2,
79*a90b9d01SCy Schubert 	WPAS_MAC_ADDR_STYLE_DEDICATED_PER_ESS = 3,
80*a90b9d01SCy Schubert };
81*a90b9d01SCy Schubert 
8239beb93cSSam Leffler /**
8339beb93cSSam Leffler  * struct wpa_ssid - Network configuration data
8439beb93cSSam Leffler  *
8539beb93cSSam Leffler  * This structure includes all the configuration variables for a network. This
8639beb93cSSam Leffler  * data is included in the per-interface configuration data as an element of
8739beb93cSSam Leffler  * the network list, struct wpa_config::ssid. Each network block in the
8839beb93cSSam Leffler  * configuration is mapped to a struct wpa_ssid instance.
8939beb93cSSam Leffler  */
9039beb93cSSam Leffler struct wpa_ssid {
9139beb93cSSam Leffler 	/**
9239beb93cSSam Leffler 	 * next - Next network in global list
9339beb93cSSam Leffler 	 *
9439beb93cSSam Leffler 	 * This pointer can be used to iterate over all networks. The head of
9539beb93cSSam Leffler 	 * this list is stored in the ssid field of struct wpa_config.
9639beb93cSSam Leffler 	 */
9739beb93cSSam Leffler 	struct wpa_ssid *next;
9839beb93cSSam Leffler 
9939beb93cSSam Leffler 	/**
10039beb93cSSam Leffler 	 * pnext - Next network in per-priority list
10139beb93cSSam Leffler 	 *
10239beb93cSSam Leffler 	 * This pointer can be used to iterate over all networks in the same
10339beb93cSSam Leffler 	 * priority class. The heads of these list are stored in the pssid
10439beb93cSSam Leffler 	 * fields of struct wpa_config.
10539beb93cSSam Leffler 	 */
10639beb93cSSam Leffler 	struct wpa_ssid *pnext;
10739beb93cSSam Leffler 
10839beb93cSSam Leffler 	/**
10939beb93cSSam Leffler 	 * id - Unique id for the network
11039beb93cSSam Leffler 	 *
11139beb93cSSam Leffler 	 * This identifier is used as a unique identifier for each network
11239beb93cSSam Leffler 	 * block when using the control interface. Each network is allocated an
11339beb93cSSam Leffler 	 * id when it is being created, either when reading the configuration
11439beb93cSSam Leffler 	 * file or when a new network is added through the control interface.
11539beb93cSSam Leffler 	 */
11639beb93cSSam Leffler 	int id;
11739beb93cSSam Leffler 
11839beb93cSSam Leffler 	/**
119*a90b9d01SCy Schubert 	 * ro - Whether a network is declared as read-only
120*a90b9d01SCy Schubert 	 *
121*a90b9d01SCy Schubert 	 * Every network which is defined in a config file that is passed to
122*a90b9d01SCy Schubert 	 * wpa_supplicant using the -I option will be marked as read-only
123*a90b9d01SCy Schubert 	 * using this flag. It has the effect that it won't be written to
124*a90b9d01SCy Schubert 	 * /etc/wpa_supplicant.conf (from -c argument) if, e.g., wpa_gui tells
125*a90b9d01SCy Schubert 	 * the daemon to save all changed configs.
126*a90b9d01SCy Schubert 	 *
127*a90b9d01SCy Schubert 	 * This is necessary because networks from /etc/wpa_supplicant.conf
128*a90b9d01SCy Schubert 	 * have a higher priority and changes from an alternative file would be
129*a90b9d01SCy Schubert 	 * silently overwritten without this.
130*a90b9d01SCy Schubert 	 */
131*a90b9d01SCy Schubert 	bool ro;
132*a90b9d01SCy Schubert 
133*a90b9d01SCy Schubert 	/**
13439beb93cSSam Leffler 	 * priority - Priority group
13539beb93cSSam Leffler 	 *
13639beb93cSSam Leffler 	 * By default, all networks will get same priority group (0). If some
13739beb93cSSam Leffler 	 * of the networks are more desirable, this field can be used to change
13839beb93cSSam Leffler 	 * the order in which wpa_supplicant goes through the networks when
13939beb93cSSam Leffler 	 * selecting a BSS. The priority groups will be iterated in decreasing
14039beb93cSSam Leffler 	 * priority (i.e., the larger the priority value, the sooner the
14139beb93cSSam Leffler 	 * network is matched against the scan results). Within each priority
14239beb93cSSam Leffler 	 * group, networks will be selected based on security policy, signal
14339beb93cSSam Leffler 	 * strength, etc.
14439beb93cSSam Leffler 	 *
14539beb93cSSam Leffler 	 * Please note that AP scanning with scan_ssid=1 and ap_scan=2 mode are
14639beb93cSSam Leffler 	 * not using this priority to select the order for scanning. Instead,
14739beb93cSSam Leffler 	 * they try the networks in the order that used in the configuration
14839beb93cSSam Leffler 	 * file.
14939beb93cSSam Leffler 	 */
15039beb93cSSam Leffler 	int priority;
15139beb93cSSam Leffler 
15239beb93cSSam Leffler 	/**
15339beb93cSSam Leffler 	 * ssid - Service set identifier (network name)
15439beb93cSSam Leffler 	 *
15539beb93cSSam Leffler 	 * This is the SSID for the network. For wireless interfaces, this is
15639beb93cSSam Leffler 	 * used to select which network will be used. If set to %NULL (or
15739beb93cSSam Leffler 	 * ssid_len=0), any SSID can be used. For wired interfaces, this must
15839beb93cSSam Leffler 	 * be set to %NULL. Note: SSID may contain any characters, even nul
15939beb93cSSam Leffler 	 * (ASCII 0) and as such, this should not be assumed to be a nul
16039beb93cSSam Leffler 	 * terminated string. ssid_len defines how many characters are valid
16139beb93cSSam Leffler 	 * and the ssid field is not guaranteed to be nul terminated.
16239beb93cSSam Leffler 	 */
16339beb93cSSam Leffler 	u8 *ssid;
16439beb93cSSam Leffler 
16539beb93cSSam Leffler 	/**
16639beb93cSSam Leffler 	 * ssid_len - Length of the SSID
16739beb93cSSam Leffler 	 */
16839beb93cSSam Leffler 	size_t ssid_len;
16939beb93cSSam Leffler 
17039beb93cSSam Leffler 	/**
17139beb93cSSam Leffler 	 * bssid - BSSID
17239beb93cSSam Leffler 	 *
17339beb93cSSam Leffler 	 * If set, this network block is used only when associating with the AP
17439beb93cSSam Leffler 	 * using the configured BSSID
175f05cddf9SRui Paulo 	 *
176f05cddf9SRui Paulo 	 * If this is a persistent P2P group (disabled == 2), this is the GO
177f05cddf9SRui Paulo 	 * Device Address.
17839beb93cSSam Leffler 	 */
17939beb93cSSam Leffler 	u8 bssid[ETH_ALEN];
18039beb93cSSam Leffler 
18139beb93cSSam Leffler 	/**
182c1d255d3SCy Schubert 	 * bssid_ignore - List of inacceptable BSSIDs
1835b9c547cSRui Paulo 	 */
184c1d255d3SCy Schubert 	u8 *bssid_ignore;
185c1d255d3SCy Schubert 	size_t num_bssid_ignore;
1865b9c547cSRui Paulo 
1875b9c547cSRui Paulo 	/**
188c1d255d3SCy Schubert 	 * bssid_accept - List of acceptable BSSIDs
1895b9c547cSRui Paulo 	 */
190c1d255d3SCy Schubert 	u8 *bssid_accept;
191c1d255d3SCy Schubert 	size_t num_bssid_accept;
1925b9c547cSRui Paulo 
1935b9c547cSRui Paulo 	/**
19439beb93cSSam Leffler 	 * bssid_set - Whether BSSID is configured for this network
19539beb93cSSam Leffler 	 */
19639beb93cSSam Leffler 	int bssid_set;
19739beb93cSSam Leffler 
19839beb93cSSam Leffler 	/**
19985732ac8SCy Schubert 	 * bssid_hint - BSSID hint
20085732ac8SCy Schubert 	 *
20185732ac8SCy Schubert 	 * If set, this is configured to the driver as a preferred initial BSSID
20285732ac8SCy Schubert 	 * while connecting to this network.
20385732ac8SCy Schubert 	 */
20485732ac8SCy Schubert 	u8 bssid_hint[ETH_ALEN];
20585732ac8SCy Schubert 
20685732ac8SCy Schubert 	/**
20785732ac8SCy Schubert 	 * bssid_hint_set - Whether BSSID hint is configured for this network
20885732ac8SCy Schubert 	 */
20985732ac8SCy Schubert 	int bssid_hint_set;
21085732ac8SCy Schubert 
21185732ac8SCy Schubert 	/**
2125b9c547cSRui Paulo 	 * go_p2p_dev_addr - GO's P2P Device Address or all zeros if not set
2135b9c547cSRui Paulo 	 */
2145b9c547cSRui Paulo 	u8 go_p2p_dev_addr[ETH_ALEN];
2155b9c547cSRui Paulo 
2165b9c547cSRui Paulo 	/**
21739beb93cSSam Leffler 	 * psk - WPA pre-shared key (256 bits)
21839beb93cSSam Leffler 	 */
21939beb93cSSam Leffler 	u8 psk[32];
22039beb93cSSam Leffler 
22139beb93cSSam Leffler 	/**
22239beb93cSSam Leffler 	 * psk_set - Whether PSK field is configured
22339beb93cSSam Leffler 	 */
22439beb93cSSam Leffler 	int psk_set;
22539beb93cSSam Leffler 
22639beb93cSSam Leffler 	/**
22739beb93cSSam Leffler 	 * passphrase - WPA ASCII passphrase
22839beb93cSSam Leffler 	 *
22939beb93cSSam Leffler 	 * If this is set, psk will be generated using the SSID and passphrase
23039beb93cSSam Leffler 	 * configured for the network. ASCII passphrase must be between 8 and
23139beb93cSSam Leffler 	 * 63 characters (inclusive).
23239beb93cSSam Leffler 	 */
23339beb93cSSam Leffler 	char *passphrase;
23439beb93cSSam Leffler 
23539beb93cSSam Leffler 	/**
23685732ac8SCy Schubert 	 * sae_password - SAE password
23785732ac8SCy Schubert 	 *
23885732ac8SCy Schubert 	 * This parameter can be used to set a password for SAE. By default, the
23985732ac8SCy Schubert 	 * passphrase value is used if this separate parameter is not used, but
24085732ac8SCy Schubert 	 * passphrase follows the WPA-PSK constraints (8..63 characters) even
24185732ac8SCy Schubert 	 * though SAE passwords do not have such constraints.
24285732ac8SCy Schubert 	 */
24385732ac8SCy Schubert 	char *sae_password;
24485732ac8SCy Schubert 
24585732ac8SCy Schubert 	/**
24685732ac8SCy Schubert 	 * sae_password_id - SAE password identifier
24785732ac8SCy Schubert 	 *
24885732ac8SCy Schubert 	 * This parameter can be used to identify a specific SAE password. If
24985732ac8SCy Schubert 	 * not included, the default SAE password is used instead.
25085732ac8SCy Schubert 	 */
25185732ac8SCy Schubert 	char *sae_password_id;
25285732ac8SCy Schubert 
253c1d255d3SCy Schubert 	struct sae_pt *pt;
254c1d255d3SCy Schubert 
25585732ac8SCy Schubert 	/**
256f05cddf9SRui Paulo 	 * ext_psk - PSK/passphrase name in external storage
257f05cddf9SRui Paulo 	 *
258f05cddf9SRui Paulo 	 * If this is set, PSK/passphrase will be fetched from external storage
259f05cddf9SRui Paulo 	 * when requesting association with the network.
260f05cddf9SRui Paulo 	 */
261f05cddf9SRui Paulo 	char *ext_psk;
262f05cddf9SRui Paulo 
263f05cddf9SRui Paulo 	/**
264325151a3SRui Paulo 	 * mem_only_psk - Whether to keep PSK/passphrase only in memory
265325151a3SRui Paulo 	 *
266325151a3SRui Paulo 	 * 0 = allow psk/passphrase to be stored to the configuration file
267325151a3SRui Paulo 	 * 1 = do not store psk/passphrase to the configuration file
268325151a3SRui Paulo 	 */
269325151a3SRui Paulo 	int mem_only_psk;
270325151a3SRui Paulo 
271325151a3SRui Paulo 	/**
27239beb93cSSam Leffler 	 * pairwise_cipher - Bitfield of allowed pairwise ciphers, WPA_CIPHER_*
27339beb93cSSam Leffler 	 */
27439beb93cSSam Leffler 	int pairwise_cipher;
27539beb93cSSam Leffler 
27639beb93cSSam Leffler 	/**
27739beb93cSSam Leffler 	 * group_cipher - Bitfield of allowed group ciphers, WPA_CIPHER_*
27839beb93cSSam Leffler 	 */
27939beb93cSSam Leffler 	int group_cipher;
28039beb93cSSam Leffler 
28139beb93cSSam Leffler 	/**
28285732ac8SCy Schubert 	 * group_mgmt_cipher - Bitfield of allowed group management ciphers
28385732ac8SCy Schubert 	 *
28485732ac8SCy Schubert 	 * This is a bitfield of WPA_CIPHER_AES_128_CMAC and WPA_CIPHER_BIP_*
28585732ac8SCy Schubert 	 * values. If 0, no constraint is used for the cipher, i.e., whatever
28685732ac8SCy Schubert 	 * the AP uses is accepted.
28785732ac8SCy Schubert 	 */
28885732ac8SCy Schubert 	int group_mgmt_cipher;
28985732ac8SCy Schubert 
29085732ac8SCy Schubert 	/**
29139beb93cSSam Leffler 	 * key_mgmt - Bitfield of allowed key management protocols
29239beb93cSSam Leffler 	 *
29339beb93cSSam Leffler 	 * WPA_KEY_MGMT_*
29439beb93cSSam Leffler 	 */
29539beb93cSSam Leffler 	int key_mgmt;
29639beb93cSSam Leffler 
29739beb93cSSam Leffler 	/**
298f05cddf9SRui Paulo 	 * bg_scan_period - Background scan period in seconds, 0 to disable, or
299f05cddf9SRui Paulo 	 * -1 to indicate no change to default driver configuration
300f05cddf9SRui Paulo 	 */
301f05cddf9SRui Paulo 	int bg_scan_period;
302f05cddf9SRui Paulo 
303f05cddf9SRui Paulo 	/**
30439beb93cSSam Leffler 	 * proto - Bitfield of allowed protocols, WPA_PROTO_*
30539beb93cSSam Leffler 	 */
30639beb93cSSam Leffler 	int proto;
30739beb93cSSam Leffler 
30839beb93cSSam Leffler 	/**
30939beb93cSSam Leffler 	 * auth_alg -  Bitfield of allowed authentication algorithms
31039beb93cSSam Leffler 	 *
31139beb93cSSam Leffler 	 * WPA_AUTH_ALG_*
31239beb93cSSam Leffler 	 */
31339beb93cSSam Leffler 	int auth_alg;
31439beb93cSSam Leffler 
31539beb93cSSam Leffler 	/**
31639beb93cSSam Leffler 	 * scan_ssid - Scan this SSID with Probe Requests
31739beb93cSSam Leffler 	 *
31839beb93cSSam Leffler 	 * scan_ssid can be used to scan for APs using hidden SSIDs.
31939beb93cSSam Leffler 	 * Note: Many drivers do not support this. ap_mode=2 can be used with
320325151a3SRui Paulo 	 * such drivers to use hidden SSIDs. Note2: Most nl80211-based drivers
321325151a3SRui Paulo 	 * do support scan_ssid=1 and that should be used with them instead of
322325151a3SRui Paulo 	 * ap_scan=2.
32339beb93cSSam Leffler 	 */
32439beb93cSSam Leffler 	int scan_ssid;
32539beb93cSSam Leffler 
32639beb93cSSam Leffler #ifdef IEEE8021X_EAPOL
32739beb93cSSam Leffler #define EAPOL_FLAG_REQUIRE_KEY_UNICAST BIT(0)
32839beb93cSSam Leffler #define EAPOL_FLAG_REQUIRE_KEY_BROADCAST BIT(1)
32939beb93cSSam Leffler 	/**
33039beb93cSSam Leffler 	 * eapol_flags - Bit field of IEEE 802.1X/EAPOL options (EAPOL_FLAG_*)
33139beb93cSSam Leffler 	 */
33239beb93cSSam Leffler 	int eapol_flags;
33339beb93cSSam Leffler 
33439beb93cSSam Leffler 	/**
33539beb93cSSam Leffler 	 * eap - EAP peer configuration for this network
33639beb93cSSam Leffler 	 */
33739beb93cSSam Leffler 	struct eap_peer_config eap;
33839beb93cSSam Leffler #endif /* IEEE8021X_EAPOL */
33939beb93cSSam Leffler 
340c1d255d3SCy Schubert #ifdef CONFIG_WEP
34139beb93cSSam Leffler #define NUM_WEP_KEYS 4
34239beb93cSSam Leffler #define MAX_WEP_KEY_LEN 16
34339beb93cSSam Leffler 	/**
34439beb93cSSam Leffler 	 * wep_key - WEP keys
34539beb93cSSam Leffler 	 */
34639beb93cSSam Leffler 	u8 wep_key[NUM_WEP_KEYS][MAX_WEP_KEY_LEN];
34739beb93cSSam Leffler 
34839beb93cSSam Leffler 	/**
34939beb93cSSam Leffler 	 * wep_key_len - WEP key lengths
35039beb93cSSam Leffler 	 */
35139beb93cSSam Leffler 	size_t wep_key_len[NUM_WEP_KEYS];
35239beb93cSSam Leffler 
35339beb93cSSam Leffler 	/**
35439beb93cSSam Leffler 	 * wep_tx_keyidx - Default key index for TX frames using WEP
35539beb93cSSam Leffler 	 */
35639beb93cSSam Leffler 	int wep_tx_keyidx;
357c1d255d3SCy Schubert #endif /* CONFIG_WEP */
35839beb93cSSam Leffler 
35939beb93cSSam Leffler 	/**
36039beb93cSSam Leffler 	 * proactive_key_caching - Enable proactive key caching
36139beb93cSSam Leffler 	 *
36239beb93cSSam Leffler 	 * This field can be used to enable proactive key caching which is also
36339beb93cSSam Leffler 	 * known as opportunistic PMKSA caching for WPA2. This is disabled (0)
364f05cddf9SRui Paulo 	 * by default unless default value is changed with the global okc=1
365f05cddf9SRui Paulo 	 * parameter. Enable by setting this to 1.
36639beb93cSSam Leffler 	 *
36739beb93cSSam Leffler 	 * Proactive key caching is used to make supplicant assume that the APs
36839beb93cSSam Leffler 	 * are using the same PMK and generate PMKSA cache entries without
36939beb93cSSam Leffler 	 * doing RSN pre-authentication. This requires support from the AP side
37039beb93cSSam Leffler 	 * and is normally used with wireless switches that co-locate the
37139beb93cSSam Leffler 	 * authenticator.
372f05cddf9SRui Paulo 	 *
373f05cddf9SRui Paulo 	 * Internally, special value -1 is used to indicate that the parameter
374f05cddf9SRui Paulo 	 * was not specified in the configuration (i.e., default behavior is
375f05cddf9SRui Paulo 	 * followed).
37639beb93cSSam Leffler 	 */
37739beb93cSSam Leffler 	int proactive_key_caching;
37839beb93cSSam Leffler 
37939beb93cSSam Leffler 	/**
38039beb93cSSam Leffler 	 * mixed_cell - Whether mixed cells are allowed
38139beb93cSSam Leffler 	 *
38239beb93cSSam Leffler 	 * This option can be used to configure whether so called mixed cells,
38339beb93cSSam Leffler 	 * i.e., networks that use both plaintext and encryption in the same
38439beb93cSSam Leffler 	 * SSID, are allowed. This is disabled (0) by default. Enable by
38539beb93cSSam Leffler 	 * setting this to 1.
38639beb93cSSam Leffler 	 */
38739beb93cSSam Leffler 	int mixed_cell;
38839beb93cSSam Leffler 
38939beb93cSSam Leffler #ifdef IEEE8021X_EAPOL
39039beb93cSSam Leffler 
39139beb93cSSam Leffler 	/**
39239beb93cSSam Leffler 	 * leap - Number of EAP methods using LEAP
39339beb93cSSam Leffler 	 *
39439beb93cSSam Leffler 	 * This field should be set to 1 if LEAP is enabled. This is used to
39539beb93cSSam Leffler 	 * select IEEE 802.11 authentication algorithm.
39639beb93cSSam Leffler 	 */
39739beb93cSSam Leffler 	int leap;
39839beb93cSSam Leffler 
39939beb93cSSam Leffler 	/**
40039beb93cSSam Leffler 	 * non_leap - Number of EAP methods not using LEAP
40139beb93cSSam Leffler 	 *
40239beb93cSSam Leffler 	 * This field should be set to >0 if any EAP method other than LEAP is
40339beb93cSSam Leffler 	 * enabled. This is used to select IEEE 802.11 authentication
40439beb93cSSam Leffler 	 * algorithm.
40539beb93cSSam Leffler 	 */
40639beb93cSSam Leffler 	int non_leap;
40739beb93cSSam Leffler 
40839beb93cSSam Leffler 	/**
40939beb93cSSam Leffler 	 * eap_workaround - EAP workarounds enabled
41039beb93cSSam Leffler 	 *
41139beb93cSSam Leffler 	 * wpa_supplicant supports number of "EAP workarounds" to work around
41239beb93cSSam Leffler 	 * interoperability issues with incorrectly behaving authentication
41339beb93cSSam Leffler 	 * servers. This is recommended to be enabled by default because some
41439beb93cSSam Leffler 	 * of the issues are present in large number of authentication servers.
41539beb93cSSam Leffler 	 *
41639beb93cSSam Leffler 	 * Strict EAP conformance mode can be configured by disabling
41739beb93cSSam Leffler 	 * workarounds with eap_workaround = 0.
41839beb93cSSam Leffler 	 */
41939beb93cSSam Leffler 	unsigned int eap_workaround;
42039beb93cSSam Leffler 
42139beb93cSSam Leffler #endif /* IEEE8021X_EAPOL */
42239beb93cSSam Leffler 
42339beb93cSSam Leffler 	/**
42439beb93cSSam Leffler 	 * mode - IEEE 802.11 operation mode (Infrastucture/IBSS)
42539beb93cSSam Leffler 	 *
42639beb93cSSam Leffler 	 * 0 = infrastructure (Managed) mode, i.e., associate with an AP.
42739beb93cSSam Leffler 	 *
42839beb93cSSam Leffler 	 * 1 = IBSS (ad-hoc, peer-to-peer)
42939beb93cSSam Leffler 	 *
430e28a4053SRui Paulo 	 * 2 = AP (access point)
431e28a4053SRui Paulo 	 *
432f05cddf9SRui Paulo 	 * 3 = P2P Group Owner (can be set in the configuration file)
433f05cddf9SRui Paulo 	 *
434f05cddf9SRui Paulo 	 * 4 = P2P Group Formation (used internally; not in configuration
435f05cddf9SRui Paulo 	 * files)
436f05cddf9SRui Paulo 	 *
4375b9c547cSRui Paulo 	 * 5 = Mesh
4385b9c547cSRui Paulo 	 *
4395b9c547cSRui Paulo 	 * Note: IBSS can only be used with key_mgmt NONE (plaintext and static
4405b9c547cSRui Paulo 	 * WEP) and WPA-PSK (with proto=RSN). In addition, key_mgmt=WPA-NONE
4415b9c547cSRui Paulo 	 * (fixed group key TKIP/CCMP) is available for backwards compatibility,
4425b9c547cSRui Paulo 	 * but its use is deprecated. WPA-None requires following network block
4435b9c547cSRui Paulo 	 * options: proto=WPA, key_mgmt=WPA-NONE, pairwise=NONE, group=TKIP (or
4445b9c547cSRui Paulo 	 * CCMP, but not both), and psk must also be set (either directly or
4455b9c547cSRui Paulo 	 * using ASCII passphrase).
44639beb93cSSam Leffler 	 */
447206b73d0SCy Schubert 	enum wpas_mode mode;
44839beb93cSSam Leffler 
44939beb93cSSam Leffler 	/**
450780fb4a2SCy Schubert 	 * pbss - Whether to use PBSS. Relevant to DMG networks only.
451780fb4a2SCy Schubert 	 * 0 = do not use PBSS
452780fb4a2SCy Schubert 	 * 1 = use PBSS
453780fb4a2SCy Schubert 	 * 2 = don't care (not allowed in AP mode)
454780fb4a2SCy Schubert 	 * Used together with mode configuration. When mode is AP, it
455780fb4a2SCy Schubert 	 * means to start a PCP instead of a regular AP. When mode is INFRA it
456780fb4a2SCy Schubert 	 * means connect to a PCP instead of AP. In this mode you can also
457780fb4a2SCy Schubert 	 * specify 2 (don't care) meaning connect to either AP or PCP.
458780fb4a2SCy Schubert 	 * P2P_GO and P2P_GROUP_FORMATION modes must use PBSS in DMG network.
459780fb4a2SCy Schubert 	 */
460780fb4a2SCy Schubert 	int pbss;
461780fb4a2SCy Schubert 
462780fb4a2SCy Schubert 	/**
46339beb93cSSam Leffler 	 * disabled - Whether this network is currently disabled
46439beb93cSSam Leffler 	 *
46539beb93cSSam Leffler 	 * 0 = this network can be used (default).
46639beb93cSSam Leffler 	 * 1 = this network block is disabled (can be enabled through
46739beb93cSSam Leffler 	 * ctrl_iface, e.g., with wpa_cli or wpa_gui).
468f05cddf9SRui Paulo 	 * 2 = this network block includes parameters for a persistent P2P
469f05cddf9SRui Paulo 	 * group (can be used with P2P ctrl_iface commands)
47039beb93cSSam Leffler 	 */
47139beb93cSSam Leffler 	int disabled;
47239beb93cSSam Leffler 
47339beb93cSSam Leffler 	/**
474f05cddf9SRui Paulo 	 * disabled_for_connect - Whether this network was temporarily disabled
475f05cddf9SRui Paulo 	 *
476f05cddf9SRui Paulo 	 * This flag is used to reenable all the temporarily disabled networks
477f05cddf9SRui Paulo 	 * after either the success or failure of a WPS connection.
478f05cddf9SRui Paulo 	 */
479f05cddf9SRui Paulo 	int disabled_for_connect;
480f05cddf9SRui Paulo 
481f05cddf9SRui Paulo 	/**
48239beb93cSSam Leffler 	 * id_str - Network identifier string for external scripts
48339beb93cSSam Leffler 	 *
48439beb93cSSam Leffler 	 * This value is passed to external ctrl_iface monitors in
48539beb93cSSam Leffler 	 * WPA_EVENT_CONNECTED event and wpa_cli sets this as WPA_ID_STR
48639beb93cSSam Leffler 	 * environment variable for action scripts.
48739beb93cSSam Leffler 	 */
48839beb93cSSam Leffler 	char *id_str;
48939beb93cSSam Leffler 
49039beb93cSSam Leffler 	/**
49139beb93cSSam Leffler 	 * ieee80211w - Whether management frame protection is enabled
49239beb93cSSam Leffler 	 *
49339beb93cSSam Leffler 	 * This value is used to configure policy for management frame
49439beb93cSSam Leffler 	 * protection (IEEE 802.11w). 0 = disabled, 1 = optional, 2 = required.
495f05cddf9SRui Paulo 	 * This is disabled by default unless the default value has been changed
496f05cddf9SRui Paulo 	 * with the global pmf=1/2 parameter.
497f05cddf9SRui Paulo 	 *
498f05cddf9SRui Paulo 	 * Internally, special value 3 is used to indicate that the parameter
499f05cddf9SRui Paulo 	 * was not specified in the configuration (i.e., default behavior is
500f05cddf9SRui Paulo 	 * followed).
50139beb93cSSam Leffler 	 */
502e28a4053SRui Paulo 	enum mfp_options ieee80211w;
50339beb93cSSam Leffler 
5044bc52338SCy Schubert #ifdef CONFIG_OCV
5054bc52338SCy Schubert 	/**
5064bc52338SCy Schubert 	 * ocv - Enable/disable operating channel validation
5074bc52338SCy Schubert 	 *
5084bc52338SCy Schubert 	 * If this parameter is set to 1, stations will exchange OCI element
5094bc52338SCy Schubert 	 * to cryptographically verify the operating channel. Setting this
5104bc52338SCy Schubert 	 * parameter to 0 disables this option. Default value: 0.
5114bc52338SCy Schubert 	 */
5124bc52338SCy Schubert 	int ocv;
5134bc52338SCy Schubert #endif /* CONFIG_OCV */
5144bc52338SCy Schubert 
51539beb93cSSam Leffler 	/**
51639beb93cSSam Leffler 	 * frequency - Channel frequency in megahertz (MHz) for IBSS
51739beb93cSSam Leffler 	 *
51839beb93cSSam Leffler 	 * This value is used to configure the initial channel for IBSS (adhoc)
51939beb93cSSam Leffler 	 * networks, e.g., 2412 = IEEE 802.11b/g channel 1. It is ignored in
52039beb93cSSam Leffler 	 * the infrastructure mode. In addition, this value is only used by the
52139beb93cSSam Leffler 	 * station that creates the IBSS. If an IBSS network with the
52239beb93cSSam Leffler 	 * configured SSID is already present, the frequency of the network
52339beb93cSSam Leffler 	 * will be used instead of this configured value.
52439beb93cSSam Leffler 	 */
52539beb93cSSam Leffler 	int frequency;
52639beb93cSSam Leffler 
5275b9c547cSRui Paulo 	/**
528c1d255d3SCy Schubert 	 * enable_edmg - Enable EDMG feature in STA/AP mode
529c1d255d3SCy Schubert 	 *
530c1d255d3SCy Schubert 	 * This flag is used for enabling the EDMG capability in STA/AP mode.
531c1d255d3SCy Schubert 	 */
532c1d255d3SCy Schubert 	int enable_edmg;
533c1d255d3SCy Schubert 
534c1d255d3SCy Schubert 	/**
535c1d255d3SCy Schubert 	 * edmg_channel - EDMG channel number
536c1d255d3SCy Schubert 	 *
537c1d255d3SCy Schubert 	 * This value is used to configure the EDMG channel bonding feature.
538c1d255d3SCy Schubert 	 * In AP mode it defines the EDMG channel to start the AP on.
539c1d255d3SCy Schubert 	 * in STA mode it defines the EDMG channel to use for connection
540c1d255d3SCy Schubert 	 * (if supported by AP).
541c1d255d3SCy Schubert 	 */
542c1d255d3SCy Schubert 	u8 edmg_channel;
543c1d255d3SCy Schubert 
544c1d255d3SCy Schubert 	/**
5455b9c547cSRui Paulo 	 * fixed_freq - Use fixed frequency for IBSS
5465b9c547cSRui Paulo 	 */
5475b9c547cSRui Paulo 	int fixed_freq;
5485b9c547cSRui Paulo 
549780fb4a2SCy Schubert #ifdef CONFIG_ACS
550780fb4a2SCy Schubert 	/**
551780fb4a2SCy Schubert 	 * ACS - Automatic Channel Selection for AP mode
552780fb4a2SCy Schubert 	 *
553780fb4a2SCy Schubert 	 * If present, it will be handled together with frequency.
554780fb4a2SCy Schubert 	 * frequency will be used to determine hardware mode only, when it is
555780fb4a2SCy Schubert 	 * used for both hardware mode and channel when used alone. This will
556780fb4a2SCy Schubert 	 * force the channel to be set to 0, thus enabling ACS.
557780fb4a2SCy Schubert 	 */
558780fb4a2SCy Schubert 	int acs;
559780fb4a2SCy Schubert #endif /* CONFIG_ACS */
560780fb4a2SCy Schubert 
5615b9c547cSRui Paulo 	/**
5625b9c547cSRui Paulo 	 * mesh_basic_rates - BSS Basic rate set for mesh network
5635b9c547cSRui Paulo 	 *
5645b9c547cSRui Paulo 	 */
5655b9c547cSRui Paulo 	int *mesh_basic_rates;
5665b9c547cSRui Paulo 
5675b9c547cSRui Paulo 	/**
5685b9c547cSRui Paulo 	 * Mesh network plink parameters
5695b9c547cSRui Paulo 	 */
5705b9c547cSRui Paulo 	int dot11MeshMaxRetries;
5715b9c547cSRui Paulo 	int dot11MeshRetryTimeout; /* msec */
5725b9c547cSRui Paulo 	int dot11MeshConfirmTimeout; /* msec */
5735b9c547cSRui Paulo 	int dot11MeshHoldingTimeout; /* msec */
5745b9c547cSRui Paulo 
57532a95656SCy Schubert 	/**
57632a95656SCy Schubert 	 * Mesh network layer-2 forwarding (dot11MeshForwarding)
57732a95656SCy Schubert 	 */
57832a95656SCy Schubert 	int mesh_fwding;
57932a95656SCy Schubert 
58085732ac8SCy Schubert 	int ht;
581f05cddf9SRui Paulo 	int ht40;
582f05cddf9SRui Paulo 
5835b9c547cSRui Paulo 	int vht;
5845b9c547cSRui Paulo 
5854bc52338SCy Schubert 	int he;
5864bc52338SCy Schubert 
587*a90b9d01SCy Schubert 	int eht;
588*a90b9d01SCy Schubert 
589*a90b9d01SCy Schubert 	enum oper_chan_width max_oper_chwidth;
590780fb4a2SCy Schubert 
59185732ac8SCy Schubert 	unsigned int vht_center_freq1;
592780fb4a2SCy Schubert 	unsigned int vht_center_freq2;
593780fb4a2SCy Schubert 
59439beb93cSSam Leffler 	/**
59539beb93cSSam Leffler 	 * wpa_ptk_rekey - Maximum lifetime for PTK in seconds
59639beb93cSSam Leffler 	 *
59739beb93cSSam Leffler 	 * This value can be used to enforce rekeying of PTK to mitigate some
59839beb93cSSam Leffler 	 * attacks against TKIP deficiencies.
59939beb93cSSam Leffler 	 */
60039beb93cSSam Leffler 	int wpa_ptk_rekey;
601e28a4053SRui Paulo 
602c1d255d3SCy Schubert 	/** wpa_deny_ptk0_rekey - Control PTK0 rekeying
603c1d255d3SCy Schubert 	 *
604c1d255d3SCy Schubert 	 * Rekeying a pairwise key using only keyid 0 (PTK0 rekey) has many
605c1d255d3SCy Schubert 	 * broken implementations and should be avoided when using or
606c1d255d3SCy Schubert 	 * interacting with one.
607c1d255d3SCy Schubert 	 *
608c1d255d3SCy Schubert 	 * 0 = always rekey when configured/instructed
609c1d255d3SCy Schubert 	 * 1 = only rekey when the local driver is explicitly indicating it can
610c1d255d3SCy Schubert 	 *	perform this operation without issues
611c1d255d3SCy Schubert 	 * 2 = never allow PTK0 rekeys
612c1d255d3SCy Schubert 	 */
613c1d255d3SCy Schubert 	enum ptk0_rekey_handling wpa_deny_ptk0_rekey;
614c1d255d3SCy Schubert 
615e28a4053SRui Paulo 	/**
616780fb4a2SCy Schubert 	 * group_rekey - Group rekeying time in seconds
617780fb4a2SCy Schubert 	 *
618780fb4a2SCy Schubert 	 * This value, if non-zero, is used as the dot11RSNAConfigGroupRekeyTime
619780fb4a2SCy Schubert 	 * parameter when operating in Authenticator role in IBSS.
620780fb4a2SCy Schubert 	 */
621780fb4a2SCy Schubert 	int group_rekey;
622780fb4a2SCy Schubert 
623780fb4a2SCy Schubert 	/**
624e28a4053SRui Paulo 	 * scan_freq - Array of frequencies to scan or %NULL for all
625e28a4053SRui Paulo 	 *
626e28a4053SRui Paulo 	 * This is an optional zero-terminated array of frequencies in
627e28a4053SRui Paulo 	 * megahertz (MHz) to include in scan requests when searching for this
628e28a4053SRui Paulo 	 * network. This can be used to speed up scanning when the network is
629e28a4053SRui Paulo 	 * known to not use all possible channels.
630e28a4053SRui Paulo 	 */
631e28a4053SRui Paulo 	int *scan_freq;
632e28a4053SRui Paulo 
633e28a4053SRui Paulo 	/**
634e28a4053SRui Paulo 	 * bgscan - Background scan and roaming parameters or %NULL if none
635e28a4053SRui Paulo 	 *
636e28a4053SRui Paulo 	 * This is an optional set of parameters for background scanning and
637e28a4053SRui Paulo 	 * roaming within a network (ESS) in following format:
638e28a4053SRui Paulo 	 * <bgscan module name>:<module parameters>
639e28a4053SRui Paulo 	 */
640e28a4053SRui Paulo 	char *bgscan;
641e28a4053SRui Paulo 
642e28a4053SRui Paulo 	/**
643f05cddf9SRui Paulo 	 * ignore_broadcast_ssid - Hide SSID in AP mode
644f05cddf9SRui Paulo 	 *
645f05cddf9SRui Paulo 	 * Send empty SSID in beacons and ignore probe request frames that do
646f05cddf9SRui Paulo 	 * not specify full SSID, i.e., require stations to know SSID.
647f05cddf9SRui Paulo 	 * default: disabled (0)
648f05cddf9SRui Paulo 	 * 1 = send empty (length=0) SSID in beacon and ignore probe request
649f05cddf9SRui Paulo 	 * for broadcast SSID
650f05cddf9SRui Paulo 	 * 2 = clear SSID (ASCII 0), but keep the original length (this may be
651f05cddf9SRui Paulo 	 * required with some clients that do not support empty SSID) and
652f05cddf9SRui Paulo 	 * ignore probe requests for broadcast SSID
653f05cddf9SRui Paulo 	 */
654f05cddf9SRui Paulo 	int ignore_broadcast_ssid;
655f05cddf9SRui Paulo 
656f05cddf9SRui Paulo 	/**
657e28a4053SRui Paulo 	 * freq_list - Array of allowed frequencies or %NULL for all
658e28a4053SRui Paulo 	 *
659e28a4053SRui Paulo 	 * This is an optional zero-terminated array of frequencies in
660e28a4053SRui Paulo 	 * megahertz (MHz) to allow for selecting the BSS. If set, scan results
661e28a4053SRui Paulo 	 * that do not match any of the specified frequencies are not
662e28a4053SRui Paulo 	 * considered when selecting a BSS.
663e28a4053SRui Paulo 	 */
664e28a4053SRui Paulo 	int *freq_list;
665f05cddf9SRui Paulo 
666f05cddf9SRui Paulo 	/**
667f05cddf9SRui Paulo 	 * p2p_client_list - List of P2P Clients in a persistent group (GO)
668f05cddf9SRui Paulo 	 *
669f05cddf9SRui Paulo 	 * This is a list of P2P Clients (P2P Device Address) that have joined
670f05cddf9SRui Paulo 	 * the persistent group. This is maintained on the GO for persistent
671f05cddf9SRui Paulo 	 * group entries (disabled == 2).
672f05cddf9SRui Paulo 	 */
673f05cddf9SRui Paulo 	u8 *p2p_client_list;
674f05cddf9SRui Paulo 
675f05cddf9SRui Paulo 	/**
676f05cddf9SRui Paulo 	 * num_p2p_clients - Number of entries in p2p_client_list
677f05cddf9SRui Paulo 	 */
678f05cddf9SRui Paulo 	size_t num_p2p_clients;
679f05cddf9SRui Paulo 
680f05cddf9SRui Paulo #ifndef P2P_MAX_STORED_CLIENTS
681f05cddf9SRui Paulo #define P2P_MAX_STORED_CLIENTS 100
682f05cddf9SRui Paulo #endif /* P2P_MAX_STORED_CLIENTS */
683f05cddf9SRui Paulo 
684f05cddf9SRui Paulo 	/**
6855b9c547cSRui Paulo 	 * psk_list - Per-client PSKs (struct psk_list_entry)
6865b9c547cSRui Paulo 	 */
6875b9c547cSRui Paulo 	struct dl_list psk_list;
6885b9c547cSRui Paulo 
6895b9c547cSRui Paulo 	/**
690f05cddf9SRui Paulo 	 * p2p_group - Network generated as a P2P group (used internally)
691f05cddf9SRui Paulo 	 */
692f05cddf9SRui Paulo 	int p2p_group;
693f05cddf9SRui Paulo 
694f05cddf9SRui Paulo 	/**
695f05cddf9SRui Paulo 	 * p2p_persistent_group - Whether this is a persistent group
696f05cddf9SRui Paulo 	 */
697f05cddf9SRui Paulo 	int p2p_persistent_group;
698f05cddf9SRui Paulo 
699f05cddf9SRui Paulo 	/**
700f05cddf9SRui Paulo 	 * temporary - Whether this network is temporary and not to be saved
701f05cddf9SRui Paulo 	 */
702f05cddf9SRui Paulo 	int temporary;
703f05cddf9SRui Paulo 
704f05cddf9SRui Paulo 	/**
705f05cddf9SRui Paulo 	 * export_keys - Whether keys may be exported
706f05cddf9SRui Paulo 	 *
707f05cddf9SRui Paulo 	 * This attribute will be set when keys are determined through
708f05cddf9SRui Paulo 	 * WPS or similar so that they may be exported.
709f05cddf9SRui Paulo 	 */
710f05cddf9SRui Paulo 	int export_keys;
711f05cddf9SRui Paulo 
712f05cddf9SRui Paulo #ifdef CONFIG_HT_OVERRIDES
713f05cddf9SRui Paulo 	/**
714f05cddf9SRui Paulo 	 * disable_ht - Disable HT (IEEE 802.11n) for this network
715f05cddf9SRui Paulo 	 *
716f05cddf9SRui Paulo 	 * By default, use it if it is available, but this can be configured
717f05cddf9SRui Paulo 	 * to 1 to have it disabled.
718f05cddf9SRui Paulo 	 */
719f05cddf9SRui Paulo 	int disable_ht;
720f05cddf9SRui Paulo 
721f05cddf9SRui Paulo 	/**
722f05cddf9SRui Paulo 	 * disable_ht40 - Disable HT40 for this network
723f05cddf9SRui Paulo 	 *
724f05cddf9SRui Paulo 	 * By default, use it if it is available, but this can be configured
725f05cddf9SRui Paulo 	 * to 1 to have it disabled.
726f05cddf9SRui Paulo 	 */
727f05cddf9SRui Paulo 	int disable_ht40;
728f05cddf9SRui Paulo 
729f05cddf9SRui Paulo 	/**
730f05cddf9SRui Paulo 	 * disable_sgi - Disable SGI (Short Guard Interval) for this network
731f05cddf9SRui Paulo 	 *
732f05cddf9SRui Paulo 	 * By default, use it if it is available, but this can be configured
733f05cddf9SRui Paulo 	 * to 1 to have it disabled.
734f05cddf9SRui Paulo 	 */
735f05cddf9SRui Paulo 	int disable_sgi;
736f05cddf9SRui Paulo 
737f05cddf9SRui Paulo 	/**
7385b9c547cSRui Paulo 	 * disable_ldpc - Disable LDPC for this network
7395b9c547cSRui Paulo 	 *
7405b9c547cSRui Paulo 	 * By default, use it if it is available, but this can be configured
7415b9c547cSRui Paulo 	 * to 1 to have it disabled.
7425b9c547cSRui Paulo 	 */
7435b9c547cSRui Paulo 	int disable_ldpc;
7445b9c547cSRui Paulo 
7455b9c547cSRui Paulo 	/**
7465b9c547cSRui Paulo 	 * ht40_intolerant - Indicate 40 MHz intolerant for this network
7475b9c547cSRui Paulo 	 */
7485b9c547cSRui Paulo 	int ht40_intolerant;
7495b9c547cSRui Paulo 
7505b9c547cSRui Paulo 	/**
751f05cddf9SRui Paulo 	 * disable_max_amsdu - Disable MAX A-MSDU
752f05cddf9SRui Paulo 	 *
753f05cddf9SRui Paulo 	 * A-MDSU will be 3839 bytes when disabled, or 7935
754f05cddf9SRui Paulo 	 * when enabled (assuming it is otherwise supported)
755f05cddf9SRui Paulo 	 * -1 (default) means do not apply any settings to the kernel.
756f05cddf9SRui Paulo 	 */
757f05cddf9SRui Paulo 	int disable_max_amsdu;
758f05cddf9SRui Paulo 
759f05cddf9SRui Paulo 	/**
760f05cddf9SRui Paulo 	 * ampdu_factor - Maximum A-MPDU Length Exponent
761f05cddf9SRui Paulo 	 *
762f05cddf9SRui Paulo 	 * Value: 0-3, see 7.3.2.56.3 in IEEE Std 802.11n-2009.
763f05cddf9SRui Paulo 	 */
764f05cddf9SRui Paulo 	int ampdu_factor;
765f05cddf9SRui Paulo 
766f05cddf9SRui Paulo 	/**
767f05cddf9SRui Paulo 	 * ampdu_density - Minimum A-MPDU Start Spacing
768f05cddf9SRui Paulo 	 *
769f05cddf9SRui Paulo 	 * Value: 0-7, see 7.3.2.56.3 in IEEE Std 802.11n-2009.
770f05cddf9SRui Paulo 	 */
771f05cddf9SRui Paulo 	int ampdu_density;
772f05cddf9SRui Paulo 
773f05cddf9SRui Paulo 	/**
774f05cddf9SRui Paulo 	 * ht_mcs - Allowed HT-MCS rates, in ASCII hex: ffff0000...
775f05cddf9SRui Paulo 	 *
776f05cddf9SRui Paulo 	 * By default (empty string): Use whatever the OS has configured.
777f05cddf9SRui Paulo 	 */
778f05cddf9SRui Paulo 	char *ht_mcs;
7794bc52338SCy Schubert 
7804bc52338SCy Schubert 	/**
7814bc52338SCy Schubert 	 * tx_stbc - Indicate STBC support for TX streams
7824bc52338SCy Schubert 	 *
7834bc52338SCy Schubert 	 * Value: -1..1, by default (-1): use whatever the OS or card has
7844bc52338SCy Schubert 	 * configured. See IEEE Std 802.11-2016, 9.4.2.56.2.
7854bc52338SCy Schubert 	 */
7864bc52338SCy Schubert 	int tx_stbc;
7874bc52338SCy Schubert 
7884bc52338SCy Schubert 	/**
7894bc52338SCy Schubert 	 * rx_stbc - Indicate STBC support for RX streams
7904bc52338SCy Schubert 	 *
7914bc52338SCy Schubert 	 * Value: -1..3, by default (-1): use whatever the OS or card has
7924bc52338SCy Schubert 	 * configured. See IEEE Std 802.11-2016, 9.4.2.56.2.
7934bc52338SCy Schubert 	 */
7944bc52338SCy Schubert 	int rx_stbc;
795f05cddf9SRui Paulo #endif /* CONFIG_HT_OVERRIDES */
796f05cddf9SRui Paulo 
7975b9c547cSRui Paulo #ifdef CONFIG_VHT_OVERRIDES
7985b9c547cSRui Paulo 	/**
7995b9c547cSRui Paulo 	 * disable_vht - Disable VHT (IEEE 802.11ac) for this network
8005b9c547cSRui Paulo 	 *
8015b9c547cSRui Paulo 	 * By default, use it if it is available, but this can be configured
8025b9c547cSRui Paulo 	 * to 1 to have it disabled.
8035b9c547cSRui Paulo 	 */
8045b9c547cSRui Paulo 	int disable_vht;
8055b9c547cSRui Paulo 
8065b9c547cSRui Paulo 	/**
8075b9c547cSRui Paulo 	 * vht_capa - VHT capabilities to use
8085b9c547cSRui Paulo 	 */
8095b9c547cSRui Paulo 	unsigned int vht_capa;
8105b9c547cSRui Paulo 
8115b9c547cSRui Paulo 	/**
8125b9c547cSRui Paulo 	 * vht_capa_mask - mask for VHT capabilities
8135b9c547cSRui Paulo 	 */
8145b9c547cSRui Paulo 	unsigned int vht_capa_mask;
8155b9c547cSRui Paulo 
8165b9c547cSRui Paulo 	int vht_rx_mcs_nss_1, vht_rx_mcs_nss_2,
8175b9c547cSRui Paulo 	    vht_rx_mcs_nss_3, vht_rx_mcs_nss_4,
8185b9c547cSRui Paulo 	    vht_rx_mcs_nss_5, vht_rx_mcs_nss_6,
8195b9c547cSRui Paulo 	    vht_rx_mcs_nss_7, vht_rx_mcs_nss_8;
8205b9c547cSRui Paulo 	int vht_tx_mcs_nss_1, vht_tx_mcs_nss_2,
8215b9c547cSRui Paulo 	    vht_tx_mcs_nss_3, vht_tx_mcs_nss_4,
8225b9c547cSRui Paulo 	    vht_tx_mcs_nss_5, vht_tx_mcs_nss_6,
8235b9c547cSRui Paulo 	    vht_tx_mcs_nss_7, vht_tx_mcs_nss_8;
8245b9c547cSRui Paulo #endif /* CONFIG_VHT_OVERRIDES */
8255b9c547cSRui Paulo 
826c1d255d3SCy Schubert #ifdef CONFIG_HE_OVERRIDES
827c1d255d3SCy Schubert 	/**
828c1d255d3SCy Schubert 	 * disable_he - Disable HE (IEEE 802.11ax) for this network
829c1d255d3SCy Schubert 	 *
830c1d255d3SCy Schubert 	 * By default, use it if it is available, but this can be configured
831c1d255d3SCy Schubert 	 * to 1 to have it disabled.
832c1d255d3SCy Schubert 	 */
833c1d255d3SCy Schubert 	int disable_he;
834c1d255d3SCy Schubert #endif /* CONFIG_HE_OVERRIDES */
835c1d255d3SCy Schubert 
836f05cddf9SRui Paulo 	/**
837f05cddf9SRui Paulo 	 * ap_max_inactivity - Timeout in seconds to detect STA's inactivity
838f05cddf9SRui Paulo 	 *
839f05cddf9SRui Paulo 	 * This timeout value is used in AP mode to clean up inactive stations.
840f05cddf9SRui Paulo 	 * By default: 300 seconds.
841f05cddf9SRui Paulo 	 */
842f05cddf9SRui Paulo 	int ap_max_inactivity;
843f05cddf9SRui Paulo 
844f05cddf9SRui Paulo 	/**
845f05cddf9SRui Paulo 	 * dtim_period - DTIM period in Beacon intervals
846f05cddf9SRui Paulo 	 * By default: 2
847f05cddf9SRui Paulo 	 */
848f05cddf9SRui Paulo 	int dtim_period;
849f05cddf9SRui Paulo 
850f05cddf9SRui Paulo 	/**
8515b9c547cSRui Paulo 	 * beacon_int - Beacon interval (default: 100 TU)
8525b9c547cSRui Paulo 	 */
8535b9c547cSRui Paulo 	int beacon_int;
8545b9c547cSRui Paulo 
8555b9c547cSRui Paulo 	/**
856f05cddf9SRui Paulo 	 * auth_failures - Number of consecutive authentication failures
857f05cddf9SRui Paulo 	 */
858f05cddf9SRui Paulo 	unsigned int auth_failures;
859f05cddf9SRui Paulo 
860f05cddf9SRui Paulo 	/**
861f05cddf9SRui Paulo 	 * disabled_until - Network block disabled until this time if non-zero
862f05cddf9SRui Paulo 	 */
8635b9c547cSRui Paulo 	struct os_reltime disabled_until;
864f05cddf9SRui Paulo 
865f05cddf9SRui Paulo 	/**
866*a90b9d01SCy Schubert 	 * disabled_due_to - BSSID of the disabling failure
867*a90b9d01SCy Schubert 	 *
868*a90b9d01SCy Schubert 	 * This identifies the BSS that failed the connection attempt that
869*a90b9d01SCy Schubert 	 * resulted in the network being temporarily disabled.
870*a90b9d01SCy Schubert 	 */
871*a90b9d01SCy Schubert 	u8 disabled_due_to[ETH_ALEN];
872*a90b9d01SCy Schubert 
873*a90b9d01SCy Schubert 	/**
874f05cddf9SRui Paulo 	 * parent_cred - Pointer to parent wpa_cred entry
875f05cddf9SRui Paulo 	 *
876f05cddf9SRui Paulo 	 * This pointer can be used to delete temporary networks when a wpa_cred
877f05cddf9SRui Paulo 	 * that was used to create them is removed. This pointer should not be
878f05cddf9SRui Paulo 	 * dereferences since it may not be updated in all cases.
879f05cddf9SRui Paulo 	 */
880f05cddf9SRui Paulo 	void *parent_cred;
8815b9c547cSRui Paulo 
8825b9c547cSRui Paulo #ifdef CONFIG_MACSEC
8835b9c547cSRui Paulo 	/**
8845b9c547cSRui Paulo 	 * macsec_policy - Determines the policy for MACsec secure session
8855b9c547cSRui Paulo 	 *
8865b9c547cSRui Paulo 	 * 0: MACsec not in use (default)
8875b9c547cSRui Paulo 	 * 1: MACsec enabled - Should secure, accept key server's advice to
8885b9c547cSRui Paulo 	 *    determine whether to use a secure session or not.
8895b9c547cSRui Paulo 	 */
8905b9c547cSRui Paulo 	int macsec_policy;
89185732ac8SCy Schubert 
89285732ac8SCy Schubert 	/**
89385732ac8SCy Schubert 	 * macsec_integ_only - Determines how MACsec are transmitted
89485732ac8SCy Schubert 	 *
89585732ac8SCy Schubert 	 * This setting applies only when MACsec is in use, i.e.,
89685732ac8SCy Schubert 	 *  - macsec_policy is enabled
89785732ac8SCy Schubert 	 *  - the key server has decided to enable MACsec
89885732ac8SCy Schubert 	 *
89985732ac8SCy Schubert 	 * 0: Encrypt traffic (default)
90085732ac8SCy Schubert 	 * 1: Integrity only
90185732ac8SCy Schubert 	 */
90285732ac8SCy Schubert 	int macsec_integ_only;
90385732ac8SCy Schubert 
90485732ac8SCy Schubert 	/**
9054bc52338SCy Schubert 	 * macsec_replay_protect - Enable MACsec replay protection
9064bc52338SCy Schubert 	 *
9074bc52338SCy Schubert 	 * This setting applies only when MACsec is in use, i.e.,
9084bc52338SCy Schubert 	 *  - macsec_policy is enabled
9094bc52338SCy Schubert 	 *  - the key server has decided to enable MACsec
9104bc52338SCy Schubert 	 *
9114bc52338SCy Schubert 	 * 0: Replay protection disabled (default)
9124bc52338SCy Schubert 	 * 1: Replay protection enabled
9134bc52338SCy Schubert 	 */
9144bc52338SCy Schubert 	int macsec_replay_protect;
9154bc52338SCy Schubert 
9164bc52338SCy Schubert 	/**
9174bc52338SCy Schubert 	 * macsec_replay_window - MACsec replay protection window
9184bc52338SCy Schubert 	 *
9194bc52338SCy Schubert 	 * A window in which replay is tolerated, to allow receipt of frames
9204bc52338SCy Schubert 	 * that have been misordered by the network.
9214bc52338SCy Schubert 	 *
9224bc52338SCy Schubert 	 * This setting applies only when MACsec replay protection active, i.e.,
9234bc52338SCy Schubert 	 *  - macsec_replay_protect is enabled
9244bc52338SCy Schubert 	 *  - the key server has decided to enable MACsec
9254bc52338SCy Schubert 	 *
9264bc52338SCy Schubert 	 * 0: No replay window, strict check (default)
9274bc52338SCy Schubert 	 * 1..2^32-1: number of packets that could be misordered
9284bc52338SCy Schubert 	 */
9294bc52338SCy Schubert 	u32 macsec_replay_window;
9304bc52338SCy Schubert 
9314bc52338SCy Schubert 	/**
932*a90b9d01SCy Schubert 	 * macsec_offload - Enable MACsec hardware offload
933*a90b9d01SCy Schubert 	 *
934*a90b9d01SCy Schubert 	 * This setting applies only when MACsec is in use, i.e.,
935*a90b9d01SCy Schubert 	 *  - the key server has decided to enable MACsec
936*a90b9d01SCy Schubert 	 *
937*a90b9d01SCy Schubert 	 * 0 = MACSEC_OFFLOAD_OFF (default)
938*a90b9d01SCy Schubert 	 * 1 = MACSEC_OFFLOAD_PHY
939*a90b9d01SCy Schubert 	 * 2 = MACSEC_OFFLOAD_MAC
940*a90b9d01SCy Schubert 	 */
941*a90b9d01SCy Schubert 	int macsec_offload;
942*a90b9d01SCy Schubert 
943*a90b9d01SCy Schubert 	/**
94485732ac8SCy Schubert 	 * macsec_port - MACsec port (in SCI)
94585732ac8SCy Schubert 	 *
94685732ac8SCy Schubert 	 * Port component of the SCI.
94785732ac8SCy Schubert 	 *
94885732ac8SCy Schubert 	 * Range: 1-65534 (default: 1)
94985732ac8SCy Schubert 	 */
95085732ac8SCy Schubert 	int macsec_port;
95185732ac8SCy Schubert 
95285732ac8SCy Schubert 	/**
95385732ac8SCy Schubert 	 * mka_priority - Priority of MKA Actor
95485732ac8SCy Schubert 	 *
95585732ac8SCy Schubert 	 * Range: 0-255 (default: 255)
95685732ac8SCy Schubert 	 */
95785732ac8SCy Schubert 	int mka_priority;
95885732ac8SCy Schubert 
95985732ac8SCy Schubert 	/**
960*a90b9d01SCy Schubert 	 * macsec_csindex - Cipher suite index for MACsec
961*a90b9d01SCy Schubert 	 *
962*a90b9d01SCy Schubert 	 * Range: 0-1 (default: 0)
963*a90b9d01SCy Schubert 	 */
964*a90b9d01SCy Schubert 	int macsec_csindex;
965*a90b9d01SCy Schubert 
966*a90b9d01SCy Schubert 	/**
96785732ac8SCy Schubert 	 * mka_ckn - MKA pre-shared CKN
96885732ac8SCy Schubert 	 */
9694bc52338SCy Schubert #define MACSEC_CKN_MAX_LEN 32
9704bc52338SCy Schubert 	size_t mka_ckn_len;
9714bc52338SCy Schubert 	u8 mka_ckn[MACSEC_CKN_MAX_LEN];
97285732ac8SCy Schubert 
97385732ac8SCy Schubert 	/**
97485732ac8SCy Schubert 	 * mka_cak - MKA pre-shared CAK
97585732ac8SCy Schubert 	 */
9764bc52338SCy Schubert #define MACSEC_CAK_MAX_LEN 32
9774bc52338SCy Schubert 	size_t mka_cak_len;
9784bc52338SCy Schubert 	u8 mka_cak[MACSEC_CAK_MAX_LEN];
97985732ac8SCy Schubert 
98085732ac8SCy Schubert #define MKA_PSK_SET_CKN BIT(0)
98185732ac8SCy Schubert #define MKA_PSK_SET_CAK BIT(1)
98285732ac8SCy Schubert #define MKA_PSK_SET (MKA_PSK_SET_CKN | MKA_PSK_SET_CAK)
98385732ac8SCy Schubert 	/**
98485732ac8SCy Schubert 	 * mka_psk_set - Whether mka_ckn and mka_cak are set
98585732ac8SCy Schubert 	 */
98685732ac8SCy Schubert 	u8 mka_psk_set;
9875b9c547cSRui Paulo #endif /* CONFIG_MACSEC */
9885b9c547cSRui Paulo 
9895b9c547cSRui Paulo #ifdef CONFIG_HS20
9905b9c547cSRui Paulo 	int update_identifier;
99185732ac8SCy Schubert 
99285732ac8SCy Schubert 	/**
99385732ac8SCy Schubert 	 * roaming_consortium_selection - Roaming Consortium Selection
99485732ac8SCy Schubert 	 *
99585732ac8SCy Schubert 	 * The matching Roaming Consortium OI that was used to generate this
99685732ac8SCy Schubert 	 * network profile.
99785732ac8SCy Schubert 	 */
99885732ac8SCy Schubert 	u8 *roaming_consortium_selection;
99985732ac8SCy Schubert 
100085732ac8SCy Schubert 	/**
100185732ac8SCy Schubert 	 * roaming_consortium_selection_len - roaming_consortium_selection len
100285732ac8SCy Schubert 	 */
100385732ac8SCy Schubert 	size_t roaming_consortium_selection_len;
10045b9c547cSRui Paulo #endif /* CONFIG_HS20 */
10055b9c547cSRui Paulo 
10065b9c547cSRui Paulo 	unsigned int wps_run;
10075b9c547cSRui Paulo 
10085b9c547cSRui Paulo 	/**
10095b9c547cSRui Paulo 	 * mac_addr - MAC address policy
10105b9c547cSRui Paulo 	 *
10115b9c547cSRui Paulo 	 * 0 = use permanent MAC address
10125b9c547cSRui Paulo 	 * 1 = use random MAC address for each ESS connection
10135b9c547cSRui Paulo 	 * 2 = like 1, but maintain OUI (with local admin bit set)
1014*a90b9d01SCy Schubert 	 * 3 = use dedicated/pregenerated MAC address (see mac_value)
10155b9c547cSRui Paulo 	 *
10165b9c547cSRui Paulo 	 * Internally, special value -1 is used to indicate that the parameter
10175b9c547cSRui Paulo 	 * was not specified in the configuration (i.e., default behavior is
10185b9c547cSRui Paulo 	 * followed).
10195b9c547cSRui Paulo 	 */
1020*a90b9d01SCy Schubert 	enum wpas_mac_addr_style mac_addr;
1021*a90b9d01SCy Schubert 
1022*a90b9d01SCy Schubert 	/**
1023*a90b9d01SCy Schubert 	 * mac_value - Specific MAC address to be used
1024*a90b9d01SCy Schubert 	 *
1025*a90b9d01SCy Schubert 	 * When mac_addr policy is equal to 3 this is the value of the MAC
1026*a90b9d01SCy Schubert 	 * address that should be used.
1027*a90b9d01SCy Schubert 	 */
1028*a90b9d01SCy Schubert 	u8 mac_value[ETH_ALEN];
10295b9c547cSRui Paulo 
10305b9c547cSRui Paulo 	/**
10315b9c547cSRui Paulo 	 * no_auto_peer - Do not automatically peer with compatible mesh peers
10325b9c547cSRui Paulo 	 *
10335b9c547cSRui Paulo 	 * When unset, the reception of a beacon from a another mesh peer in
10345b9c547cSRui Paulo 	 * this MBSS will trigger a peering attempt.
10355b9c547cSRui Paulo 	 */
10365b9c547cSRui Paulo 	int no_auto_peer;
1037780fb4a2SCy Schubert 
1038780fb4a2SCy Schubert 	/**
103985732ac8SCy Schubert 	 * mesh_rssi_threshold - Set mesh parameter mesh_rssi_threshold (dBm)
104085732ac8SCy Schubert 	 *
104185732ac8SCy Schubert 	 * -255..-1 = threshold value in dBm
104285732ac8SCy Schubert 	 * 0 = not using RSSI threshold
104385732ac8SCy Schubert 	 * 1 = do not change driver default
104485732ac8SCy Schubert 	 */
104585732ac8SCy Schubert 	int mesh_rssi_threshold;
104685732ac8SCy Schubert 
104785732ac8SCy Schubert 	/**
1048780fb4a2SCy Schubert 	 * wps_disabled - WPS disabled in AP mode
1049780fb4a2SCy Schubert 	 *
1050780fb4a2SCy Schubert 	 * 0 = WPS enabled and configured (default)
1051780fb4a2SCy Schubert 	 * 1 = WPS disabled
1052780fb4a2SCy Schubert 	 */
1053780fb4a2SCy Schubert 	int wps_disabled;
105485732ac8SCy Schubert 
105585732ac8SCy Schubert 	/**
105685732ac8SCy Schubert 	 * fils_dh_group - FILS DH Group
105785732ac8SCy Schubert 	 *
105885732ac8SCy Schubert 	 * 0 = PFS disabled with FILS shared key authentication
105985732ac8SCy Schubert 	 * 1-65535 DH Group to use for FILS PFS
106085732ac8SCy Schubert 	 */
106185732ac8SCy Schubert 	int fils_dh_group;
106285732ac8SCy Schubert 
106385732ac8SCy Schubert 	/**
106485732ac8SCy Schubert 	 * dpp_connector - DPP Connector (signedConnector as string)
106585732ac8SCy Schubert 	 */
106685732ac8SCy Schubert 	char *dpp_connector;
106785732ac8SCy Schubert 
106885732ac8SCy Schubert 	/**
106985732ac8SCy Schubert 	 * dpp_netaccesskey - DPP netAccessKey (own private key)
107085732ac8SCy Schubert 	 */
107185732ac8SCy Schubert 	u8 *dpp_netaccesskey;
107285732ac8SCy Schubert 
107385732ac8SCy Schubert 	/**
107485732ac8SCy Schubert 	 * dpp_netaccesskey_len - DPP netAccessKey length in octets
107585732ac8SCy Schubert 	 */
107685732ac8SCy Schubert 	size_t dpp_netaccesskey_len;
107785732ac8SCy Schubert 
107885732ac8SCy Schubert 	/**
107985732ac8SCy Schubert 	 * net_access_key_expiry - DPP netAccessKey expiry in UNIX time stamp
108085732ac8SCy Schubert 	 *
108185732ac8SCy Schubert 	 * 0 indicates no expiration.
108285732ac8SCy Schubert 	 */
108385732ac8SCy Schubert 	unsigned int dpp_netaccesskey_expiry;
108485732ac8SCy Schubert 
108585732ac8SCy Schubert 	/**
108685732ac8SCy Schubert 	 * dpp_csign - C-sign-key (Configurator public key)
108785732ac8SCy Schubert 	 */
108885732ac8SCy Schubert 	u8 *dpp_csign;
108985732ac8SCy Schubert 
109085732ac8SCy Schubert 	/**
109185732ac8SCy Schubert 	 * dpp_csign_len - C-sign-key length in octets
109285732ac8SCy Schubert 	 */
109385732ac8SCy Schubert 	size_t dpp_csign_len;
109485732ac8SCy Schubert 
109585732ac8SCy Schubert 	/**
1096c1d255d3SCy Schubert 	 * dpp_pp_key - ppKey (Configurator privacy protection public key)
1097c1d255d3SCy Schubert 	 */
1098c1d255d3SCy Schubert 	u8 *dpp_pp_key;
1099c1d255d3SCy Schubert 
1100c1d255d3SCy Schubert 	/**
1101c1d255d3SCy Schubert 	 * dpp_pp_key_len - ppKey length in octets
1102c1d255d3SCy Schubert 	 */
1103c1d255d3SCy Schubert 	size_t dpp_pp_key_len;
1104c1d255d3SCy Schubert 
1105c1d255d3SCy Schubert 	/**
1106c1d255d3SCy Schubert 	 * dpp_pfs - DPP PFS
1107c1d255d3SCy Schubert 	 * 0: allow PFS to be used or not used
1108c1d255d3SCy Schubert 	 * 1: require PFS to be used (note: not compatible with DPP R1)
1109c1d255d3SCy Schubert 	 * 2: do not allow PFS to be used
1110c1d255d3SCy Schubert 	 */
1111c1d255d3SCy Schubert 	int dpp_pfs;
1112c1d255d3SCy Schubert 
1113c1d255d3SCy Schubert 	/**
1114c1d255d3SCy Schubert 	 * dpp_pfs_fallback - DPP PFS fallback selection
1115c1d255d3SCy Schubert 	 *
1116c1d255d3SCy Schubert 	 * This is an internally used variable (i.e., not used in external
1117c1d255d3SCy Schubert 	 * configuration) to track state of the DPP PFS fallback mechanism.
1118c1d255d3SCy Schubert 	 */
1119c1d255d3SCy Schubert 	int dpp_pfs_fallback;
1120c1d255d3SCy Schubert 
1121c1d255d3SCy Schubert 	/**
1122*a90b9d01SCy Schubert 	 * dpp_connector_privacy - Network introduction type
1123*a90b9d01SCy Schubert 	 * 0: unprotected variant from DPP R1
1124*a90b9d01SCy Schubert 	 * 1: privacy protecting (station Connector encrypted) variant from
1125*a90b9d01SCy Schubert 	 *    DPP R3
1126*a90b9d01SCy Schubert 	 */
1127*a90b9d01SCy Schubert 	int dpp_connector_privacy;
1128*a90b9d01SCy Schubert 
1129*a90b9d01SCy Schubert 	/**
113085732ac8SCy Schubert 	 * owe_group - OWE DH Group
113185732ac8SCy Schubert 	 *
113285732ac8SCy Schubert 	 * 0 = use default (19) first and then try all supported groups one by
113385732ac8SCy Schubert 	 *	one if AP rejects the selected group
113485732ac8SCy Schubert 	 * 1-65535 DH Group to use for OWE
113585732ac8SCy Schubert 	 *
113685732ac8SCy Schubert 	 * Groups 19 (NIST P-256), 20 (NIST P-384), and 21 (NIST P-521) are
113785732ac8SCy Schubert 	 * currently supported.
113885732ac8SCy Schubert 	 */
113985732ac8SCy Schubert 	int owe_group;
114085732ac8SCy Schubert 
114185732ac8SCy Schubert 	/**
114285732ac8SCy Schubert 	 * owe_only - OWE-only mode (disable transition mode)
114385732ac8SCy Schubert 	 *
114485732ac8SCy Schubert 	 * 0 = enable transition mode (allow connection to either OWE or open
114585732ac8SCy Schubert 	 *	BSS)
114685732ac8SCy Schubert 	 * 1 = disable transition mode (allow connection only with OWE)
114785732ac8SCy Schubert 	 */
114885732ac8SCy Schubert 	int owe_only;
114985732ac8SCy Schubert 
115085732ac8SCy Schubert 	/**
1151c1d255d3SCy Schubert 	 * owe_ptk_workaround - OWE PTK derivation workaround
1152c1d255d3SCy Schubert 	 *
1153c1d255d3SCy Schubert 	 * Initial OWE implementation used SHA256 when deriving the PTK for all
1154c1d255d3SCy Schubert 	 * OWE groups. This was supposed to change to SHA384 for group 20 and
1155c1d255d3SCy Schubert 	 * SHA512 for group 21. This parameter can be used to enable older
1156c1d255d3SCy Schubert 	 * behavior mainly for testing purposes. There is no impact to group 19
1157c1d255d3SCy Schubert 	 * behavior, but if enabled, this will make group 20 and 21 cases use
1158c1d255d3SCy Schubert 	 * SHA256-based PTK derivation which will not work with the updated
1159c1d255d3SCy Schubert 	 * OWE implementation on the AP side.
1160c1d255d3SCy Schubert 	 */
1161c1d255d3SCy Schubert 	int owe_ptk_workaround;
1162c1d255d3SCy Schubert 
1163c1d255d3SCy Schubert 	/**
116485732ac8SCy Schubert 	 * owe_transition_bss_select_count - OWE transition BSS select count
116585732ac8SCy Schubert 	 *
116685732ac8SCy Schubert 	 * This is an internally used variable (i.e., not used in external
116785732ac8SCy Schubert 	 * configuration) to track the number of selection attempts done for
116885732ac8SCy Schubert 	 * OWE BSS in transition mode. This allows fallback to an open BSS if
116985732ac8SCy Schubert 	 * the selection attempts for OWE BSS exceed the configured threshold.
117085732ac8SCy Schubert 	 */
117185732ac8SCy Schubert 	int owe_transition_bss_select_count;
11724bc52338SCy Schubert 
11734bc52338SCy Schubert 	/**
11744bc52338SCy Schubert 	 * multi_ap_backhaul_sta - Multi-AP backhaul STA
11754bc52338SCy Schubert 	 * 0 = normal (non-Multi-AP) station
11764bc52338SCy Schubert 	 * 1 = Multi-AP backhaul station
11774bc52338SCy Schubert 	 */
11784bc52338SCy Schubert 	int multi_ap_backhaul_sta;
1179206b73d0SCy Schubert 
1180206b73d0SCy Schubert 	/**
1181206b73d0SCy Schubert 	 * ft_eap_pmksa_caching - Whether FT-EAP PMKSA caching is allowed
1182206b73d0SCy Schubert 	 * 0 = do not try to use PMKSA caching with FT-EAP
1183206b73d0SCy Schubert 	 * 1 = try to use PMKSA caching with FT-EAP
1184206b73d0SCy Schubert 	 *
1185206b73d0SCy Schubert 	 * This controls whether to try to use PMKSA caching with FT-EAP for the
1186206b73d0SCy Schubert 	 * FT initial mobility domain association.
1187206b73d0SCy Schubert 	 */
1188206b73d0SCy Schubert 	int ft_eap_pmksa_caching;
1189c1d255d3SCy Schubert 
1190c1d255d3SCy Schubert 	/**
1191*a90b9d01SCy Schubert 	 * multi_ap_profile - Supported Multi-AP profile
1192*a90b9d01SCy Schubert 	 */
1193*a90b9d01SCy Schubert 	int multi_ap_profile;
1194*a90b9d01SCy Schubert 
1195*a90b9d01SCy Schubert 	/**
1196c1d255d3SCy Schubert 	 * beacon_prot - Whether Beacon protection is enabled
1197c1d255d3SCy Schubert 	 *
1198c1d255d3SCy Schubert 	 * This depends on management frame protection (ieee80211w) being
1199c1d255d3SCy Schubert 	 * enabled.
1200c1d255d3SCy Schubert 	 */
1201c1d255d3SCy Schubert 	int beacon_prot;
1202c1d255d3SCy Schubert 
1203c1d255d3SCy Schubert 	/**
1204c1d255d3SCy Schubert 	 * transition_disable - Transition Disable indication
1205c1d255d3SCy Schubert 	 * The AP can notify authenticated stations to disable transition mode
1206c1d255d3SCy Schubert 	 * in their network profiles when the network has completed transition
1207c1d255d3SCy Schubert 	 * steps, i.e., once sufficiently large number of APs in the ESS have
1208c1d255d3SCy Schubert 	 * been updated to support the more secure alternative. When this
1209c1d255d3SCy Schubert 	 * indication is used, the stations are expected to automatically
1210c1d255d3SCy Schubert 	 * disable transition mode and less secure security options. This
1211c1d255d3SCy Schubert 	 * includes use of WEP, TKIP (including use of TKIP as the group
1212c1d255d3SCy Schubert 	 * cipher), and connections without PMF.
1213c1d255d3SCy Schubert 	 * Bitmap bits:
1214c1d255d3SCy Schubert 	 * bit 0 (0x01): WPA3-Personal (i.e., disable WPA2-Personal = WPA-PSK
1215c1d255d3SCy Schubert 	 *	and only allow SAE to be used)
1216c1d255d3SCy Schubert 	 * bit 1 (0x02): SAE-PK (disable SAE without use of SAE-PK)
1217c1d255d3SCy Schubert 	 * bit 2 (0x04): WPA3-Enterprise (move to requiring PMF)
1218c1d255d3SCy Schubert 	 * bit 3 (0x08): Enhanced Open (disable use of open network; require
1219c1d255d3SCy Schubert 	 *	OWE)
1220c1d255d3SCy Schubert 	 */
1221c1d255d3SCy Schubert 	u8 transition_disable;
1222c1d255d3SCy Schubert 
1223c1d255d3SCy Schubert 	/**
1224c1d255d3SCy Schubert 	 * sae_pk - SAE-PK mode
1225c1d255d3SCy Schubert 	 * 0 = automatic SAE/SAE-PK selection based on password; enable
1226c1d255d3SCy Schubert 	 * transition mode (allow SAE authentication without SAE-PK)
1227c1d255d3SCy Schubert 	 * 1 = SAE-PK only (disable transition mode; allow SAE authentication
1228c1d255d3SCy Schubert 	 * only with SAE-PK)
1229c1d255d3SCy Schubert 	 * 2 = disable SAE-PK (allow SAE authentication only without SAE-PK)
1230c1d255d3SCy Schubert 	 */
1231c1d255d3SCy Schubert 	enum sae_pk_mode sae_pk;
1232c1d255d3SCy Schubert 
1233c1d255d3SCy Schubert 	/**
1234c1d255d3SCy Schubert 	 * was_recently_reconfigured - Whether this SSID config has been changed
1235c1d255d3SCy Schubert 	 * recently
1236c1d255d3SCy Schubert 	 *
1237c1d255d3SCy Schubert 	 * This is an internally used variable, i.e., not used in external
1238c1d255d3SCy Schubert 	 * configuration.
1239c1d255d3SCy Schubert 	 */
1240c1d255d3SCy Schubert 	bool was_recently_reconfigured;
12414b72b91aSCy Schubert 
12424b72b91aSCy Schubert 	/**
12434b72b91aSCy Schubert 	 * sae_pwe - SAE mechanism for PWE derivation
12444b72b91aSCy Schubert 	 *
12454b72b91aSCy Schubert 	 * Internally, special value 4 (DEFAULT_SAE_PWE) is used to indicate
12464b72b91aSCy Schubert 	 * that the parameter is not set and the global sae_pwe value needs to
12474b72b91aSCy Schubert 	 * be considered.
12484b72b91aSCy Schubert 	 *
12494b72b91aSCy Schubert 	 * 0 = hunting-and-pecking loop only
12504b72b91aSCy Schubert 	 * 1 = hash-to-element only
12514b72b91aSCy Schubert 	 * 2 = both hunting-and-pecking loop and hash-to-element enabled
12524b72b91aSCy Schubert 	 */
1253*a90b9d01SCy Schubert 	enum sae_pwe sae_pwe;
1254*a90b9d01SCy Schubert 
1255*a90b9d01SCy Schubert 	/**
1256*a90b9d01SCy Schubert 	 * disable_eht - Disable EHT (IEEE 802.11be) for this network
1257*a90b9d01SCy Schubert 	 *
1258*a90b9d01SCy Schubert 	 * By default, use it if it is available, but this can be configured
1259*a90b9d01SCy Schubert 	 * to 1 to have it disabled.
1260*a90b9d01SCy Schubert 	 */
1261*a90b9d01SCy Schubert 	int disable_eht;
1262*a90b9d01SCy Schubert 
1263*a90b9d01SCy Schubert 	/**
1264*a90b9d01SCy Schubert 	 * enable_4addr_mode - Set 4addr mode after association
1265*a90b9d01SCy Schubert 	 * 0 = Do not attempt to set 4addr mode
1266*a90b9d01SCy Schubert 	 * 1 = Try to set 4addr mode after association
1267*a90b9d01SCy Schubert 	 *
1268*a90b9d01SCy Schubert 	 * Linux requires that an interface is set to 4addr mode before it can
1269*a90b9d01SCy Schubert 	 * be added to a bridge. Set this to 1 for networks where you intent
1270*a90b9d01SCy Schubert 	 * to use the interface in a bridge.
1271*a90b9d01SCy Schubert 	 */
1272*a90b9d01SCy Schubert 	int enable_4addr_mode;
1273*a90b9d01SCy Schubert 
1274*a90b9d01SCy Schubert 	/**
1275*a90b9d01SCy Schubert 	 * max_idle - BSS max idle period to request
1276*a90b9d01SCy Schubert 	 *
1277*a90b9d01SCy Schubert 	 * If nonzero, request the specified number of 1000 TU (i.e., 1.024 s)
1278*a90b9d01SCy Schubert 	 * as the maximum idle period for the STA during association.
1279*a90b9d01SCy Schubert 	 */
1280*a90b9d01SCy Schubert 	int max_idle;
1281*a90b9d01SCy Schubert 
1282*a90b9d01SCy Schubert 	/**
1283*a90b9d01SCy Schubert 	 * ssid_protection - Whether to use SSID protection in 4-way handshake
1284*a90b9d01SCy Schubert 	 */
1285*a90b9d01SCy Schubert 	bool ssid_protection;
128639beb93cSSam Leffler };
128739beb93cSSam Leffler 
128839beb93cSSam Leffler #endif /* CONFIG_SSID_H */
1289