public function getMyAttributes($attrs) { $ldapObj = new Lucid_LDAP($this->configFile); $ldapObj->bind($this->username, $this->password); $result = $ldapObj->getAttributes($this->username, $attrs); $ldapObj->destroy(); return $result; }
public function updateAttr($dn, $attrib, $value) { $ldapObj = new Lucid_LDAP($this->configFile); $ldapObj->bind($this->username, $this->password); $status = $ldapObj->updateAttribute($dn, $attrib, $value); $ldapObj->destroy(); if ($status === true) { $this->loggerObj->log("ADMIN::info::{$this->username} has updated {$attrib} for {$dn} successfully"); } else { $this->loggerObj->log("ADMIN::error::{$this->username}'s Attempt to update {$attrib} for {$dn} has failed. Reason: {$status}"); } return $status; }