return 0;
}
+typedef struct {
+ int sec_type;
+ char *sec_type_str;
+} security_list_str_s;
+
+static security_list_str_s security_list_str_table[] = {
+ { WIFI_MANAGER_SECURITY_TYPE_NONE, "None" },
+ { WIFI_MANAGER_SECURITY_TYPE_WEP, "WEP" },
+ { WIFI_MANAGER_SECURITY_TYPE_WPA_PSK, "PSK" },
+ { WIFI_MANAGER_SECURITY_TYPE_WPA2_PSK, "RSN" },
+ { WIFI_MANAGER_SECURITY_TYPE_EAP, "EAP" },
+ { WIFI_MANAGER_SECURITY_TYPE_WPA_FT_PSK, "FT_PSK" },
+ { WIFI_MANAGER_SECURITY_TYPE_SAE, "SAE" },
+ { WIFI_MANAGER_SECURITY_TYPE_OWE, "OWE" },
+ { WIFI_MANAGER_SECURITY_TYPE_DPP, "DPP" },
+ { -1, "" },
+};
+
+static inline void __test_found_print_ap_security_list(wifi_manager_ap_h ap)
+{
+ bool supported = false;
+ int count = 0;
+
+ printf("Supported security types: ");
+
+ while (security_list_str_table[count].sec_type >= 0) {
+ if (WIFI_MANAGER_ERROR_NONE == wifi_manager_ap_is_security_type_supported(
+ ap, security_list_str_table[count].sec_type, &supported) &&
+ supported)
+ printf("%s ", security_list_str_table[count].sec_type_str);
+ count++;
+ }
+
+ printf("\n");
+}
+
static inline int __test_found_print_ap_security_info_cb(wifi_manager_ap_h ap)
{
bool bool_value;
else
printf("Fail to get Security type\n");
+ __test_found_print_ap_security_list(ap);
+
if (wifi_manager_ap_get_encryption_type(ap, &enc_type) == WIFI_MANAGER_ERROR_NONE)
printf("Encryption type : %d\n", enc_type);
else