From be1001dbd07ebc6e68e4dd6bf0fb08ce49f11c4c Mon Sep 17 00:00:00 2001 From: Scott Ullrich Date: Wed, 27 Sep 2006 20:21:12 +0000 Subject: Resolve pppoe and dhcp ip addresses --- packages/snort/snort.inc | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/packages/snort/snort.inc b/packages/snort/snort.inc index 45781bc8..fb1c76e3 100644 --- a/packages/snort/snort.inc +++ b/packages/snort/snort.inc @@ -152,7 +152,13 @@ function generate_snort_conf() { $ifcfg = &$config['interfaces'][$int]; $subnet = gen_subnet($ifcfg['ipaddr'], $ifcfg['subnet']); $subnetmask = gen_subnet_mask($ifcfg['subnet']); - $home_net .= "{$subnet}/{$ifcfg['subnet']} "; + if($subnet == "pppoe" or $subnet = "dhcp") { + $subnet = find_interface_ip("ng0"); + if($subnet) + $home_net .= "{$subnet} "; + } else { + $home_net .= "{$subnet}/{$ifcfg['subnet']} "; + } } /* add all local ips to the whitelist */ -- cgit v1.2.3