From f471b2130461efa25c62dbe8b015da6219cf3498 Mon Sep 17 00:00:00 2001 From: Horus3 Date: Sat, 29 Mar 2014 20:26:26 +0100 Subject: Improved the ban system and the download mechanism. --- www/functions/func_login.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'www/functions/func_login.php') diff --git a/www/functions/func_login.php b/www/functions/func_login.php index 121849c..a4d4696 100755 --- a/www/functions/func_login.php +++ b/www/functions/func_login.php @@ -55,7 +55,6 @@ function brutforce_protection($db){ $_SESSION["login_attempts"] = $_SESSION["login_attempts"] - 1; if($_SESSION["login_attempts"] <= 0){ - $_SESSION["banned"] = true; $remote_ip = $_SERVER["REMOTE_ADDR"]; $session_id = session_id(); $time = $_SERVER["REQUEST_TIME"]; @@ -81,8 +80,8 @@ function check_if_banned($db){ $accepted_time = $_SERVER["REQUEST_TIME"] - 21600; // == 6h if($check_ar[0] < $accepted_time){ - return true; // not longer banned + return false; // not longer banned } else { - return false; // still banned + return true; // still banned } } -- cgit v1.2.3