/** * Set configuration; throw an exception if it is invalid. * * @param \Zend\Config\Config $config Configuration to set * * @throws AuthException * @return void */ public function setConfig($config) { parent::setConfig($config); $this->strategies = array_map('trim', explode(',', $this->getConfig()->ChoiceAuth->choice_order)); }
/** * Password policy for a new password (e.g. minLength, maxLength) * * @return array */ public function getPasswordPolicy() { $policy = $this->getCatalog()->getPasswordPolicy($this->getLoggedInPatron()); return $policy !== false ? $policy : parent::getPasswordPolicy(); }
/** * Password policy for a new password (e.g. minLength, maxLength) * * @return array */ public function getPasswordPolicy() { $policy = parent::getPasswordPolicy(); // Limit maxLength to the database limit if (!isset($policy['maxLength']) || $policy['maxLength'] > 32) { $policy['maxLength'] = 32; } return $policy; }
/** * Set configuration; throw an exception if it is invalid. * * @param \Zend\Config\Config $config Configuration to set * * @throws AuthException * @return void */ public function setConfig($config) { parent::setConfig($config); if (isset($config->MultiAuth->method_order)) { $this->methods = array_map('trim', explode(',', $config->MultiAuth->method_order)); } if (isset($config->MultiAuth->filters) && strlen($config->MultiAuth->filters)) { $this->filters = array_map('trim', explode(',', $config->MultiAuth->filters)); } }
/** * Password policy for a new password (e.g. minLength, maxLength) * * @return array */ public function getPasswordPolicy() { $policy = $this->getCatalog()->getPasswordPolicy($this->getLoggedInPatron()); if ($policy === false) { return parent::getPasswordPolicy(); } if (isset($policy['pattern']) && empty($policy['hint'])) { $policy['hint'] = $this->getCannedPasswordPolicyHint($policy['pattern']); } return $policy; }