]> git.entuzijast.net Git - freeradius-dialup-admin.git/commitdiff
Correctly check nas validity in nas_admin.php3. Bug noted by Nick Bright
authorkkalev <kkalev>
Mon, 14 Mar 2005 11:57:34 +0000 (11:57 +0000)
committerkkalev <kkalev>
Mon, 14 Mar 2005 11:57:34 +0000 (11:57 +0000)
Changelog
htdocs/nas_admin.php3

index a06dc5dfa45071a99c3436c739debd6dc09ba423..95ca0de27fd6aee892061021abd63255a49af791 100644 (file)
--- a/Changelog
+++ b/Changelog
@@ -27,6 +27,7 @@ Ver 1.78:
 * Show the correct nas type in nas_admin. Bug noted by Nick Bright
 * Correctly calculate the nas ip in lib/sql/nas_list.php3. Add a check_ip() function in lib/functions.php3
   Bug noted by Nick Bright
+* Correctly check nas validity in nas_admin.php3. Bug noted by Nick Bright
 Ver 1.75:
 * A LOT of security related fixes. Now dialupadmin should hopefully be secure enough to
   be accessed by normal users (not administrators).
index 9390198c5f25cb089ede3f54a85fa09630fef448..f2bb7f07f1bbfdfd962ea7573fc035d4e3900b7f 100644 (file)
@@ -45,7 +45,7 @@ if ($link){
                $selected_nas = da_sql_escape_string($selected_nas);
                switch ($action) {
                        case 'check_nas':
-                               if ($selected_nas == gethostbyname($selected_nas))
+                               if (!check_ip($selected_nas) && $selected_nas == gethostbyname($selected_nas))
                                        $msg = "<b>The NAS name <font color=red>is not</font> valid</b><br>\n";
                                else
                                        $msg = "<b>The NAS name <font color=green>is</font> valid</b><br>\n";