Increase 2FA window size

This commit is contained in:
cnr 2017-01-20 15:42:21 -06:00
parent fbb1836eb5
commit 8ae74ce952
1 changed files with 4 additions and 1 deletions

View File

@ -27,6 +27,7 @@ import org.bukkit.map.MapRenderer;
import org.bukkit.map.MapView;
import com.warrenstrange.googleauth.GoogleAuthenticator;
import com.warrenstrange.googleauth.GoogleAuthenticatorConfig;
import mineplex.core.Managers;
import mineplex.core.MiniClientPlugin;
@ -46,7 +47,9 @@ public class TwoFactorAuth extends MiniClientPlugin<TwoFactorData>
private final Map<UUID, String> setupData = new HashMap<>();
private final Set<UUID> authenticating = new HashSet<>();
private static final GoogleAuthenticator authenticator = new GoogleAuthenticator();
private static final GoogleAuthenticator authenticator = new GoogleAuthenticator(
new GoogleAuthenticatorConfig.GoogleAuthenticatorConfigBuilder().setWindowSize(5).build()
);
private final CoreClientManager _clientManager = Managers.require(CoreClientManager.class);
private final TwoFactorRepository _repository = new TwoFactorRepository(DBPool.getAccount());