]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
Show [UTF-8] flag if the SSID is reported as UTF-8
authorJouke Witteveen <j.witteveen@gmail.com>
Mon, 25 Jun 2018 20:24:15 +0000 (22:24 +0200)
committerJouni Malinen <j@w1.fi>
Wed, 2 Jan 2019 15:58:05 +0000 (17:58 +0200)
Signed-off-by: Jouke Witteveen <j.witteveen@gmail.com>
wpa_supplicant/ctrl_iface.c

index 936cf3144fe2dc0ec23313ca331bc755f2ad8caf..4964c62173316fe8fe58e23673d96ecab91182c0 100644 (file)
@@ -2913,6 +2913,13 @@ static int wpa_supplicant_ctrl_iface_scan_result(
                pos += ret;
        }
 #endif /* CONFIG_FST */
+       ie = wpa_bss_get_ie(bss, WLAN_EID_EXT_CAPAB);
+       if (ie && ie[1] >= 7 && ie[8] & BIT(0)) { /* Bit 48 - UTF-8 SSID */
+               ret = os_snprintf(pos, end - pos, "[UTF-8]");
+               if (os_snprintf_error(end - pos, ret))
+                       return -1;
+               pos += ret;
+       }
 
        ret = os_snprintf(pos, end - pos, "\t%s",
                          wpa_ssid_txt(bss->ssid, bss->ssid_len));