From 7d6751b922570ef307ee1cd8ef095e6fdaec1a8b Mon Sep 17 00:00:00 2001 From: hickert Date: Mon, 18 Aug 2008 07:53:42 +0000 Subject: [PATCH] Updated ACL detection. - There was a hard coded ou= inside the regex, but we may have an empty group container object defined. groups="" git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@12227 594d385d-05f5-0310-b6e9-bd551577e9d8 --- include/class_userinfo.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/class_userinfo.inc b/include/class_userinfo.inc index 0715c7008..85538a5b0 100644 --- a/include/class_userinfo.inc +++ b/include/class_userinfo.inc @@ -84,8 +84,8 @@ class userinfo } while($attrs = $ldap->fetch()){ - $base= preg_replace('/^[^,]+,ou=[^,]+,/i', "",$ldap->getDN()); - $base= preg_replace("/[ ]*,[ ]*/", ",", $base); + $base= preg_replace('/^[^,]*+,'.normalizePreg(get_groups_ou()).'/i', "",$ldap->getDN()); + $base= preg_replace("/\s*,\s*/", ",", $base); for ($i= 0; $i<$attrs["gosaSubtreeACL"]["count"]; $i++){ $this->subtreeACL[$base][]= $attrs["gosaSubtreeACL"][$i]; -- 2.30.2