]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
nl80211: Check 4-way handshake offload support
authorEliad Peller <eliad@wizery.com>
Sun, 28 Jan 2018 12:45:33 +0000 (14:45 +0200)
committerJouni Malinen <j@w1.fi>
Sat, 17 Feb 2018 16:31:05 +0000 (18:31 +0200)
Set the WPA_DRIVER_FLAGS_4WAY_HANDSHAKE flag if the driver indicates
both 4-way handshake PSK and 802.1X support. Currently wpa_supplicant
doesn't distinguish between 4-way handshake for 802.1X and PSK, but
nl80211 API has different capabilities for each one.

Signed-off-by: Eliad Peller <eliadx.peller@intel.com>
Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
src/drivers/driver_nl80211_capa.c

index f11a1d70e6e17f3748078b185a0805d981d5dad1..fd8b457b836de376e1765380f248d56a3fdac875 100644 (file)
@@ -401,6 +401,12 @@ static void wiphy_info_ext_feature_flags(struct wiphy_info_data *info,
        if (ext_feature_isset(ext_features, len,
                              NL80211_EXT_FEATURE_FILS_SK_OFFLOAD))
                capa->flags |= WPA_DRIVER_FLAGS_FILS_SK_OFFLOAD;
+
+       if (ext_feature_isset(ext_features, len,
+                             NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_PSK) &&
+           ext_feature_isset(ext_features, len,
+                             NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X))
+               capa->flags |= WPA_DRIVER_FLAGS_4WAY_HANDSHAKE;
 }