From 634eb7276092612bb5a8841da9a37358b1aea6f8 Mon Sep 17 00:00:00 2001 From: zbchristian <33725910+zbchristian@users.noreply.github.com> Date: Wed, 18 Aug 2021 21:57:30 +0200 Subject: [PATCH] Convert non ASCII ssid for display to utf8 Convert hex bytes to binary. Assumes utf8 encoding --- includes/wifi_functions.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/includes/wifi_functions.php b/includes/wifi_functions.php index 978fb50c..3f13738a 100755 --- a/includes/wifi_functions.php +++ b/includes/wifi_functions.php @@ -190,3 +190,12 @@ function reinitializeWPA($force) return $result; } +/* + * Replace escaped bytes (hex) by binary - assume UTF8 encoding + * + * @param string $ssid + */ +function ssid2utf8($ssid) { + return evalHexSequence($ssid); +} +