Explorar el Código

qcacld-3.0: Fix IE offset while checking OWE transition mode

In OWE transition mode, the beacon from the transition mode AP
should be dropped after sending unicast probe to avoid kernel
entry for BSS with null ssid. But while parsing the IE, the
frame pointer passed points to the fixed fields.

So pass the ssid IE pointer to the OWE transition mode IE
parsing API.

Change-Id: I668bc2dfc32a5a23b44da50ac81bac98250faa2a
CRs-Fixed: 2814173
Pragaspathi Thilagaraj hace 4 años
padre
commit
4120a198cb
Se han modificado 1 ficheros con 9 adiciones y 4 borrados
  1. 9 4
      core/mac/src/pe/lim/lim_process_beacon_frame.c

+ 9 - 4
core/mac/src/pe/lim/lim_process_beacon_frame.c

@@ -60,6 +60,7 @@ lim_process_beacon_frame(struct mac_context *mac_ctx, uint8_t *rx_pkt_info,
 	tpSirMacMgmtHdr mac_hdr;
 	tSchBeaconStruct *bcn_ptr;
 	uint8_t *frame;
+	const uint8_t *owe_transition_ie;
 	uint16_t frame_len;
 
 	mac_ctx->lim.gLimNumBeaconsRcvd++;
@@ -118,11 +119,15 @@ lim_process_beacon_frame(struct mac_context *mac_ctx, uint8_t *rx_pkt_info,
 
 	if (session->limMlmState ==
 			eLIM_MLM_WT_JOIN_BEACON_STATE) {
+		owe_transition_ie = wlan_get_vendor_ie_ptr_from_oui(
+					OWE_TRANSITION_OUI_TYPE,
+					OWE_TRANSITION_OUI_SIZE,
+					frame + SIR_MAC_B_PR_SSID_OFFSET,
+					frame_len - SIR_MAC_B_PR_SSID_OFFSET);
 		if (session->connected_akm == ANI_AKM_TYPE_OWE &&
-		    wlan_get_vendor_ie_ptr_from_oui(OWE_TRANSITION_OUI_TYPE,
-						    OWE_TRANSITION_OUI_SIZE,
-						    frame, frame_len)) {
-			pe_debug("Drop OWE rx beacon. Wait for probe for join success");
+		    owe_transition_ie) {
+			pe_debug("vdev:%d Drop OWE rx beacon. Wait for probe for join success",
+				 session->vdev_id);
 			qdf_mem_free(bcn_ptr);
 			return;
 		}