Send notification on MAX_LOGIN_ATTEMPTS

This commit is contained in:
Maks Snegov 2024-04-27 22:47:57 -07:00
parent f66c6ecbf9
commit ca84e18468

View File

@ -433,6 +433,11 @@ async function runner() {
else if (isSignInPage()) {
// Prevent brute forcing
if (ctx.signinAttempts >= MAX_SIGNIN_ATTEMPTS) {
if (prev_ctx.signinAttempts < MAX_SIGNIN_ATTEMPTS) {
msg = 'Too many sign in attempts';
console.log(msg);
await sendNotification(msg);
}
await chrome.storage.local.set({ "ctx_statusMsg": "too many sign in attempts" });
isRunning = false;
return;