Fix HTTP login attempts check triggering too late (#20431)
This commit is contained in:
parent
76c0295403
commit
d39784906b
2 changed files with 2 additions and 2 deletions
|
@ -104,7 +104,7 @@ async def process_wrong_login(request):
|
|||
|
||||
request.app[KEY_FAILED_LOGIN_ATTEMPTS][remote_addr] += 1
|
||||
|
||||
if (request.app[KEY_FAILED_LOGIN_ATTEMPTS][remote_addr] >
|
||||
if (request.app[KEY_FAILED_LOGIN_ATTEMPTS][remote_addr] >=
|
||||
request.app[KEY_LOGIN_THRESHOLD]):
|
||||
new_ban = IpBan(remote_addr)
|
||||
request.app[KEY_BANNED_IPS].append(new_ban)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue