public function getCredentials() { $value = $this->getUserData('KurogoCredentialsCache'); try { $credentials = Kurogo::decrypt($value); } catch (KurogoException $e) { $credentials = $value; } return $credentials; }
public function getCredentials(AuthenticationAuthority $authority) { $value = null; if ($cache = Kurogo::arrayVal($_SESSION, 'KurogoCredentialsCache')) { $value = Kurogo::arrayVal($cache, $authority->getAuthorityIndex()); } try { $credentials = Kurogo::decrypt($value); } catch (KurogoException $e) { $credentials = $value; } return $credentials; }