WPS: Allow the priority for the WPS networks to be configured
[mech_eap.git] / wpa_supplicant / config.h
index eeb4ba7..545a4bd 100644 (file)
 #define DEFAULT_RAND_ADDR_LIFETIME 60
 #define DEFAULT_KEY_MGMT_OFFLOAD 1
 #define DEFAULT_CERT_IN_CB 1
+#define DEFAULT_P2P_GO_CTWINDOW 0
 
 #include "config_ssid.h"
 #include "wps/wps.h"
+#include "common/ieee802_11_defs.h"
 #include "common/ieee802_11_common.h"
 
 
@@ -240,7 +242,7 @@ struct wpa_cred {
        char *phase2;
 
        struct excluded_ssid {
-               u8 ssid[MAX_SSID_LEN];
+               u8 ssid[SSID_MAX_LEN];
                size_t ssid_len;
        } *excluded_ssid;
        size_t num_excluded_ssid;
@@ -942,6 +944,14 @@ struct wpa_config {
        int p2p_go_vht;
 
        /**
+        * p2p_go_ctwindow - CTWindow to use when operating as GO
+        *
+        * By default: 0 (no CTWindow). Values 0-127 can be used to indicate
+        * the length of the CTWindow in TUs.
+        */
+       int p2p_go_ctwindow;
+
+       /**
         * p2p_disabled - Whether P2P operations are disabled for this interface
         */
        int p2p_disabled;
@@ -1137,6 +1147,31 @@ struct wpa_config {
         * By default: 300 seconds.
         */
        int mesh_max_inactivity;
+
+       /**
+        * passive_scan - Whether to force passive scan for network connection
+        *
+        * This parameter can be used to force only passive scanning to be used
+        * for network connection cases. It should be noted that this will slow
+        * down scan operations and reduce likelihood of finding the AP. In
+        * addition, some use cases will override this due to functional
+        * requirements, e.g., for finding an AP that uses hidden SSID
+        * (scan_ssid=1) or P2P device discovery.
+        */
+       int passive_scan;
+
+       /**
+        * reassoc_same_bss_optim - Whether to optimize reassoc-to-same-BSS
+        */
+       int reassoc_same_bss_optim;
+
+       /**
+        * wps_priority - Priority for the networks added through WPS
+        *
+        * This priority value will be set to each network profile that is added
+        * by executing the WPS protocol.
+        */
+       int wps_priority;
 };
 
 
@@ -1155,6 +1190,11 @@ int wpa_config_set(struct wpa_ssid *ssid, const char *var, const char *value,
                   int line);
 int wpa_config_set_quoted(struct wpa_ssid *ssid, const char *var,
                          const char *value);
+int wpa_config_dump_values(struct wpa_config *config, char *buf,
+                          size_t buflen);
+int wpa_config_get_value(const char *name, struct wpa_config *config,
+                        char *buf, size_t buflen);
+
 char ** wpa_config_get_all(struct wpa_ssid *ssid, int get_keys);
 char * wpa_config_get(struct wpa_ssid *ssid, const char *var);
 char * wpa_config_get_no_key(struct wpa_ssid *ssid, const char *var);