diff --git a/src/www/status_graph.php b/src/www/status_graph.php index 7acdcf50f..afa37319e 100644 --- a/src/www/status_graph.php +++ b/src/www/status_graph.php @@ -87,7 +87,21 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { $real_interface = get_real_interface($pconfig['if']); $intsubnet = find_interface_network($real_interface); if (is_subnetv4($intsubnet)) { - $cmd_args = $pconfig['filter'] == "local" ? " -c " . $intsubnet . " " : " -lc 0.0.0.0/0 "; + + switch ( $pconfig['filter'] ) { + case 'local': + $cmd_args = " -c " . $intsubnet . " "; + break; + + case 'private': + $cmd_args = " -c 172.16.0.0/12 -c 192.168.0.0/16 -c 10.0.0.0/8 "; + break; + + default: + $cmd_args = " -lc 0.0.0.0/0 "; + break; + } + $cmd_args .= $pconfig['sort'] == "out" ? " -T " : " -R "; $cmd_action = "/usr/local/bin/rate -v -i {$real_interface} -nlq 1 -Aba 20 {$cmd_args} | tr \"|\" \" \" | awk '{ printf \"%s:%s:%s:%s:%s\\n\", $1, $2, $4, $6, $8 }'"; exec($cmd_action, $listedIPs); @@ -135,6 +149,9 @@ include("head.inc"); margin: 0px; margin-bottom: -5px; } +.table-striped select { + max-width: none; +}