Merge pull request #1542 from RaspAP/sec/providers

Sanitize country POST input
This commit is contained in:
Bill Zimmerman 2024-03-08 21:20:08 +01:00 committed by GitHub
commit 95f74c560e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -50,7 +50,7 @@ function DisplayProviderConfig()
if (!RASPI_MONITOR_ENABLED) {
if (isset($_POST['SaveProviderSettings'])) {
if (isset($_POST['country'])) {
$country = trim($_POST['country']);
$country = escapeshellarg(trim($_POST['country']));
if (strlen($country) == 0) {
$status->addMessage('Select a country from the server location list', 'danger');
} else {