Changeset View
Changeset View
Standalone View
Standalone View
src/applications/auth/provider/PhabricatorAuthProviderPersona.php
| Show First 20 Lines • Show All 49 Lines • ▼ Show 20 Lines | public function processLoginRequest( | ||||
| $request = $controller->getRequest(); | $request = $controller->getRequest(); | ||||
| $adapter = $this->getAdapter(); | $adapter = $this->getAdapter(); | ||||
| $account = null; | $account = null; | ||||
| $response = null; | $response = null; | ||||
| if (!$request->isAjax()) { | if (!$request->isAjax()) { | ||||
| throw new Exception("Expected this request to come via Ajax."); | throw new Exception('Expected this request to come via Ajax.'); | ||||
| } | } | ||||
| $assertion = $request->getStr('assertion'); | $assertion = $request->getStr('assertion'); | ||||
| if (!$assertion) { | if (!$assertion) { | ||||
| throw new Exception("Expected identity assertion."); | throw new Exception('Expected identity assertion.'); | ||||
| } | } | ||||
| $adapter->setAssertion($assertion); | $adapter->setAssertion($assertion); | ||||
| $adapter->setAudience(PhabricatorEnv::getURI('/')); | $adapter->setAudience(PhabricatorEnv::getURI('/')); | ||||
| try { | try { | ||||
| $account_id = $adapter->getAccountID(); | $account_id = $adapter->getAccountID(); | ||||
| } catch (Exception $ex) { | } catch (Exception $ex) { | ||||
| Show All 12 Lines | |||||