Add a per nas finger_type directive
authorkkalev <kkalev>
Thu, 13 Feb 2003 21:23:16 +0000 (21:23 +0000)
committerkkalev <kkalev>
Thu, 13 Feb 2003 21:23:16 +0000 (21:23 +0000)
dialup_admin/Changelog
dialup_admin/conf/admin.conf
dialup_admin/htdocs/user_finger.php3

index 0f79fcd..c74d47d 100644 (file)
@@ -11,6 +11,7 @@ Ver 1.63:
 * Add an entry in the FAQ about the Dialup-Access attribute
 * Add an entry in the FAQ about duplicate personal attributes in the user_admin page
 * Only show the personal attributes in the New User page if we have ldap or we are using the userinfo table in sql
+* Add a per nas finger_type directive
 Ver 1.62:
 * Remove one sql query from user_admin which was not needed.
 * Instead of a query like "LIKE 'YYYY-MM-DD%'" use "AcctStopTime >= 'YYYY-MM-DD 00:00:00 AND AcctStopTime
index 610cdfa..b07d369 100644 (file)
@@ -111,6 +111,13 @@ nas2_model: Cisco 2511 access server
 nas2_ip: 147.122.122.123
 nas2_port_num: 16
 nas2_community: public
+#
+# finger type can also be set per NAS
+# snmp: Use snmp to query the NAS
+# database: Only query the sql database
+#
+# If it is not set, general_finger_type is assumed
+nas2_finger_type: database
 nas3_name: nas3.%{general_domain}
 nas3_model: Cisco 5300 access server
 nas3_ip: 147.122.122.124
index f9308f0..99d83d7 100644 (file)
@@ -50,6 +50,7 @@ if ($link){
                $community = $nas . '_community';
                $ip = $nas . '_ip';
                $portnum = $nas . '_port_num';
+               $finger_type = $nas . '_finger_type';
 
                if ($config[$name] == ''){
                        $i--;
@@ -70,7 +71,7 @@ if ($link){
                if ($config[general_ld_library_path] != '')
                        putenv("LD_LIBRARY_PATH=$config[general_ld_library_path]");
                $extra = "";
-               if ($config[general_finger_type] == 'snmp'){
+               if ($config[$finger_type] != 'database' && $config[general_finger_type] == 'snmp'){
                        $users=exec("$config[general_snmpfinger_bin] $name_data $community_data");
                        if (strlen($users))
                                $extra = "AND UserName IN ($users)";