config = &$config; $this->dn = $dn; $this->parent = &$parent; $ldap = $this->config->get_ldap_link(); $ldap->cd($this->config->current['BASE']); $ldap->cat($dn); $this->attrs = $ldap->fetch(); if(isset($this->parent->acl_category) && !empty($this->parent->acl_category)){ $this->acl_category = preg_replace("/\/$/","",$this->parent->acl_category); } if(isset($attrs['uid'][0])){ $this->uid = $attrs['uid'][0]; } $this->ignoreACL = ($this->config->get_cfg_value("ignoreAcl") == $this->dn); $this->reset_acl_cache(); $this->loadACL(); foreach($this->allACLs as $dn => $acls){ if(preg_match("/".preg_quote($dn,'/')."$/i", $this->dn)){ foreach($acls as $prio => $acl){ if($acl['type'] == "reset"){ $this->affectingACLs[$dn][$prio] = $acl; break; }else{ foreach($acl['acl'] as $category => $attributes){ if(preg_match("/^all($|\/)/", $category) || preg_match("/^".$this->acl_category."($|\/)/", $category)){ $this->affectingACLs[$dn][$prio] = $acl; break; } } } } } } } function getReadableACL() { $str = "
".$image." | "; $str.="".$dn." | "; $str.="".$aclTypes[$acl['type']]." | "; $str.="
"._("Members")."
| ";
$str.="";
if($acl['type']!='reset'){
$str.=""._("Acls")."
| ";
$str .= "|