<?php
/************************************************************************/
/* Maximus CMS: Web Portal System                                       */
/* ==============================                                       */
/*                                                                      */
/* Copyright (c) 2002 - 2006                                            */
/* http://www.php-maximus.fr                                            */
/* dev@php-maximus.org                                                  */
/*                                                                      */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
/************************************************************************/
/* Based on PHP-NUKE: Web Portal System                                 */
/************************************************************************/
/********************************************************/
/* NukeSentinel(tm)                                     */
/* By: NukeScripts Network (webmaster@nukescripts.net)  */
/* http://www.nukescripts.net                           */
/* Copyright © 2000-2005 by NukeScripts Network         */
/********************************************************/

if (!defined('ADMIN_ALLOW') && !defined('ADMIN_MAX')) {
	die ("Access Denied");
}

$pagetitle = _AB_NUKESENTINEL.": "._AB_VIEWIP;
incoh();
title($pagetitle);
Max_OpenTable();
OpenMenu();
ipbanmenu();
CarryMenu();
blockedipmenu();
CloseMenu();
Max_CloseTable();
br('1');
Max_OpenTable();
$getIPs = $db->sql_fetchrow($db->sql_query("SELECT * FROM `".TABLE_NSNST_BLOCKED_IPS."` WHERE `ip_addr`='$xIPs'"));
$getIPs['date'] = date("Y-m-d H:i:s",$getIPs['date']);
list($getIPs['reason']) = $db->sql_fetchrow($db->sql_query("SELECT `reason` FROM `".TABLE_NSNST_BLOCKERS."` WHERE `blocker`='".$getIPs['reason']."'"));
$lookupip = str_replace("*", "0", $xIPs);
echo "<table align='center' border='0' cellpadding='2' cellspacing='2'>\n";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_BLOCKEDIP.":</b></td><td><a href='".$ab_config['lookup_link']."$lookupip' target='$xIPs'>$xIPs</a></td></tr>";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_USER.":</b></td><td>".$getIPs['username']."</td></tr>";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_AGENT.":</b></td><td>".$getIPs['user_agent']."</td></tr>";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_BLOCKEDON.":</b></td><td>".$getIPs['date']."</td></tr>";
echo "<tr><td bgcolor='$bgcolor2' valign='top'><b>"._AB_NOTES.":</b></td><td>".$getIPs['notes']."</td></tr>\n";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_REASON.":</b></td><td>".$getIPs['reason']."</td></tr>\n";
echo "<tr><td bgcolor='$bgcolor2' colspan='2'>&nbsp;</td></tr>\n";
$getIPs['query_string'] = htmlentities(base64_decode($getIPs['query_string']));
$getIPs['query_string'] = str_replace("%20", " ", $getIPs['query_string']);
$getIPs['query_string'] = str_replace("/**/", "/* */", $getIPs['query_string']);
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_QUERY.":</b></td><td>".info_img("<b>"._AB_QUERY.":</b> ".$getIPs['query_string'], r)."</td></tr>\n";
$getIPs['get_string'] = htmlentities(base64_decode($getIPs['get_string']));
$getIPs['get_string'] = str_replace("%20", " ", $getIPs['get_string']);
$getIPs['get_string'] = str_replace("/**/", "/* */", $getIPs['get_string']);
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_GET.":</b></td><td>".info_img("<b>"._AB_GET.":</b> ".$getIPs['get_string'], r)."</td></tr>\n";
$getIPs['post_string'] = htmlentities(base64_decode($getIPs['post_string']));
$getIPs['post_string'] = str_replace("%20", " ", $getIPs['post_string']);
$getIPs['post_string'] = str_replace("/**/", "/* */", $getIPs['post_string']);
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_POST.":</b></td><td>".info_img("<b>"._AB_POST.":</b> ".$getIPs['post_string'], r)."</td></tr>\n";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_X_FORWARDED.":</b></td><td>".$getIPs['x_forward_for']."</td></tr>\n";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_CLIENT_IP.":</b></td><td>".$getIPs['client_ip']."</td></tr>\n";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_REMOTE_ADDR.":</b></td><td>".$getIPs['remote_addr']."</td></tr>\n";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_REMOTE_PORT.":</b></td><td>".$getIPs['remote_port']."</td></tr>\n";
echo "<tr><td bgcolor='$bgcolor2'><b>"._AB_REQUEST_METHOD.":</b></td><td>".$getIPs['request_method']."</td></tr>\n";
echo "<tr><td align='center' colspan='2'>"._GOBACK."</td></tr>";
echo "</table>\n";
Max_CloseTable();
incof();