$netmask = ImportHTTPVar("netmask", VAR_DIGIT); $action = ImportHTTPVar("action", VAR_ALPHA); $submit = ImportHTTPVar("submit", VAR_ALPHA | VAR_SPACE); // Check role out and redirect if needed -- Kevin $roleneeded = 10000; #$BUser = new BaseUser(); #if (($BUser->hasRole($roleneeded) == 0) && ($Use_Auth_System == 1)) base_header("Location: " . $BASE_urlpath . "/index.php"); if ($netmask == '') { $netmask = "32"; } $page_title = $ip . '/' . $netmask; /* Connect to the Alert database */ $db = NewBASEDBConnection($DBlib_path, $DBtype); $db->baseDBConnect($db_connect_method, $alert_dbname, $alert_host, $alert_port, $alert_user, $alert_password); // Include base_header.php PrintBASESubHeader($page_title, $page_title, $cs->GetBackLink(), 1); if ($event_cache_auto_update == 1) { UpdateAlertCache($db); } if (sizeof($sig) != 0 && strstr($sig[1], "spp_portscan")) { $sig[1] = ""; } /* Build new link for criteria-based sensor page * -- ALS <*****@*****.**> */ $tmp_sensor_lookup = 'base_stat_sensor.php?ip_addr_cnt=2&m_opt=analysis&sm_opt=security_events&h_opt=security_events' . BuildIPFormVars($ip); $tmp_srcdst_iplookup = 'base_qry_main.php?new=2&m_opt=analysis&sm_opt=security_events&h_opt=security_events' . '&num_result_rows=-1' . '&submit=' . gettext("Query DB") . '&current_view=-1&ip_addr_cnt=2' . BuildIPFormVars($ip); $tmp_src_iplookup = 'base_qry_main.php?new=2&m_opt=analysis&sm_opt=security_events&h_opt=security_events' . '&num_result_rows=-1' . '&submit=' . gettext("Query DB") . '&current_view=-1&ip_addr_cnt=1' . BuildSrcIPFormVars($ip); $tmp_dst_iplookup = 'base_qry_main.php?new=2&m_opt=analysis&sm_opt=security_events&h_opt=security_events' . '&num_result_rows=-1' . '&submit=' . gettext("Query DB") . '&current_view=-1&ip_addr_cnt=1' . BuildDstIPFormVars($ip); echo '<CENTER><BR>'; echo '<table border=0 cellpadding=0 cellspacing=0 class="table_list" style="width:90%">';
$qs->MoveView($submit); /* increment the view if necessary */ if ($addr_type == SOURCE_IP) { $page_title = gettext("Unique Source Address(es)"); $results_title = gettext("Src IP address"); $addr_type_name = "ip_src"; } else { if ($addr_type != DEST_IP) { ErrorMessage(gettext("CRITERIA ERROR: unknown address type -- assuming Dst address")); } $page_title = gettext("Unique Destination Address(es)"); $results_title = gettext("Dst IP address"); $addr_type_name = "ip_dst"; } if ($qs->isCannedQuery()) { PrintBASESubHeader($page_title . ": " . $qs->GetCurrentCannedQueryDesc(), $page_title . ": " . $qs->GetCurrentCannedQueryDesc(), $cs->GetBackLink(), 1); } else { PrintBASESubHeader($page_title, $page_title, $cs->GetBackLink(), 1); } if ($event_cache_auto_update == 1) { UpdateAlertCache($db); } $criteria_clauses = ProcessCriteria(); if (!$printing_ag) { /* ***** Generate and print the criteria in human readable form */ echo '<TABLE WIDTH="100%"> <TR> <TD WIDTH="60%" VALIGN=TOP>'; if (!array_key_exists("minimal_view", $_GET)) { PrintCriteria($caller); }