38 if (!$tokenData = $this->encryptionUtil->decode($oauth_token,
null,
false)) {
42 $client_id = isset($tokenData[
'aud']) ? $tokenData[
'aud'] :
null;
43 $public_key = $this->publicKeyStorage->getPublicKey($client_id);
44 $algorithm = $this->publicKeyStorage->getEncryptionAlgorithm($client_id);
47 if (
false === $this->encryptionUtil->decode($oauth_token, $public_key, array($algorithm))) {
55 public function setAccessToken($oauth_token, $client_id, $user_id, $expires, $scope =
null)
57 if ($this->tokenStorage) {
58 return $this->tokenStorage->setAccessToken($oauth_token, $client_id, $user_id, $expires, $scope);
64 if ($this->tokenStorage) {
65 return $this->tokenStorage->unsetAccessToken($access_token);
79 foreach ($keyMapping
as $jwtKey => $oauth2Key) {
80 if (isset($tokenData[$jwtKey])) {
81 $tokenData[$oauth2Key] = $tokenData[$jwtKey];
82 unset($tokenData[$jwtKey]);