struct sta_info *sta;
int new_assoc, res;
struct ieee802_11_elems elems;
+#ifdef CONFIG_P2P
+ const u8 *all_ies = ie;
+ size_t all_ies_len = ielen;
+#endif /* CONFIG_P2P */
if (addr == NULL) {
/*
}
sta->flags &= ~(WLAN_STA_WPS | WLAN_STA_MAYBE_WPS);
+#ifdef CONFIG_P2P
+ if (elems.p2p) {
+ wpabuf_free(sta->p2p_ie);
+ sta->p2p_ie = ieee802_11_vendor_ie_concat(all_ies, all_ies_len,
+ P2P_IE_VENDOR_TYPE);
+ }
+#endif /* CONFIG_P2P */
+
if (hapd->conf->wpa) {
if (ie == NULL || ielen == 0) {
if (hapd->conf->wps_state) {
} else
wpa_auth_sta_no_wpa(sta->wpa_sm);
+#ifdef CONFIG_P2P
+ if (elems.p2p) {
+ wpabuf_free(sta->p2p_ie);
+ sta->p2p_ie = ieee802_11_vendor_ie_concat(ies, ies_len,
+ P2P_IE_VENDOR_TYPE);
+ } else {
+ wpabuf_free(sta->p2p_ie);
+ sta->p2p_ie = NULL;
+ }
+#endif /* CONFIG_P2P */
+
return WLAN_STATUS_SUCCESS;
}
#endif /* CONFIG_IEEE80211W */
wpabuf_free(sta->wps_ie);
+ wpabuf_free(sta->p2p_ie);
os_free(sta->ht_capabilities);
#endif /* CONFIG_IEEE80211W */
struct wpabuf *wps_ie; /* WPS IE from (Re)Association Request */
+ struct wpabuf *p2p_ie; /* P2P IE from (Re)Association Request */
};