feat(auth): add microsoft auto-remember policy with tenant override and configurable remember TTL
This commit is contained in:
@@ -25,7 +25,8 @@ class RememberMeService
|
||||
private readonly AuthSessionTenantContextService $authSessionTenantContextService,
|
||||
private readonly SessionStoreInterface $sessionStore,
|
||||
private readonly CookieStoreInterface $cookieStore,
|
||||
private readonly RequestRuntimeInterface $requestRuntime
|
||||
private readonly RequestRuntimeInterface $requestRuntime,
|
||||
private readonly ?AuthSettingsGateway $authSettingsGateway = null
|
||||
) {
|
||||
}
|
||||
|
||||
@@ -175,7 +176,11 @@ class RememberMeService
|
||||
|
||||
private function lifetimeSeconds(): int
|
||||
{
|
||||
return self::LIFETIME_DAYS * 24 * 60 * 60;
|
||||
if ($this->authSettingsGateway !== null) {
|
||||
return $this->authSettingsGateway->getRememberTokenLifetimeDays() * 86400;
|
||||
}
|
||||
|
||||
return self::LIFETIME_DAYS * 86400;
|
||||
}
|
||||
|
||||
private function cookieName(): string
|
||||
|
||||
Reference in New Issue
Block a user