From: Niraj Kumar Goit Date: Mon, 23 Aug 2021 15:26:26 +0000 (+0530) Subject: Add SAE security type for netlink scan. X-Git-Tag: submit/tizen/20210908.150016^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7ff53e1bdcdf6726eb564272c4467bbf4054439d;p=platform%2Fcore%2Fconnectivity%2Fnet-config.git Add SAE security type for netlink scan. Change-Id: I1f37d0fed1dfdbc8947f3ade2a2ed1faf32acd48 Signed-off-by: Niraj Kumar Goit --- diff --git a/packaging/net-config.spec b/packaging/net-config.spec index 42263fc..817f96f 100755 --- a/packaging/net-config.spec +++ b/packaging/net-config.spec @@ -1,7 +1,7 @@ Name: net-config Summary: TIZEN Network Configuration service Version: 1.2.10 -Release: 2 +Release: 3 Group: System/Network License: Apache-2.0 Source0: %{name}-%{version}.tar.gz diff --git a/src/wifi-netlink-scan.c b/src/wifi-netlink-scan.c index efc5523..409534a 100755 --- a/src/wifi-netlink-scan.c +++ b/src/wifi-netlink-scan.c @@ -253,7 +253,8 @@ typedef enum { WIFI_SECURITY_TYPE_WEP = 1, WIFI_SECURITY_TYPE_WPA_PSK = 2, WIFI_SECURITY_TYPE_WPA2_PSK = 3, - WIFI_SECURITY_TYPE_EAP = 4, + WIFI_SECURITY_TYPE_SAE = 4, + WIFI_SECURITY_TYPE_EAP = 5, } wifi_security_type_e; typedef enum { @@ -274,6 +275,7 @@ static void __netconfig_get_security(unsigned char *bss_element, int length, wif uint8_t *t_data; int len; __u16 count; + gboolean ieee80211_psk = false; *sec_type = WIFI_SECURITY_TYPE_NONE; *enc_type = WIFI_ENCRYPTION_TYPE_NONE; @@ -417,6 +419,10 @@ static void __netconfig_get_security(unsigned char *bss_element, int length, wif *sec_type = WIFI_SECURITY_TYPE_EAP; } else if (t_data[3] == 2 || t_data[3] == 4 || t_data[3] == 6) { // 2 : PSK, 4 : FT/PSK, 6 : PSK/SHA-256 *sec_type = WIFI_SECURITY_TYPE_WPA2_PSK; + ieee80211_psk = true; + } else if (t_data[3] == 8) { // Add SAE security type for netlink scan + if (ieee80211_psk != true) + *sec_type = WIFI_SECURITY_TYPE_SAE; } } } //for