예제 #1
0
 /**
  * @param $config
  *  - store_encrypted_token_string (bool true)
  *       whether the entire encrypted string is stored,
  *       or just the token ID is stored
  */
 public function __construct(PublicKeyInterface $publicKeyStorage = null, AccessTokenStorageInterface $tokenStorage = null, RefreshTokenInterface $refreshStorage = null, array $config = array(), EncryptionInterface $encryptionUtil = null)
 {
     $this->publicKeyStorage = $publicKeyStorage;
     $config = array_merge(array('store_encrypted_token_string' => true, 'issuer' => ''), $config);
     if (is_null($tokenStorage)) {
         // a pass-thru, so we can call the parent constructor
         $tokenStorage = new Memory();
     }
     if (is_null($encryptionUtil)) {
         $encryptionUtil = new Jwt();
     }
     $this->encryptionUtil = $encryptionUtil;
     parent::__construct($tokenStorage, $refreshStorage, $config);
 }
 public function __construct(AccessTokenStorageInterface $tokenStorage, RefreshTokenStorageInterface $refreshStorage = null, array $config = array())
 {
     parent::__construct($tokenStorage, $refreshStorage, $config);
 }