diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2006-10-05 17:13:40 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2006-10-05 17:13:40 +0000 |
commit | d2a2ba9504179e14e66c8003fd5ceb5fd176eda1 (patch) | |
tree | 1aa95f8f00c34b35898430286326e041c2520d73 /etc/inc | |
parent | 360d815d22bb7e2c100a445a0bdbaafdd7f6a513 (diff) | |
download | pfsense-d2a2ba9504179e14e66c8003fd5ceb5fd176eda1.zip pfsense-d2a2ba9504179e14e66c8003fd5ceb5fd176eda1.tar.gz |
Only install spamd_whitelist if /var/db/whitelist exists
Diffstat (limited to 'etc/inc')
-rw-r--r-- | etc/inc/filter.inc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/etc/inc/filter.inc b/etc/inc/filter.inc index ac25f07..5f1c741 100644 --- a/etc/inc/filter.inc +++ b/etc/inc/filter.inc @@ -679,7 +679,8 @@ function filter_nat_rules_generate() { $natrules .= "table <whitelist> persist\n"; $natrules .= "table <blacklist> persist\n"; $natrules .= "table <spamd> persist\n"; - $natrules .= "table <spamd-white> persist file \"/var/db/whitelist.txt\"\n"; + if(file_exists("/var/db/whitelist.txt")) + $natrules .= "table <spamd-white> persist file \"/var/db/whitelist.txt\"\n"; $natrules .= "rdr pass on {$wanif} proto tcp from <blacklist> to port smtp -> 127.0.0.1 port spamd\n"; $natrules .= "rdr pass on {$wanif} proto tcp from <spamd> to port smtp -> 127.0.0.1 port spamd\n"; $natrules .= "rdr pass on {$wanif} proto tcp from !<spamd-white> to port smtp -> 127.0.0.1 port spamd\n"; |