if (!check_perms('admin_login_watch')) { error(403); } if (isset($_POST['submit']) && isset($_POST['ip']) && $_POST['submit'] == 'Unban') { authorize(); $Cache->delete_value('login_attempts_'.$_POST['ip']); } View::show_header('Login Watch'); $AttemptIPs = $Cache->get_value('login_attempts'); $AllAttempts = array(); foreach($AttemptIPs as $IP => $Time) { if (time() > $Time) { continue; } list($Attempts, $Banned) = $Cache->get_value('login_attempts_'.$IP); if (!isset($Attempts) && !isset($Banned)) { continue; } $AllAttempts[] = [$IP, $Attempts, $Banned, $Time]; } ?>
IP | Attempts | Banned | Time | Submit | if (check_perms('admin_manage_ipbans')) { ?>Submit | } ?>
=$IP?> | =$Attempts?> | =($Banned?'Yes':'No')?> | =time_diff($BannedUntil)?> | if (check_perms('admin_manage_ipbans')) { ?> | } ?> |