public function authenticate(Login $login, Firewall $firewall) { try { $result = $firewall->verifyPasswordHash($login->getPassword(), $this->getPassword()); } catch (\Exception $e) { throw new \Exception($e->getMessage()); } return $result; }