note 56782 added to function.ldap-bind
| From: | darkstar_ae at hotmail dot com | Date: | Thu, 15 Sep 2005 07:03:04 +0000 |
| Subject: | note 56782 added to function.ldap-bind | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-95198@lists.php.net to get a copy of this message | ||
This may be a security issue but after tinkering for hours with the below ldap auth function (edi01
at gmx dot at), I discovered that the ldap_bind function will return true if you enter a valid
username AND a NULL value!
so if that function were to receive something like $username = 'someuser' and $password =
'', it would return true. As long as it isn't a null value the function will work as
expected. Might as well check if it is null or empty then.
----
Manual Page -- http://www.php.net/manual/en/function.ldap-bind.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+56782
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+56782&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+56782&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+56782&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+56782&report=yes&reason=useless
Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+56782&report=yes&reason=non-english
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+56782&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+56782&report=yes
Search -- http://master.php.net/manage/user-notes.php