Skip to contentSkip to conversation

wifi: wilc1000: fix for absent RSN capabilities WFA testcase

PATCH In review [email protected] 2 participants 3 messages Apr 21, 2023 – May 11, 2023 Microchip WILC1000 wifi driver

lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 wifi: wilc1000: fix for absent RSN capabilities WFA testcase

From: Amisha Patel <[email protected]>

Mandatory WFA testcase CT_Security_WPA2Personal_STA_RSNEBoundsVerification-AbsentRSNCap, performs bounds verfication on Beacon and/or Probe response frames. It failed and observed the reason to be absence of cipher suite and AKM suite in RSN information. To fix this, enable the RSN flag before extracting RSN capabilities.

Fixes cd21d99e595e :"wifi: wilc1000: validate pairwise and authentication suite offsets")

---
v3 - fixed From field as per review

v2 - modified commit log based on review

---
 drivers/net/wireless/microchip/wilc1000/hif.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/net/wireless/microchip/wilc1000/hif.c +4 -4
index 5adc69d5bcae..a28da5938481 100644
@@ -485,6 +485,9 @@ void *wilc_parse_join_bss_param(struct cfg80211_bss *bss,
 		int rsn_ie_len = sizeof(struct element) + rsn_ie[1];
 		int offset = 8;
 
+		param->mode_802_11i = 2;
+		param->rsn_found = true;
+
 		/* extract RSN capabilities */
 		if (offset < rsn_ie_len) {
 			/* skip over pairwise suites */
@@ -494,11 +497,8 @@ void *wilc_parse_join_bss_param(struct cfg80211_bss *bss,
 				/* skip over authentication suites */
 				offset += (rsn_ie[offset] * 4) + 2;
 
-				if (offset + 1 < rsn_ie_len) {
-					param->mode_802_11i = 2;
-					param->rsn_found = true;
+				if (offset + 1 < rsn_ie_len)
 					memcpy(param->rsn_cap, &rsn_ie[offset], 2);
-				}
 			}
 		}
 	}
Signature · 1 line
2.25.1
#1 lore raw
Quoted 11 lines · <[email protected]> wrote:

From: Amisha Patel <[email protected]>

Mandatory WFA testcase CT_Security_WPA2Personal_STA_RSNEBoundsVerification-AbsentRSNCap, performs bounds verfication on Beacon and/or Probe response frames. It failed and observed the reason to be absence of cipher suite and AKM suite in RSN information. To fix this, enable the RSN flag before extracting RSN capabilities.

Fixes cd21d99e595e :"wifi: wilc1000: validate pairwise and authentication suite offsets")

The fixes tag is wrong, should be:

Fixes cd21d99e595e ("wifi: wilc1000: validate pairwise and authentication suite offsets")

I can fix that, no need to resend because of this.

Signature · 3 lines
https://patchwork.kernel.org/project/linux-wireless/patch/[email protected]/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
#2 lore raw
In reply to [email protected]
Quoted 11 lines · <[email protected]> wrote:

From: Amisha Patel <[email protected]>

Mandatory WFA testcase CT_Security_WPA2Personal_STA_RSNEBoundsVerification-AbsentRSNCap, performs bounds verfication on Beacon and/or Probe response frames. It failed and observed the reason to be absence of cipher suite and AKM suite in RSN information. To fix this, enable the RSN flag before extracting RSN capabilities.

Fixes cd21d99e595e ("wifi: wilc1000: validate pairwise and authentication suite offsets")

Patch applied to wireless-next.git, thanks.

9ce4bb09123e wifi: wilc1000: fix for absent RSN capabilities WFA testcase

Signature · 3 lines
https://patchwork.kernel.org/project/linux-wireless/patch/[email protected]/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches