From: Duck (Jakob Munih) Date: Wed, 30 Sep 2009 14:59:11 +0000 (+0200) Subject: We must throw an exeption on bad login X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=b8af1a76c0067ef77eccfb07958aa69cd25e59fe;p=horde.git We must throw an exeption on bad login --- diff --git a/folks/lib/Application.php b/folks/lib/Application.php index 654caf5a7..e91f4988d 100644 --- a/folks/lib/Application.php +++ b/folks/lib/Application.php @@ -27,13 +27,16 @@ class Folks_Application extends Horde_Registry_Application * @param string $userID Username * @param array $credentials Array of criedentials (password requied) * - * @return boolean Whether IMP authentication was successful. + * @return boolean Whether Folks authentication was successful. */ public function authAuthenticate($userID, $credentials) { require_once dirname(__FILE__) . '/base.php'; - return $GLOBALS['folks_driver']->comparePassword($userID, $credentials['password']); + $result = $GLOBALS['folks_driver']->comparePassword($userID, $credentials['password']); + if ($result !== true) { + throw new Horde_Auth_Exception('', Horde_Auth::REASON_BADLOGIN); + } } /**