]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
Do not derive SAE PT if the network profile does not include SAE
authorHu Wang <quic_huw@quicinc.com>
Wed, 5 Jun 2024 05:21:02 +0000 (22:21 -0700)
committerJouni Malinen <j@w1.fi>
Thu, 11 Jul 2024 14:39:19 +0000 (17:39 +0300)
wpa_s_setup_sae_pt() derived SAE PT even when the configured key
management options did not include SAE if the global sae_pwe
configuration parameter had been changed to enable H2E. This adds
unnecessary extra delay, so derive PT only if SAE is actually enabled in
the network profile.

Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
wpa_supplicant/wpa_supplicant.c

index 6df13739b5015aa72eed0b5aa8b813bc8b0267fe..3689f203dfdb3c0e43df4ae13961a9eeee5a62fa 100644 (file)
@@ -2424,6 +2424,7 @@ void wpa_s_setup_sae_pt(struct wpa_config *conf, struct wpa_ssid *ssid,
                password = ssid->passphrase;
 
        if (!password ||
+           !wpa_key_mgmt_sae(ssid->key_mgmt) ||
            (conf->sae_pwe == SAE_PWE_HUNT_AND_PECK && !ssid->sae_password_id &&
             !wpa_key_mgmt_sae_ext_key(ssid->key_mgmt) &&
             !force &&