]> git.entuzijast.net Git - freeradius-dialup-admin.git/commitdiff
When searching a user in ldap through the find page only try to find the users which...
authorkkalev <kkalev>
Tue, 12 Nov 2002 09:04:12 +0000 (09:04 +0000)
committerkkalev <kkalev>
Tue, 12 Nov 2002 09:04:12 +0000 (09:04 +0000)
Changelog
lib/ldap/find.php3

index e842a7016b4b73d3e8aeb96ee70aa414cd1ba1d0..99fde222e5f754f519597a55d7d3c3a903635158 100644 (file)
--- a/Changelog
+++ b/Changelog
@@ -8,6 +8,7 @@ Ver 1.61:
 * Fix a parse error in failed_logins.php3
 * Fix a bug in lib/defaults.php3 which did not allow the default.vals file to be used correctly
 * Include password.php3 in lib/ldap/password_check.php3
+* When searching a user in ldap through the find page only try to find the users which have a uid attribute (username)
 Ver 1.60:
 * Use require_once when including lib/functions.php3 in lib/sql
 * In the buttons toolbar Edit User should not be clickable.
index 5c6da52e7634f3d86490ab0929b711034a8d2039..e1809180c636a0d63aee5925def8c2e5780bba2a 100644 (file)
@@ -9,7 +9,7 @@ if ($ds) {
                require('../lib/ldap/attrmap.php3');
                $attr = $attrmap[$radius_attr];
        }
-       $sr=@ldap_search($ds,"$config[ldap_base]", "$attr=*$search*",array('uid'),0,$max_results);
+       $sr=@ldap_search($ds,"$config[ldap_base]", "(&($attr=*$search*)(uid=*))",array('uid'),0,$max_results);
        if (($info = @ldap_get_entries($ds, $sr))){
                for ($i = 0; $i < $info["count"]; $i++)
                        $found_users[] = $info[$i]['uid'][0];