Merge pull request #3329 from andreas-p/ldap_no-memberof-with-memberuid

Ldap no memberof with memberuid
This commit is contained in:
Roeland Jago Douma 2017-03-29 19:12:51 +02:00 committed by GitHub
commit 636575e3de
1 changed files with 3 additions and 1 deletions

View File

@ -496,9 +496,11 @@ class Group_LDAP extends BackendUtility implements \OCP\GroupInterface {
// if possible, read out membership via memberOf. It's far faster than
// performing a search, which still is a fallback later.
// memberof doesn't support memberuid, so skip it here.
if(intval($this->access->connection->hasMemberOfFilterSupport) === 1
&& intval($this->access->connection->useMemberOfToDetectMembership) === 1
) {
&& strtolower($this->access->connection->ldapGroupMemberAssocAttr) !== 'memberuid'
) {
$groupDNs = $this->_getGroupDNsFromMemberOf($userDN);
if (is_array($groupDNs)) {
foreach ($groupDNs as $dn) {