diff options
author | Vinita S. Maloo <vmaloo@codeaurora.org> | 2020-07-29 01:56:22 +0000 |
---|---|---|
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | 2020-07-29 01:56:22 +0000 |
commit | cf7b49ba14d68aced911f3a42a2e87fe86bd32a9 (patch) | |
tree | f625b9948aa534ad3e35f914d959ef8fb72fad3e | |
parent | 20ebcddc36e67ba5147dccab40c56e48a10d25f9 (diff) | |
parent | fb3a444d74031cb5c27121bd2a3b04ec771026c4 (diff) | |
download | wpa_supplicant_8-cf7b49ba14d68aced911f3a42a2e87fe86bd32a9.tar.gz |
FILS: Use FILS auth alg when connecting using PMKSA caching am: fb3a444d74
Original change: https://googleplex-android-review.googlesource.com/c/platform/external/wpa_supplicant_8/+/11990403
Change-Id: I25a1ff69da10495c6f49f342043e39a0e23c8f16
-rw-r--r-- | wpa_supplicant/wpa_supplicant.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/wpa_supplicant/wpa_supplicant.c b/wpa_supplicant/wpa_supplicant.c index 6f446134..78910fc4 100644 --- a/wpa_supplicant/wpa_supplicant.c +++ b/wpa_supplicant/wpa_supplicant.c @@ -2742,9 +2742,9 @@ static u8 * wpas_populate_assoc_ies( #ifdef CONFIG_MBO const u8 *mbo_ie; #endif -#ifdef CONFIG_SAE - int sae_pmksa_cached = 0; -#endif /* CONFIG_SAE */ +#if defined(CONFIG_SAE) || defined(CONFIG_FILS) + int pmksa_cached = 0; +#endif /* CONFIG_SAE || CONFIG_FILS */ #ifdef CONFIG_FILS const u8 *realm, *username, *rrk; size_t realm_len, username_len, rrk_len; @@ -2784,9 +2784,9 @@ static u8 * wpas_populate_assoc_ies( ssid, try_opportunistic, cache_id, 0) == 0) { eapol_sm_notify_pmkid_attempt(wpa_s->eapol); -#ifdef CONFIG_SAE - sae_pmksa_cached = 1; -#endif /* CONFIG_SAE */ +#if defined(CONFIG_SAE) || defined(CONFIG_FILS) + pmksa_cached = 1; +#endif /* CONFIG_SAE || CONFIG_FILS */ } wpa_ie_len = max_wpa_ie_len; if (wpa_supplicant_set_suites(wpa_s, bss, ssid, @@ -2885,6 +2885,10 @@ static u8 * wpas_populate_assoc_ies( if (mask) *mask |= WPA_DRV_UPDATE_FILS_ERP_INFO; + } else if ((wpa_s->drv_flags & WPA_DRIVER_FLAGS_FILS_SK_OFFLOAD) && + ssid->eap.erp && wpa_key_mgmt_fils(wpa_s->key_mgmt) && + pmksa_cached) { + algs = WPA_AUTH_ALG_FILS; } #endif /* CONFIG_FILS */ #endif /* IEEE8021X_EAPOL */ @@ -2901,7 +2905,7 @@ static u8 * wpas_populate_assoc_ies( } #ifdef CONFIG_SAE - if (sae_pmksa_cached && algs == WPA_AUTH_ALG_SAE) { + if (pmksa_cached && algs == WPA_AUTH_ALG_SAE) { wpa_dbg(wpa_s, MSG_DEBUG, "SAE: Use WPA_AUTH_ALG_OPEN for PMKSA caching attempt"); algs = WPA_AUTH_ALG_OPEN; |