From 4d187fa0f2706358cb5648352e89f54f763ea1ba Mon Sep 17 00:00:00 2001 From: Utkarsh Bhatnagar Date: Fri, 1 May 2020 16:26:11 +0530 Subject: [PATCH] qcacld-3.0: Consider self capability in RSN caps RSN caps are anded with AP RSN caps, but it should be self caps. Due to this even when PMF required is configured in self capability while connecting to non pmf required AP, self cap doesnt include self capability of pmf required. So do not and RSN's self caps with AP's caps Change-Id: Iae84486e13859fc8deb342d7b774129dc26ae323 CRs-Fixed: 2676337 --- core/sme/src/csr/csr_util.c | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) diff --git a/core/sme/src/csr/csr_util.c b/core/sme/src/csr/csr_util.c index 69a7fbdcb4ca..046cdb05d369 100644 --- a/core/sme/src/csr/csr_util.c +++ b/core/sme/src/csr/csr_util.c @@ -2812,35 +2812,16 @@ uint8_t csr_construct_rsn_ie(struct mac_context *mac, uint32_t sessionId, uint8_t *rsn_ie_end = NULL; uint8_t *rsn_ie = (uint8_t *)pRSNIe; uint8_t ie_len = 0; - tDot11fBeaconIEs *local_ap_ie = ap_ie; - uint16_t rsn_cap = 0; struct wlan_crypto_pmksa pmksa, *pmksa_peer; struct csr_roam_session *session = &mac->roam.roamSession[sessionId]; - if (!local_ap_ie && - (!QDF_IS_STATUS_SUCCESS(csr_get_parsed_bss_description_ies - (mac, pSirBssDesc, &local_ap_ie)))) - return ie_len; - - /* get AP RSN cap */ - qdf_mem_copy(&rsn_cap, local_ap_ie->RSN.RSN_Cap, sizeof(rsn_cap)); - if (!ap_ie && local_ap_ie) - /* locally allocated */ - qdf_mem_free(local_ap_ie); - vdev = wlan_objmgr_get_vdev_by_id_from_psoc(mac->psoc, sessionId, WLAN_LEGACY_SME_ID); if (!vdev) { sme_err("Invalid vdev"); return ie_len; } - /* - * Use intersection of the RSN cap sent by user space and - * the AP, so that only common capability are enabled. - */ - rsn_cap &= (uint16_t)wlan_crypto_get_param(vdev, - WLAN_CRYPTO_PARAM_RSN_CAP); - wlan_crypto_set_vdev_param(vdev, WLAN_CRYPTO_PARAM_RSN_CAP, rsn_cap); + qdf_mem_zero(&pmksa, sizeof(pmksa)); if (pSirBssDesc->fils_info_element.is_cache_id_present) { pmksa.ssid_len =