mirror of
https://github.com/elyby/accounts.git
synced 2025-05-31 14:11:46 +05:30
Add support for the legacy refresh tokens, make the new refresh tokens non-expire [skip ci]
This commit is contained in:
@@ -45,11 +45,11 @@ class Component extends BaseComponent {
|
||||
$authServer->enableGrantType($authCodeGrant, $accessTokenTTL);
|
||||
$authCodeGrant->setScopeRepository($publicScopesRepo); // Change repository after enabling
|
||||
|
||||
// TODO: extends refresh token life time to forever
|
||||
$refreshTokenGrant = new RefreshTokenGrant($refreshTokensRepo);
|
||||
$authServer->enableGrantType($refreshTokenGrant, $accessTokenTTL);
|
||||
$authServer->enableGrantType($refreshTokenGrant);
|
||||
$refreshTokenGrant->setScopeRepository($publicScopesRepo); // Change repository after enabling
|
||||
|
||||
// TODO: make these access tokens live longer
|
||||
$clientCredentialsGrant = new Grant\ClientCredentialsGrant();
|
||||
$authServer->enableGrantType($clientCredentialsGrant, $accessTokenTTL);
|
||||
$clientCredentialsGrant->setScopeRepository($internalScopesRepo); // Change repository after enabling
|
||||
|
||||
Reference in New Issue
Block a user