소스 검색

qcacld-3.0: Do not create preauth node while sending SAE assoc reject

Driver validates the authentication context and allows
connection with SAE AKM in either of the below cases,
1. Successful SAE authentication
2. Open authentication with a valid PMKID

Driver rejects association if none of these are met. Do not
create preauth node while sending assoc reject in these cases
as there is no need to maintain a preauth context. Stations
initiate a fresh SAE authentication in both of these cases and
a new node will be created.

Change-Id: Ic446add47358d01bf4b316aa9ac5bf86c33bf812
CRs-Fixed: 2396379
Srinivas Dasari 6 년 전
부모
커밋
397ae4058f
1개의 변경된 파일8개의 추가작업 그리고 1개의 파일을 삭제
  1. 8 1
      core/mac/src/pe/lim/lim_process_sme_req_messages.c

+ 8 - 1
core/mac/src/pe/lim/lim_process_sme_req_messages.c

@@ -3112,6 +3112,7 @@ void __lim_process_sme_assoc_cnf_new(struct mac_context *mac_ctx, uint32_t msg_t
 					session_entry);
 		goto end;
 	} else {
+		uint8_t add_pre_auth_context = true;
 		/*
 		 * SME_ASSOC_CNF status is non-success, so STA is not allowed
 		 * to be associated since the HAL sta entry is created for
@@ -3128,9 +3129,15 @@ void __lim_process_sme_assoc_cnf_new(struct mac_context *mac_ctx, uint32_t msg_t
 			 assoc_cnf.mac_status_code);
 		if (assoc_cnf.mac_status_code)
 			mac_status_code = assoc_cnf.mac_status_code;
+		if (assoc_cnf.mac_status_code == eSIR_MAC_INVALID_PMKID ||
+		    assoc_cnf.mac_status_code ==
+			eSIR_MAC_AUTH_ALGO_NOT_SUPPORTED_STATUS)
+			add_pre_auth_context = false;
+
 		lim_reject_association(mac_ctx, sta_ds->staAddr,
 				       sta_ds->mlmStaContext.subType,
-				       true, sta_ds->mlmStaContext.authType,
+				       add_pre_auth_context,
+				       sta_ds->mlmStaContext.authType,
 				       sta_ds->assocId, true,
 				       mac_status_code,
 				       session_entry);