diff options
Diffstat (limited to 'vendor/bshaffer/oauth2-server-php/src/OAuth2/OpenID/Controller/UserInfoController.php')
-rw-r--r-- | vendor/bshaffer/oauth2-server-php/src/OAuth2/OpenID/Controller/UserInfoController.php | 40 |
1 files changed, 22 insertions, 18 deletions
diff --git a/vendor/bshaffer/oauth2-server-php/src/OAuth2/OpenID/Controller/UserInfoController.php b/vendor/bshaffer/oauth2-server-php/src/OAuth2/OpenID/Controller/UserInfoController.php index 30cb942d0..c489b7af3 100644 --- a/vendor/bshaffer/oauth2-server-php/src/OAuth2/OpenID/Controller/UserInfoController.php +++ b/vendor/bshaffer/oauth2-server-php/src/OAuth2/OpenID/Controller/UserInfoController.php @@ -16,30 +16,34 @@ use OAuth2\ResponseInterface; */ class UserInfoController extends ResourceController implements UserInfoControllerInterface { - private $token; - - protected $tokenType; - protected $tokenStorage; + /** + * @var UserClaimsInterface + */ protected $userClaimsStorage; - protected $config; - protected $scopeUtil; + /** + * Constructor + * + * @param TokenTypeInterface $tokenType + * @param AccessTokenInterface $tokenStorage + * @param UserClaimsInterface $userClaimsStorage + * @param array $config + * @param ScopeInterface $scopeUtil + */ public function __construct(TokenTypeInterface $tokenType, AccessTokenInterface $tokenStorage, UserClaimsInterface $userClaimsStorage, $config = array(), ScopeInterface $scopeUtil = null) { - $this->tokenType = $tokenType; - $this->tokenStorage = $tokenStorage; - $this->userClaimsStorage = $userClaimsStorage; - - $this->config = array_merge(array( - 'www_realm' => 'Service', - ), $config); + parent::__construct($tokenType, $tokenStorage, $config, $scopeUtil); - if (is_null($scopeUtil)) { - $scopeUtil = new Scope(); - } - $this->scopeUtil = $scopeUtil; + $this->userClaimsStorage = $userClaimsStorage; } + /** + * Handle the user info request + * + * @param RequestInterface $request + * @param ResponseInterface $response + * @return void + */ public function handleUserInfoRequest(RequestInterface $request, ResponseInterface $response) { if (!$this->verifyResourceRequest($request, $response, 'openid')) { @@ -55,4 +59,4 @@ class UserInfoController extends ResourceController implements UserInfoControlle ); $response->addParameters($claims); } -} +}
\ No newline at end of file |