From aa314146cac3382cc1c7fc28c93296f70e7c9682 Mon Sep 17 00:00:00 2001 From: Renato Botelho Date: Tue, 24 Feb 2015 16:08:19 -0300 Subject: When RADIUS auth is selected, radius protocol and server ip/host are mandatory. Fixes #4384 --- usr/local/www/services_captiveportal.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/usr/local/www/services_captiveportal.php b/usr/local/www/services_captiveportal.php index 41a9042..a56a6fc 100644 --- a/usr/local/www/services_captiveportal.php +++ b/usr/local/www/services_captiveportal.php @@ -210,6 +210,13 @@ if ($_POST) { $reqdfields = explode(" ", "zone cinterface"); $reqdfieldsn = array(gettext("Zone name"), gettext("Interface")); + if (isset($_POST['auth_method']) && $_POST['auth_method'] == "radius") { + $reqdfields[] = "radius_protocol"; + $reqdfieldsn[] = gettext("RADIUS Protocol"); + $reqdfields[] = "radiusip"; + $reqdfieldsn[] = gettext("Primary RADIUS server IP address"); + } + do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors); /* make sure no interfaces are bridged or used on other zones */ -- cgit v1.1