pmk: set external flag for PMKSA entries configured from framework
Set external flag for PMKSA entries configured from framework to
wpa_supplicant to differentiate them from internally generated PMKSA
entries.
Drop externally configure PMKSA entries even without ERP keys since it
is possible for an external component to add PMKSA entries for FILS
authentication without restoring previously generated ERP keys.
external PMKSA is not valid for FILS because there is no corresponding
key.
Bug: 243092442
Test: 1. Configure AP in FILS SHA-256.
2. Connect the STA to the AP.
3. Make the device roam to the AP.
4. send auth properly and connect to AP
Change-Id: I3aef8be3bd957995415c9f18b3dbb57db5ccd60a
Signed-off-by: Sumit Agre <quic_sagre@quicinc.com>
diff --git a/wpa_supplicant/aidl/sta_network.cpp b/wpa_supplicant/aidl/sta_network.cpp
index fe4a760..feb5ec4 100644
--- a/wpa_supplicant/aidl/sta_network.cpp
+++ b/wpa_supplicant/aidl/sta_network.cpp
@@ -2142,6 +2142,7 @@
return ndk::ScopedAStatus::ok();
}
+ new_entry->external = true;
wpa_sm_pmksa_cache_add_entry(wpa_s->wpa, new_entry);
return ndk::ScopedAStatus::ok();