From e33c869497fa0afd49ecf87a7b89432fd84015cc Mon Sep 17 00:00:00 2001 From: Bill Marquette Date: Mon, 28 Feb 2005 03:45:04 +0000 Subject: We can now put OS filtering in rules --- usr/local/www/firewall_rules_edit.php | 36 ++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) (limited to 'usr') diff --git a/usr/local/www/firewall_rules_edit.php b/usr/local/www/firewall_rules_edit.php index 1ce53d4..c592984 100755 --- a/usr/local/www/firewall_rules_edit.php +++ b/usr/local/www/firewall_rules_edit.php @@ -141,6 +141,8 @@ if (isset($id) && $a_filter[$id]) { $pconfig['srcmask'], $pconfig['srcnot'], $pconfig['srcbeginport'], $pconfig['srcendport']); + $pconfig['os'] = $a_filter[$id]['os']; + address_to_pconfig($a_filter[$id]['destination'], $pconfig['dst'], $pconfig['dstmask'], $pconfig['dstnot'], $pconfig['dstbeginport'], $pconfig['dstendport']); @@ -294,6 +296,9 @@ if ($_POST) { $_POST['dstendport'] = $_POST['dstbeginport']; $_POST['dstbeginport'] = $tmp; } + if ($_POST['os']) + if( $_POST['proto'] != "tcp" ) + $input_errors[] = "OS detection is only valid with protocol tcp."; if (!$input_errors) { $filterent = array(); @@ -305,6 +310,7 @@ if ($_POST) { $filterent['max-src-states'] = $_POST['max-src-states']; $filterent['statetimeout'] = $_POST['statetimeout']; $filterent['statetype'] = $_POST['statetype']; + $filterent['os'] = $_POST['os']; if ($_POST['proto'] != "any") $filterent['protocol'] = $_POST['proto']; @@ -634,6 +640,33 @@ Hint: the difference between block and reject is that with reject, a packet (TCP the source of the packet for this rule. This is usually not equal to the destination port range (and is often "any").
Hint: you can leave the 'to' field empty if you only want to filter a single port + + + Source OS + OS Type:  +
+ Note: this only works for TCP rules + Destination @@ -749,7 +782,8 @@ Hint: the difference between block and reject is that with reject, a packet (TCP Advanced Options
Simultaneous client connection limit

-
Maximum state entries per host
+
Maximum state entries per host

+

NOTE: Leave these fields blank to disable this feature. -- cgit v1.1