mac80211: parse also the RSNXE IE
Parse also the RSN Extension IE when parsing the rest of the IEs. It will be used in a later patch. Signed-off-by: Shaul Triebitz <shaul.triebitz@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Link: https://lore.kernel.org/r/20200131111300.891737-21-luca@coelho.fi Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
parent
ff74c51e8f
commit
c0058df733
|
@ -2532,6 +2532,7 @@ enum ieee80211_eid {
|
||||||
WLAN_EID_FILS_INDICATION = 240,
|
WLAN_EID_FILS_INDICATION = 240,
|
||||||
WLAN_EID_DILS = 241,
|
WLAN_EID_DILS = 241,
|
||||||
WLAN_EID_FRAGMENT = 242,
|
WLAN_EID_FRAGMENT = 242,
|
||||||
|
WLAN_EID_RSNX = 244,
|
||||||
WLAN_EID_EXTENSION = 255
|
WLAN_EID_EXTENSION = 255
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -3421,4 +3422,11 @@ static inline bool for_each_element_completed(const struct element *element,
|
||||||
return (const u8 *)element == (const u8 *)data + datalen;
|
return (const u8 *)element == (const u8 *)data + datalen;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* RSNX Capabilities:
|
||||||
|
* bits 0-3: Field length (n-1)
|
||||||
|
*/
|
||||||
|
#define WLAN_RSNX_CAPA_PROTECTED_TWT BIT(4)
|
||||||
|
#define WLAN_RSNX_CAPA_SAE_H2E BIT(5)
|
||||||
|
|
||||||
#endif /* LINUX_IEEE80211_H */
|
#endif /* LINUX_IEEE80211_H */
|
||||||
|
|
|
@ -1472,6 +1472,7 @@ struct ieee802_11_elems {
|
||||||
const struct ieee80211_tim_ie *tim;
|
const struct ieee80211_tim_ie *tim;
|
||||||
const u8 *challenge;
|
const u8 *challenge;
|
||||||
const u8 *rsn;
|
const u8 *rsn;
|
||||||
|
const u8 *rsnx;
|
||||||
const u8 *erp_info;
|
const u8 *erp_info;
|
||||||
const u8 *ext_supp_rates;
|
const u8 *ext_supp_rates;
|
||||||
const u8 *wmm_info;
|
const u8 *wmm_info;
|
||||||
|
@ -1519,6 +1520,7 @@ struct ieee802_11_elems {
|
||||||
u8 tim_len;
|
u8 tim_len;
|
||||||
u8 challenge_len;
|
u8 challenge_len;
|
||||||
u8 rsn_len;
|
u8 rsn_len;
|
||||||
|
u8 rsnx_len;
|
||||||
u8 ext_supp_rates_len;
|
u8 ext_supp_rates_len;
|
||||||
u8 wmm_info_len;
|
u8 wmm_info_len;
|
||||||
u8 wmm_param_len;
|
u8 wmm_param_len;
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
* Copyright 2007 Johannes Berg <johannes@sipsolutions.net>
|
* Copyright 2007 Johannes Berg <johannes@sipsolutions.net>
|
||||||
* Copyright 2013-2014 Intel Mobile Communications GmbH
|
* Copyright 2013-2014 Intel Mobile Communications GmbH
|
||||||
* Copyright (C) 2015-2017 Intel Deutschland GmbH
|
* Copyright (C) 2015-2017 Intel Deutschland GmbH
|
||||||
* Copyright (C) 2018-2019 Intel Corporation
|
* Copyright (C) 2018-2020 Intel Corporation
|
||||||
*
|
*
|
||||||
* utilities for mac80211
|
* utilities for mac80211
|
||||||
*/
|
*/
|
||||||
|
@ -994,6 +994,7 @@ _ieee802_11_parse_elems_crc(const u8 *start, size_t len, bool action,
|
||||||
case WLAN_EID_CHAN_SWITCH_TIMING:
|
case WLAN_EID_CHAN_SWITCH_TIMING:
|
||||||
case WLAN_EID_LINK_ID:
|
case WLAN_EID_LINK_ID:
|
||||||
case WLAN_EID_BSS_MAX_IDLE_PERIOD:
|
case WLAN_EID_BSS_MAX_IDLE_PERIOD:
|
||||||
|
case WLAN_EID_RSNX:
|
||||||
/*
|
/*
|
||||||
* not listing WLAN_EID_CHANNEL_SWITCH_WRAPPER -- it seems possible
|
* not listing WLAN_EID_CHANNEL_SWITCH_WRAPPER -- it seems possible
|
||||||
* that if the content gets bigger it might be needed more than once
|
* that if the content gets bigger it might be needed more than once
|
||||||
|
@ -1264,6 +1265,10 @@ _ieee802_11_parse_elems_crc(const u8 *start, size_t len, bool action,
|
||||||
if (elen >= sizeof(*elems->max_idle_period_ie))
|
if (elen >= sizeof(*elems->max_idle_period_ie))
|
||||||
elems->max_idle_period_ie = (void *)pos;
|
elems->max_idle_period_ie = (void *)pos;
|
||||||
break;
|
break;
|
||||||
|
case WLAN_EID_RSNX:
|
||||||
|
elems->rsnx = pos;
|
||||||
|
elems->rsnx_len = elen;
|
||||||
|
break;
|
||||||
case WLAN_EID_EXTENSION:
|
case WLAN_EID_EXTENSION:
|
||||||
ieee80211_parse_extension_element(calc_crc ?
|
ieee80211_parse_extension_element(calc_crc ?
|
||||||
&crc : NULL,
|
&crc : NULL,
|
||||||
|
|
Loading…
Reference in New Issue