note 2742 deleted from function.ldap-bind by didou
| From: | didou@php.net | Date: | Sun, 04 Feb 2007 18:59:40 +0000 |
| Subject: | note 2742 deleted from function.ldap-bind by didou | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-122820@lists.php.net to get a copy of this message | ||
Note Submitter: john dot lewis at waldenweb dot com
----
To get around the null password returns true on servers where anonymous access is allowed, try...
// get a connection
$ldap=ldap_connect($ldapServer);
// check to see if we got one, if we did, proceed
if($ldap)
{
if(!$passWord)
{
// generate a bogus password to pass if the user doesn't give us one
// this gets around systems that are anonymous search enabled
$passWord = crypt(microtime());
}
then do your ldap_bind to test authentication....