fixed LDAP_DEREF_NEVER

This commit is contained in:
Roland Gruber 2014-12-11 18:22:35 +00:00
parent 261a794249
commit 1676c1b81d
4 changed files with 5 additions and 3 deletions

View File

@ -4,6 +4,8 @@ December 2014 4.8
- Usability improvements - Usability improvements
- LAM Pro: - LAM Pro:
-> Self service: added option if referrals should be followed -> Self service: added option if referrals should be followed
- fixed bugs:
-> missing LDAP_DEREF_NEVER in some cases (169)
07.10.2014 4.7.1 07.10.2014 4.7.1

View File

@ -780,7 +780,7 @@ function ldapGetDN($dn, $attributes = array('dn'), $handle = null) {
$handle = $_SESSION['ldap']->server(); $handle = $_SESSION['ldap']->server();
} }
$return = null; $return = null;
$sr = @ldap_read($handle, escapeDN($dn), 'objectClass=*', $attributes); $sr = @ldap_read($handle, escapeDN($dn), 'objectClass=*', $attributes, 0, 0, 0, LDAP_DEREF_NEVER);
if ($sr) { if ($sr) {
$entries = ldap_get_entries($_SESSION['ldap']->server(), $sr); $entries = ldap_get_entries($_SESSION['ldap']->server(), $sr);
if ($entries) { if ($entries) {

View File

@ -510,7 +510,7 @@ class imapAccess extends baseModule {
// read LAM login user data // read LAM login user data
$data = $_SESSION['ldap']->decrypt_login(); $data = $_SESSION['ldap']->decrypt_login();
$dn = $data[0]; $dn = $data[0];
$sr = @ldap_read($_SESSION['ldap']->server(), $dn, '(objectclass=*)', $attrNames); $sr = @ldap_read($_SESSION['ldap']->server(), $dn, '(objectclass=*)', $attrNames, 0, 0, 0, LDAP_DEREF_NEVER);
if ($sr) { if ($sr) {
$info = @ldap_get_entries($_SESSION['ldap']->server(), $sr); $info = @ldap_get_entries($_SESSION['ldap']->server(), $sr);
if ($info) { if ($info) {

View File

@ -215,7 +215,7 @@ function lamRunLamdaemonTestSuite($serverName, $serverTitle, $testQuota, $contai
$container->addElement($spacer); $container->addElement($spacer);
$credentials = $_SESSION['ldap']->decrypt_login(); $credentials = $_SESSION['ldap']->decrypt_login();
$unixOk = false; $unixOk = false;
$sr = @ldap_read($_SESSION['ldap']->server(), $credentials[0], "objectClass=posixAccount", array('uid')); $sr = @ldap_read($_SESSION['ldap']->server(), $credentials[0], "objectClass=posixAccount", array('uid'), 0, 0, 0, LDAP_DEREF_NEVER);
if ($sr) { if ($sr) {
$entry = @ldap_get_entries($_SESSION['ldap']->server(), $sr); $entry = @ldap_get_entries($_SESSION['ldap']->server(), $sr);
$userName = $entry[0]['uid'][0]; $userName = $entry[0]['uid'][0];