u16 capability;
const u8 *supp_rates;
size_t supp_rates_len;
- int flags;
u16 listen_interval;
const struct ieee80211_ht_capabilities *ht_capabilities;
};
};
+struct wpa_bss_params {
+ /** Interface name (for multi-SSID/VLAN support) */
+ const char *ifname;
+ /** Whether IEEE 802.1X or WPA/WPA2 is enabled */
+ int enabled;
+
+ int wpa;
+ int ieee802_1x;
+ int wpa_group;
+ int wpa_pairwise;
+ int wpa_key_mgmt;
+ int rsn_preauth;
+};
+
+#define WPA_STA_AUTHORIZED BIT(0)
+#define WPA_STA_WMM BIT(1)
+#define WPA_STA_SHORT_PREAMBLE BIT(2)
+#define WPA_STA_MFP BIT(3)
+
/**
* struct wpa_driver_ops - Driver interface API definition
*
/**
* set_ieee8021x - Enable/disable IEEE 802.1X support (AP only)
- * @ifname: Interface name (for multi-SSID/VLAN support)
* @priv: Private driver interface data
- * @enabled: 1 = enable, 0 = disable
+ * @params: BSS parameters
* Returns: 0 on success, -1 on failure
*
* This is an optional function to configure the kernel driver to
- * enable/disable 802.1X support. This can be left undefined (set to
- * %NULL) if IEEE 802.1X support is always enabled.
+ * enable/disable IEEE 802.1X support and set WPA/WPA2 parameters. This
+ * can be left undefined (set to %NULL) if IEEE 802.1X support is
+ * always enabled and the driver uses set_beacon() to set WPA/RSN IE
+ * for Beacon frames.
*/
- int (*set_ieee8021x)(const char *ifname, void *priv, int enabled);
+ int (*set_ieee8021x)(void *priv, struct wpa_bss_params *params);
/**
* set_privacy - Enable/disable privacy (AP only)
* sta_set_flags - Set station flags (AP only)
* @priv: Private driver interface data
* @addr: Station address
- * @total_flags: Bitmap of all WLAN_STA_* flags currently set
- * @flags_or: Bitmap of WLAN_STA_* flags to add
- * @flags_and: Bitmap of WLAN_STA_* flags to us as a mask
+ * @total_flags: Bitmap of all WPA_STA_* flags currently set
+ * @flags_or: Bitmap of WPA_STA_* flags to add
+ * @flags_and: Bitmap of WPA_STA_* flags to us as a mask
* Returns: 0 on success, -1 on failure
*/
int (*sta_set_flags)(void *priv, const u8 *addr,
* @ifname: Interface name for the new virtual interface
* @addr: Local address to use for the interface or %NULL to use the
* parent interface address
+ * @bss_ctx: BSS context for %WPA_IF_AP_BSS interfaces
* Returns: 0 on success, -1 on failure
*/
int (*if_add)(const char *iface, void *priv,
enum wpa_driver_if_type type, const char *ifname,
- const u8 *addr);
+ const u8 *addr, void *bss_ctx);
/**
* if_remove - Remove a virtual interface
/**
* EVENT_ASSOC_TIMED_OUT - Association timed out
*/
- EVENT_ASSOC_TIMED_OUT
+ EVENT_ASSOC_TIMED_OUT,
+
+ /**
+ * EVENT_FT_RRB_RX - FT (IEEE 802.11r) RRB frame received
+ */
+ EVENT_FT_RRB_RX
} wpa_event_type;
struct timeout_event {
u8 addr[ETH_ALEN];
} timeout_event;
+
+ /**
+ * struct ft_rrb_rx - Data for EVENT_FT_RRB_RX events
+ */
+ struct ft_rrb_rx {
+ const u8 *src;
+ const u8 *data;
+ size_t data_len;
+ } ft_rrb_rx;
};
/**
const u8 *buf, size_t len, int ack);
void hostapd_rx_from_unknown_sta(struct hostapd_data *hapd,
const struct ieee80211_hdr *hdr, size_t len);
+int hostapd_notif_new_sta(struct hostapd_data *hapd, const u8 *addr);
int hostapd_notif_assoc(struct hostapd_data *hapd, const u8 *addr,
const u8 *ie, size_t ielen);
void hostapd_notif_disassoc(struct hostapd_data *hapd, const u8 *addr);
u16 stype, struct hostapd_frame_info *fi);
void hostapd_mgmt_tx_cb(struct hostapd_data *hapd, u8 *buf, size_t len,
u16 stype, int ok);
-void hostapd_michael_mic_failure(struct hostapd_data *hapd, const u8 *addr);
struct hostapd_data * hostapd_sta_get_bss(struct hostapd_data *hapd,
const u8 *addr);
void hostapd_probe_req_rx(struct hostapd_data *hapd, const u8 *sa,