summaryrefslogtreecommitdiffstats
path: root/modules-available/serversetup-bwlp-ipxe/api.inc.php
diff options
context:
space:
mode:
authorSimon Rettberg2020-07-30 17:21:29 +0200
committerSimon Rettberg2020-07-30 17:21:29 +0200
commit71fe655d73db79fa03e17e8e414568c8ea0f5842 (patch)
tree13398be8bbdc9942461419c32eda5fda1b397c95 /modules-available/serversetup-bwlp-ipxe/api.inc.php
parent[exams] More sanity checks regarding date/time and locations (diff)
downloadslx-admin-71fe655d73db79fa03e17e8e414568c8ea0f5842.tar.gz
slx-admin-71fe655d73db79fa03e17e8e414568c8ea0f5842.tar.xz
slx-admin-71fe655d73db79fa03e17e8e414568c8ea0f5842.zip
[serversetup-bwlp-ipxe/statistics] Sanitize strings from clients
Some string from the clients might not be well suited for utf-8 representation. Add wrapper functions that clean utf-8 strings, or convert ANSI strings to UTF-8 while removing problematic chars.
Diffstat (limited to 'modules-available/serversetup-bwlp-ipxe/api.inc.php')
-rw-r--r--modules-available/serversetup-bwlp-ipxe/api.inc.php1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules-available/serversetup-bwlp-ipxe/api.inc.php b/modules-available/serversetup-bwlp-ipxe/api.inc.php
index c3804a03..7dc03e11 100644
--- a/modules-available/serversetup-bwlp-ipxe/api.inc.php
+++ b/modules-available/serversetup-bwlp-ipxe/api.inc.php
@@ -113,6 +113,7 @@ if ($model === false) {
$model .= " ($manuf)";
}
}
+ $model = Util::ansiToUtf8($model); // Some SMBIOSes contain corrupt/bogus strings
}
// Query
if ($model !== false) {