diff options
author | Niraj Kumar Goit <niraj.g@samsung.com> | 2019-05-30 16:13:20 +0530 |
---|---|---|
committer | Nishant Chaprana <n.chaprana@samsung.com> | 2019-06-19 12:50:20 +0530 |
commit | a48fa9fdffe415e9a6f703776b5db795e242ac23 (patch) | |
tree | 3d123bfc10ab773961cc8df5dfd3d3e74b7319f1 /src | |
parent | 85bcbd4afa2fee27400b4efc67000a1ea7a71973 (diff) | |
download | connman-a48fa9fdffe415e9a6f703776b5db795e242ac23.tar.gz connman-a48fa9fdffe415e9a6f703776b5db795e242ac23.tar.bz2 connman-a48fa9fdffe415e9a6f703776b5db795e242ac23.zip |
Added support of WPA3-SAE security mode.submit/tizen/20190621.094817accepted/tizen/unified/20190624.075215
Change-Id: I8612c52dc0cc078459fa19aa8a639597f070b293
Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/config.c | 1 | ||||
-rw-r--r-- | src/service.c | 17 |
2 files changed, 18 insertions, 0 deletions
diff --git a/src/config.c b/src/config.c index 11f0bd84..d4ba0b37 100644 --- a/src/config.c +++ b/src/config.c @@ -742,6 +742,7 @@ static bool load_service(GKeyFile *keyfile, const char *group, if (security == CONNMAN_SERVICE_SECURITY_PSK || #if defined TIZEN_EXT security == CONNMAN_SERVICE_SECURITY_RSN || + security == CONNMAN_SERVICE_SECURITY_SAE || #endif security == CONNMAN_SERVICE_SECURITY_WEP) { service->security = security; diff --git a/src/service.c b/src/service.c index 2fd1e50e..d1ada486 100644 --- a/src/service.c +++ b/src/service.c @@ -350,6 +350,8 @@ enum connman_service_security __connman_service_string2security(const char *str) #if defined TIZEN_EXT if (!strcmp(str, "rsn")) return CONNMAN_SERVICE_SECURITY_RSN; + if (!strcmp(str, "sae")) + return CONNMAN_SERVICE_SECURITY_SAE; #endif return CONNMAN_SERVICE_SECURITY_UNKNOWN; @@ -370,6 +372,8 @@ static const char *security2string(enum connman_service_security security) return "psk"; case CONNMAN_SERVICE_SECURITY_RSN: return "rsn"; + case CONNMAN_SERVICE_SECURITY_SAE: + return "sae"; #else case CONNMAN_SERVICE_SECURITY_RSN: return "psk"; @@ -2388,6 +2392,9 @@ static void append_security(DBusMessageIter *iter, void *user_data) case CONNMAN_SERVICE_SECURITY_PSK: case CONNMAN_SERVICE_SECURITY_WPA: case CONNMAN_SERVICE_SECURITY_RSN: +#if defined TIZEN_EXT + case CONNMAN_SERVICE_SECURITY_SAE: +#endif str = "wps"; dbus_message_iter_append_basic(iter, DBUS_TYPE_STRING, &str); @@ -4143,6 +4150,8 @@ int __connman_service_check_passphrase(enum connman_service_security security, case CONNMAN_SERVICE_SECURITY_PSK: #if defined TIZEN_EXT case CONNMAN_SERVICE_SECURITY_RSN: + /* TO CHECK: We need to check the key length supported by SAE */ + case CONNMAN_SERVICE_SECURITY_SAE: #endif /* A raw key is always 64 bytes length, * its content is in hex representation. @@ -8207,6 +8216,9 @@ static int service_connect(struct connman_service *service) case CONNMAN_SERVICE_SECURITY_PSK: case CONNMAN_SERVICE_SECURITY_WPA: case CONNMAN_SERVICE_SECURITY_RSN: +#if defined TIZEN_EXT + case CONNMAN_SERVICE_SECURITY_SAE: +#endif if (service->error == CONNMAN_SERVICE_ERROR_INVALID_KEY) return -ENOKEY; @@ -8277,6 +8289,9 @@ static int service_connect(struct connman_service *service) case CONNMAN_SERVICE_SECURITY_PSK: case CONNMAN_SERVICE_SECURITY_WPA: case CONNMAN_SERVICE_SECURITY_RSN: +#if defined TIZEN_EXT + case CONNMAN_SERVICE_SECURITY_SAE: +#endif break; case CONNMAN_SERVICE_SECURITY_8021X: prepare_8021x(service); @@ -9028,6 +9043,8 @@ static enum connman_service_security convert_wifi_security(const char *security) else if (g_str_equal(security, "rsn")) return CONNMAN_SERVICE_SECURITY_RSN; #if defined TIZEN_EXT + else if (g_str_equal(security, "sae")) + return CONNMAN_SERVICE_SECURITY_SAE; else if (g_str_equal(security, "ft_psk") == TRUE) return CONNMAN_SERVICE_SECURITY_PSK; else if (g_str_equal(security, "ft_ieee8021x") == TRUE) |