aboutsummaryrefslogtreecommitdiffstats
path: root/config/openvpn-client-export
diff options
context:
space:
mode:
Diffstat (limited to 'config/openvpn-client-export')
-rwxr-xr-xconfig/openvpn-client-export/openvpn-client-export.xml2
-rwxr-xr-xconfig/openvpn-client-export/vpn_openvpn_export.php10
2 files changed, 8 insertions, 4 deletions
diff --git a/config/openvpn-client-export/openvpn-client-export.xml b/config/openvpn-client-export/openvpn-client-export.xml
index a6a46649..ee04b0cc 100755
--- a/config/openvpn-client-export/openvpn-client-export.xml
+++ b/config/openvpn-client-export/openvpn-client-export.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<packagegui>
<name>OpenVPN Client Export</name>
- <version>1.2.9</version>
+ <version>1.2.11</version>
<title>OpenVPN Client Export</title>
<include_file>/usr/local/pkg/openvpn-client-export.inc</include_file>
<backup_file></backup_file>
diff --git a/config/openvpn-client-export/vpn_openvpn_export.php b/config/openvpn-client-export/vpn_openvpn_export.php
index 8d002397..086c2a52 100755
--- a/config/openvpn-client-export/vpn_openvpn_export.php
+++ b/config/openvpn-client-export/vpn_openvpn_export.php
@@ -131,10 +131,14 @@ if (!empty($act)) {
else
$nokeys = false;
- if (empty($_GET['useaddr'])) {
+ $useaddr = '';
+ if (isset($_GET['useaddr']) && !empty($_GET['useaddr']))
+ $useaddr = trim($_GET['useaddr']);
+
+ if (!(is_ipaddr($useaddr) || is_hostname($useaddr) ||
+ in_array($useaddr, array("serveraddr", "servermagic", "servermagichost", "serverhostname"))))
$input_errors[] = "You need to specify an IP or hostname.";
- } else
- $useaddr = $_GET['useaddr'];
+
$advancedoptions = $_GET['advancedoptions'];
$openvpnmanager = $_GET['openvpnmanager'];