From a182bc36d467c2bac1f7439cc484829fbe0eb853 Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 30 Oct 2008 10:55:45 +0000 Subject: [PATCH] Updated ACL caching for get_permissions. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@12828 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-core/include/class_userinfo.inc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gosa-core/include/class_userinfo.inc b/gosa-core/include/class_userinfo.inc index e5ba9c736..4a840d422 100644 --- a/gosa-core/include/class_userinfo.inc +++ b/gosa-core/include/class_userinfo.inc @@ -301,6 +301,12 @@ class userinfo return("rwcdm"); } + /* Ensure that we only cache relevant ACL settings + */ + while(!isset($this->ACL[$dn]) && preg_match("/,/",$dn)){ + $dn = preg_replace("/^[^,]*+,/","",$dn); + } + /* Push cache answer? */ $ACL_CACHE = &session::get('ACL_CACHE'); if (isset($ACL_CACHE["$dn+$object+$attribute"])){ -- 2.30.2