diff --git a/core/src/plugins/auth.ldap/class.ldapAuthDriver.php b/core/src/plugins/auth.ldap/class.ldapAuthDriver.php index 0210ec7b89..ef3de0a7bb 100644 --- a/core/src/plugins/auth.ldap/class.ldapAuthDriver.php +++ b/core/src/plugins/auth.ldap/class.ldapAuthDriver.php @@ -510,8 +510,9 @@ public function listChildrenGroups($baseGroup = "/") if (count($branch)) { $parent = "/" . implode("/", array_reverse($branch)); } - AuthService::createGroup($parent, $dn, $login); - + if(!ConfService::getConfStorageImpl()->groupExists(rtrim(AuthService::filterBaseGroup($parent), "/")."/".$dn)) { + AuthService::createGroup($parent, $dn, $login); + } } $this->ldapDN = $origUsersDN; $this->ldapFilter = $origUsersFilter;