mirror of
https://github.com/bitwarden/server
synced 2025-12-26 13:13:24 +00:00
only tracking TOTPs in cache (#3275)
This commit is contained in:
@@ -163,7 +163,8 @@ public abstract class BaseRequestValidator<T> where T : class
|
||||
}
|
||||
return;
|
||||
}
|
||||
if (twoFactorProviderType != TwoFactorProviderType.Remember)
|
||||
// We only want to track TOTPs in the chache to enforce one time use.
|
||||
if (twoFactorProviderType == TwoFactorProviderType.Authenticator || twoFactorProviderType == TwoFactorProviderType.Email)
|
||||
{
|
||||
await Core.Utilities.DistributedCacheExtensions.SetAsync(_distributedCache, cacheKey, twoFactorToken, _cacheEntryOptions);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user