summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--usr/local/www/services_captiveportal_vouchers.php18
1 files changed, 9 insertions, 9 deletions
diff --git a/usr/local/www/services_captiveportal_vouchers.php b/usr/local/www/services_captiveportal_vouchers.php
index d6919f6..3462ad6 100644
--- a/usr/local/www/services_captiveportal_vouchers.php
+++ b/usr/local/www/services_captiveportal_vouchers.php
@@ -36,15 +36,6 @@
##|*MATCH=services_captiveportal_vouchers.php*
##|-PRIV
-$cpzone = $_GET['zone'];
-if (isset($_POST['zone']))
- $cpzone = $_POST['zone'];
-
-if (empty($cpzone) || empty($config['captiveportal'][$cpzone])) {
- header("Location: services_captiveportal_zones.php");
- exit;
-}
-
if ($_POST['postafterlogin'])
$nocsrf= true;
@@ -55,6 +46,15 @@ require("shaper.inc");
require("captiveportal.inc");
require_once("voucher.inc");
+$cpzone = $_GET['zone'];
+if (isset($_POST['zone']))
+ $cpzone = $_POST['zone'];
+
+if (empty($cpzone) || empty($config['captiveportal'][$cpzone])) {
+ header("Location: services_captiveportal_zones.php");
+ exit;
+}
+
if($_REQUEST['generatekey']) {
exec("/usr/local/bin/openssl genrsa 64 > /tmp/key64.private");
exec("/usr/local/bin/openssl rsa -pubout < /tmp/key64.private > /tmp/key64.public");
OpenPOWER on IntegriCloud