summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2011-03-10 13:05:01 +0000
committerErmal <eri@pfsense.org>2011-03-10 13:05:01 +0000
commit298ca201d8e45f6682e1a5b76f023efe8d2ab5ee (patch)
tree11b0fb5fd7c247cd09331efcd61f19aba3b6a5f0
parent366538692b1392e3c4405820daa65e7638d3b2c4 (diff)
downloadpfsense-298ca201d8e45f6682e1a5b76f023efe8d2ab5ee.zip
pfsense-298ca201d8e45f6682e1a5b76f023efe8d2ab5ee.tar.gz
Define only one loginterface since that is what pf(4) allows. This prevents a memory leak from pfctl(1) which may lead to memory depletion if the utility is run frequently with the pfSense generated ruleset.
-rw-r--r--etc/inc/filter.inc13
1 files changed, 4 insertions, 9 deletions
diff --git a/etc/inc/filter.inc b/etc/inc/filter.inc
index 58a9931..15aee5d 100644
--- a/etc/inc/filter.inc
+++ b/etc/inc/filter.inc
@@ -2632,16 +2632,11 @@ function filter_setup_logging_interfaces() {
echo "filter_setup_logging_interfaces() being called $mt\n";
}
$rules = "";
- foreach ($FilterIflist as $ifdescr => $ifcfg) {
- /*
- * XXX: This should be cleared out after a discussion
- * between pf(4) devs is cleared out. This breaks
- * compatibility with OpenBSD.
- */
- if(isset($ifcfg['virtual']))
- continue;
+ if (isset($FilterIflist['lan']))
$rules .= "set loginterface {$ifcfg['if']}\n";
- }
+ else if (isset($FilterIflist['wan']))
+ $rules .= "set loginterface {$ifcfg['if']}\n";
+
return $rules;
}
OpenPOWER on IntegriCloud