Revert "qcacld-3.0: Save previous auth algo in pe session"

This reverts commit 7cf307e148
as the check to drop auth frame if previous sequence number
and auth algo match with current sequence number and auth
algo returns true instead of false in a correct scenario.

Change-Id: I8dee272f535acaadb9dfff69ee9ce68ddea4eec1
CRs-Fixed: 2166125
This commit is contained in:
Yeshwanth Sriram Guntuka 2018-01-03 11:25:36 +05:30 • committed by snandini
commit 72a2fb2513
3 changed files with 12 additions and 18 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2012-2017 The Linux Foundation. All rights reserved.
* Copyright (c) 2012-2018 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@ -528,8 +528,6 @@ typedef struct sPESession /* Added to Support BT-AMP */
#endif
/* previous auth frame's sequence number */
uint16_t prev_auth_seq_num;
/* previous auth algo */
uint16_t prev_auth_algo;
} tPESession, *tpPESession;
/*-------------------------------------------------------------------------

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011-2017 The Linux Foundation. All rights reserved.
* Copyright (c) 2011-2018 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@ -1096,6 +1096,15 @@ lim_process_auth_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
pe_session->limMlmState, MAC_ADDR_ARRAY(mac_hdr->bssId),
(uint) abs((int8_t) WMA_GET_RX_RSSI_NORMALIZED(rx_pkt_info)));
if (pe_session->prev_auth_seq_num == curr_seq_num) {
pe_err("auth frame, seq num: %d is already processed, drop it",
curr_seq_num);
return;
}
/* save seq number in pe_session */
pe_session->prev_auth_seq_num = curr_seq_num;
body_ptr = WMA_GET_RX_MPDU_DATA(rx_pkt_info);
/* Restore default failure timeout */
@ -1335,18 +1344,6 @@ lim_process_auth_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
goto free;
}
if (pe_session->prev_auth_seq_num == curr_seq_num &&
pe_session->prev_auth_algo == rx_auth_frame->authAlgoNumber) {
pe_err("auth frame, seq num: %d is already processed, drop it",
curr_seq_num);
goto free;
}
/* save seq number in pe_session */
pe_session->prev_auth_seq_num = curr_seq_num;
pe_session->prev_auth_algo = rx_auth_frame->authAlgoNumber;
rx_auth_frm_body = rx_auth_frame;
pe_debug("Received Auth frame with type: %d seqnum: %d status: %d %d",

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011-2017 The Linux Foundation. All rights reserved.
* Copyright (c) 2011-2018 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@ -541,7 +541,6 @@ pe_create_session(tpAniSirGlobal pMac, uint8_t *bssid, uint8_t *sessionId,
session_ptr->ht_client_cnt = 0;
/* following is invalid value since seq number is 12 bit */
session_ptr->prev_auth_seq_num = 0xFFFF;
session_ptr->prev_auth_algo = 0xFFFF;
return &pMac->lim.gpSession[i];
}