]> git.ipfire.org Git - thirdparty/hostap.git/blobdiff - wpa_supplicant/wpa_supplicant_i.h
DBus: Add ability to report probe requests
[thirdparty/hostap.git] / wpa_supplicant / wpa_supplicant_i.h
index fd04a7d0adb04048cbcf6f0b133914834321643f..14ef278fed7930efd606ca456f711f20db044ff4 100644 (file)
@@ -2,14 +2,8 @@
  * wpa_supplicant - Internal definitions
  * Copyright (c) 2003-2010, Jouni Malinen <j@w1.fi>
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2 as
- * published by the Free Software Foundation.
- *
- * Alternatively, this software may be distributed under the terms of BSD
- * license.
- *
- * See README and COPYING for more details.
+ * This software may be distributed under the terms of the BSD license.
+ * See README for more details.
  */
 
 #ifndef WPA_SUPPLICANT_I_H
@@ -36,6 +30,7 @@ struct scan_info;
 struct wpa_bss;
 struct wpa_scan_results;
 struct hostapd_hw_modes;
+struct wpa_driver_associate_params;
 
 /*
  * Forward declarations of private structures used within the ctrl_iface
@@ -165,6 +160,11 @@ struct wpa_params {
         */
        int wpa_debug_syslog;
 
+       /**
+        * wpa_debug_tracing - Enable log output through Linux tracing
+        */
+       int wpa_debug_tracing;
+
        /**
         * override_driver - Optional driver parameter override
         *
@@ -204,6 +204,12 @@ struct p2p_srv_upnp {
        char *service;
 };
 
+struct wpa_freq_range {
+       unsigned int min;
+       unsigned int max;
+};
+
+
 /**
  * struct wpa_global - Internal, global data for all %wpa_supplicant interfaces
  *
@@ -225,6 +231,8 @@ struct wpa_global {
        struct dl_list p2p_srv_upnp; /* struct p2p_srv_upnp */
        int p2p_disabled;
        int cross_connection;
+       struct wpa_freq_range *p2p_disallow_freq;
+       unsigned int num_p2p_disallow_freq;
 };
 
 
@@ -257,6 +265,9 @@ struct wpa_supplicant {
 #ifdef CONFIG_CTRL_IFACE_DBUS_NEW
        char *dbus_new_path;
        char *dbus_groupobj_path;
+#ifdef CONFIG_AP
+       char *preq_notify_peer;
+#endif /* CONFIG_AP */
 #endif /* CONFIG_CTRL_IFACE_DBUS_NEW */
        char bridge_ifname[16];
 
@@ -266,7 +277,7 @@ struct wpa_supplicant {
        os_time_t last_michael_mic_error;
        u8 bssid[ETH_ALEN];
        u8 pending_bssid[ETH_ALEN]; /* If wpa_state == WPA_ASSOCIATING, this
-                                    * field contains the targer BSSID. */
+                                    * field contains the target BSSID. */
        int reassociate; /* reassociation requested */
        int disconnected; /* all connections disabled; i.e., do no reassociate
                           * before this has been cleared */
@@ -285,6 +296,12 @@ struct wpa_supplicant {
        void *drv_priv; /* private data used by driver_ops */
        void *global_drv_priv;
 
+       u8 *bssid_filter;
+       size_t bssid_filter_count;
+
+       /* previous scan was wildcard when interleaving between
+        * wildcard scans and specific SSID scan when max_ssids=1 */
+       int prev_scan_wildcard;
        struct wpa_ssid *prev_scan_ssid; /* previously scanned SSID;
                                          * NULL = not yet initialized (start
                                          * with wildcard SSID)
@@ -325,6 +342,10 @@ struct wpa_supplicant {
                             * previous association event */
 
        struct scard_data *scard;
+#ifdef PCSC_FUNCS
+       char imsi[20];
+       int mnc_len;
+#endif /* PCSC_FUNCS */
 
        unsigned char last_eapol_src[ETH_ALEN];
 
@@ -337,8 +358,16 @@ struct wpa_supplicant {
        int scan_runs; /* number of scan runs since WPS was started */
        int *next_scan_freqs;
        int scan_interval; /* time in sec between scans to find suitable AP */
+       int normal_scans; /* normal scans run before sched_scan */
 
        unsigned int drv_flags;
+
+       /*
+        * A bitmap of supported protocols for probe response offload. See
+        * struct wpa_driver_capa in driver.h
+        */
+       unsigned int probe_resp_offloads;
+
        int max_scan_ssids;
        int max_sched_scan_ssids;
        int sched_scan_supported;
@@ -476,6 +505,8 @@ struct wpa_supplicant {
                P2P_GROUP_REMOVAL_IDLE_TIMEOUT,
                P2P_GROUP_REMOVAL_UNAVAILABLE
        } removal_reason;
+
+       unsigned int p2p_cb_on_scan_complete:1;
 #endif /* CONFIG_P2P */
 
        struct wpa_ssid *bgscan_ssid;
@@ -485,6 +516,7 @@ struct wpa_supplicant {
        struct wpa_ssid *connect_without_scan;
 
        int after_wps;
+       int known_wps_freq;
        unsigned int wps_freq;
        int wps_fragment_size;
        int auto_reconnect_disabled;
@@ -508,15 +540,22 @@ struct wpa_supplicant {
                u16 num_modes;
                u16 flags;
        } hw;
+
+       int pno;
 };
 
 
 /* wpa_supplicant.c */
+void wpa_supplicant_apply_ht_overrides(
+       struct wpa_supplicant *wpa_s, struct wpa_ssid *ssid,
+       struct wpa_driver_associate_params *params);
+
 int wpa_set_wep_keys(struct wpa_supplicant *wpa_s, struct wpa_ssid *ssid);
 
 int wpa_supplicant_reload_configuration(struct wpa_supplicant *wpa_s);
 
 const char * wpa_supplicant_state_txt(enum wpa_states state);
+int wpa_supplicant_update_mac_addr(struct wpa_supplicant *wpa_s);
 int wpa_supplicant_driver_init(struct wpa_supplicant *wpa_s);
 int wpa_supplicant_set_suites(struct wpa_supplicant *wpa_s,
                              struct wpa_bss *bss, struct wpa_ssid *ssid,
@@ -552,16 +591,20 @@ int wpa_supplicant_set_bss_expiration_age(struct wpa_supplicant *wpa_s,
                                          unsigned int expire_age);
 int wpa_supplicant_set_bss_expiration_count(struct wpa_supplicant *wpa_s,
                                            unsigned int expire_count);
+int wpa_supplicant_set_scan_interval(struct wpa_supplicant *wpa_s,
+                                    int scan_interval);
 int wpa_supplicant_set_debug_params(struct wpa_global *global,
                                    int debug_level, int debug_timestamp,
                                    int debug_show_keys);
+void free_hw_features(struct wpa_supplicant *wpa_s);
 
 void wpa_show_license(void);
 
 struct wpa_supplicant * wpa_supplicant_add_iface(struct wpa_global *global,
                                                 struct wpa_interface *iface);
 int wpa_supplicant_remove_iface(struct wpa_global *global,
-                               struct wpa_supplicant *wpa_s);
+                               struct wpa_supplicant *wpa_s,
+                               int terminate);
 struct wpa_supplicant * wpa_supplicant_get_iface(struct wpa_global *global,
                                                 const char *ifname);
 struct wpa_global * wpa_supplicant_init(struct wpa_params *params);