summaryrefslogtreecommitdiffstats
path: root/usr/local/www/vpn_openvpn_server.php
diff options
context:
space:
mode:
Diffstat (limited to 'usr/local/www/vpn_openvpn_server.php')
-rw-r--r--usr/local/www/vpn_openvpn_server.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/usr/local/www/vpn_openvpn_server.php b/usr/local/www/vpn_openvpn_server.php
index 4b47b3c..90e2b47 100644
--- a/usr/local/www/vpn_openvpn_server.php
+++ b/usr/local/www/vpn_openvpn_server.php
@@ -61,8 +61,9 @@ foreach ($a_crl as $cid => $acrl)
if (!isset($acrl['refid']))
unset ($a_crl[$cid]);
-$id = $_GET['id'];
-if (isset($_POST['id']))
+if (is_numericint($_GET['id']))
+ $id = $_GET['id'];
+if (isset($_POST['id']) && is_numericint($_POST['id']))
$id = $_POST['id'];
$act = $_GET['act'];
@@ -1672,7 +1673,7 @@ if ($savemsg)
<input name="save" type="submit" class="formbtn" value="<?=gettext("Save"); ?>"/>
<input name="act" type="hidden" value="<?=$act;?>"/>
<?php if (isset($id) && $a_server[$id]): ?>
- <input name="id" type="hidden" value="<?=$id;?>">
+ <input name="id" type="hidden" value="<?=htmlspecialchars($id);?>">
<?php endif; ?>
</td>
</tr>
OpenPOWER on IntegriCloud