Lines Matching defs:info

171      * Return user info [required auth function]
173 * Returns info about the given user needs to contain
212 //get info for given user
213 $result = $adldap->user()->info($this->getUserName($user), $fields);
218 //general user info
219 $info = array();
220 $info['name'] = $result[0]['displayname'][0];
221 $info['mail'] = $result[0]['mail'][0];
222 $info['uid'] = $result[0]['samaccountname'][0];
223 $info['dn'] = $result[0]['dn'];
225 $info['lastpwd'] = $result[0]['pwdlastset'][0] / 10000000 - 11644473600;
227 $info['expires'] = !($result[0]['useraccountcontrol'][0] & 0x10000); //ADS_UF_DONT_EXPIRE_PASSWD
232 $info[$field] = $result[0][strtolower($field)][0];
237 $info['grps'] = $adldap->user()->groups($this->getUserName($user), (bool) $this->opts['recursive_groups']);
239 if (is_array($info['grps'])) {
240 foreach ($info['grps'] as $ndx => $group) {
241 $info['grps'][$ndx] = $this->cleanGroup($group);
246 if (!is_array($info['grps']) || !in_array($conf['defaultgroup'], $info['grps'])) {
247 $info['grps'][] = $conf['defaultgroup'];
252 if ($domain && !in_array("domain-$domain", (array) $info['grps'])) {
253 $info['grps'][] = $this->cleanGroup("domain-$domain");
257 if ($info['expires'] && $this->conf['expirywarn']) {
261 $info['expiresat'] = $expiry['expiryts'];
262 $info['expiresin'] = round(($info['expiresat'] - time())/(24*60*60));
266 ($info['expiresin'] <= $this->conf['expirywarn']) &&
269 $msg = sprintf($this->getLang('authpwdexpire'), $info['expiresin']);
283 return $info;
473 foreach ($this->users as $user => &$info) {
477 if ($info === false) {
478 $info = $this->getUserData($user);
480 if ($this->filter($user, $info)) {
481 $this->grpsusers[$this->filterToString($filter)][$user] = $info;
504 //get info for given user
519 foreach ($this->users as $user => &$info) {
523 if ($info === false) {
524 $info = $this->getUserData($user);
526 $result[$user] = $info;
546 foreach ($this->grpsusers[$this->filterToString($filter)] as $user => &$info) {
550 $result[$user] = $info;
757 * @param array $info
760 protected function filter($user, $info)
766 if (!count(preg_grep($pattern, $info['grps']))) return false;
768 if (!preg_match($pattern, $info[$item])) return false;