Changeset View
Changeset View
Standalone View
Standalone View
lib/Net/LDAP3.php
Show First 20 Lines • Show All 629 Lines • ▼ Show 20 Lines | public function connect($host = null) | ||||
if ($timeout) { | if ($timeout) { | ||||
ldap_set_option($lc, LDAP_OPT_NETWORK_TIMEOUT, $timeout); | ldap_set_option($lc, LDAP_OPT_NETWORK_TIMEOUT, $timeout); | ||||
} | } | ||||
if ($referrals !== null) { | if ($referrals !== null) { | ||||
ldap_set_option($lc, LDAP_OPT_REFERRALS, (bool) $referrals); | ldap_set_option($lc, LDAP_OPT_REFERRALS, (bool) $referrals); | ||||
} | } | ||||
$this->_current_host = $host; | $this->_current_host = $host . (strpos($host, ':') ? '' : ":$port"); | ||||
$this->conn = $lc; | $this->conn = $lc; | ||||
break; | break; | ||||
} | } | ||||
$this->_debug("S: NOT OK"); | $this->_debug("S: NOT OK"); | ||||
} | } | ||||
▲ Show 20 Lines • Show All 137 Lines • ▼ Show 20 Lines | protected function effective_rights_mozldap($entry_dn) | ||||
return null; | return null; | ||||
} | } | ||||
$output = array(); | $output = array(); | ||||
$command = Array( | $command = Array( | ||||
$moz_ldapsearch, | $moz_ldapsearch, | ||||
'-x', | '-x', | ||||
'-h', | '-h', | ||||
preg_replace('|^[a-z]+://|i', '', $this->_current_host), | $this->_current_host, | ||||
'-p', | |||||
$this->config_get('port', 389), | |||||
'-b', | '-b', | ||||
escapeshellarg($entry_dn), | escapeshellarg($entry_dn), | ||||
'-s', | '-s', | ||||
'base', | 'base', | ||||
'-D', | '-D', | ||||
escapeshellarg($this->_current_bind_dn), | escapeshellarg($this->_current_bind_dn), | ||||
'-w', | '-w', | ||||
escapeshellarg($this->_current_bind_pw) | escapeshellarg($this->_current_bind_pw) | ||||
▲ Show 20 Lines • Show All 2,414 Lines • Show Last 20 Lines |