[PATCH 1/2] BSS: permit falling back to RSNOE for MLO
Benjamin Berg
benjamin at sipsolutions.net
Thu Jul 31 03:56:20 PDT 2025
From: Benjamin Berg <benjamin.berg at intel.com>
On the one hand, the WPA3 specification says that with MLO one should
use the RSNO2E. At the same time, in the Wi-Fi Alliance Forward
Compatibility tests 5.2.3.x the station is expected to do a fallback in
case none of the ciphers are supported.
Change the logic to allow a fallback to the RSN Override Element (RSNOE)
for MLO. Still left is the logic to check that an RSNX Override Element
is present in this case.
Signed-off-by: Benjamin Berg <benjamin.berg at intel.com>
---
wpa_supplicant/bss.c | 29 +++++++++++++++++------------
1 file changed, 17 insertions(+), 12 deletions(-)
diff --git a/wpa_supplicant/bss.c b/wpa_supplicant/bss.c
index 58adaf7449..c679688108 100644
--- a/wpa_supplicant/bss.c
+++ b/wpa_supplicant/bss.c
@@ -2244,31 +2244,36 @@ const u8 * wpa_bss_get_rsne(struct wpa_supplicant *wpa_s,
bool mlo)
{
#ifndef CONFIG_NO_WPA
- const u8 *ie;
-
if (wpas_rsn_overriding(wpa_s, ssid)) {
+ const u8 *ie;
+
if (!ssid)
ssid = wpa_s->current_ssid;
/* MLO cases for RSN overriding are required to use RSNE
- * Override 2 element and RSNXE Override element together. */
+ * Override 2 element and RSNXE Override element together.
+ * However, we are also expected to do a fallback, so for MLO,
+ * accept either Override if the RSNXE override is present.
+ */
ie = wpa_bss_get_vendor_ie(bss, RSNE_OVERRIDE_2_IE_VENDOR_TYPE);
+ if (!ie || !wpa_bss_supported_rsne(wpa_s, ssid, ie)) {
+ ie = wpa_bss_get_vendor_ie(bss,
+ RSNE_OVERRIDE_IE_VENDOR_TYPE);
+ if (!ie || !wpa_bss_supported_rsne(wpa_s, ssid, ie))
+ ie = NULL;
+ }
+
if (mlo && ie &&
!wpa_bss_get_vendor_ie(bss,
RSNXE_OVERRIDE_IE_VENDOR_TYPE)) {
wpa_printf(MSG_DEBUG, "BSS " MACSTR
- " advertises RSNE Override 2 element without RSNXE Override element - ignore RSNE Override 2 element for MLO",
+ " has no RSNX Override Element - ignore RSN Override for MLO",
MAC2STR(bss->bssid));
- } else if (ie && wpa_bss_supported_rsne(wpa_s, ssid, ie)) {
- return ie;
+ ie = NULL;
}
- if (!mlo) {
- ie = wpa_bss_get_vendor_ie(
- bss, RSNE_OVERRIDE_IE_VENDOR_TYPE);
- if (ie && wpa_bss_supported_rsne(wpa_s, ssid, ie))
- return ie;
- }
+ if (ie)
+ return ie;
}
#endif /* CONFIG_NO_WPA */
--
2.50.1
More information about the Hostap
mailing list