aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRenato Botelho <renato@netgate.com>2016-04-04 07:37:43 -0300
committerRenato Botelho <renato@netgate.com>2016-04-04 07:37:43 -0300
commit59e9d5426697ceea8aabce311f6c61a9b24ad7d1 (patch)
tree9e3f848189c49d8742ef1d83a70c310db2708ced
parent0ae8b6dbdbe106bbb33c1fb62ae4b6479df81072 (diff)
parentfce3c4cb51a95973b08b0455400d4edc4a7187bf (diff)
downloadpfsense-packages-59e9d5426697ceea8aabce311f6c61a9b24ad7d1.tar.gz
pfsense-packages-59e9d5426697ceea8aabce311f6c61a9b24ad7d1.tar.bz2
pfsense-packages-59e9d5426697ceea8aabce311f6c61a9b24ad7d1.zip
Merge pull request #1247 from BBcan177/patch-1
-rw-r--r--config/pfblockerng/pfblockerng.inc12
-rw-r--r--pkg_config.10.xml2
2 files changed, 11 insertions, 3 deletions
diff --git a/config/pfblockerng/pfblockerng.inc b/config/pfblockerng/pfblockerng.inc
index 437d912d..4df77922 100644
--- a/config/pfblockerng/pfblockerng.inc
+++ b/config/pfblockerng/pfblockerng.inc
@@ -2480,7 +2480,15 @@ function sync_package_pfblockerng($cron='') {
}
// Rebuild DNSBL database or DNSBL statistics if files are not found
- if (!file_exists("{$pfb['dnsbl_file']}.conf") || !file_exists($pfb['dnsbl_info'])) {
+ $dnsbl_missing = FALSE;
+ if (!file_exists("{$pfb['dnsbl_file']}.conf")) {
+ $dnsbl_missing = TRUE;
+ }
+ if (!file_exists("{$pfb['dnsbl_info']}")) {
+ $dnsbl_missing = TRUE;
+ }
+
+ if ($dnsbl_missing) {
$log = "Missing DNSBL stats and/or Unbound DNSBL conf file - Rebuilding\n";
pfb_logger("{$log}", 1);
$pfb['reuse_dnsbl'] = 'on';
@@ -3153,7 +3161,7 @@ function sync_package_pfblockerng($cron='') {
}
else {
// When DNSBL is enabled and no Aliases are defined, or all Aliases are Disabled. Set flag to clear out Unbound pfb_dnsbl.conf file.
- if (empty($lists_dnsbl_all)) {
+ if (empty($lists_dnsbl_all) && !$pfb['save']) {
pfb_logger("\nClearing all DNSBL Feeds... ", 1);
$pfb['domain_clear'] = TRUE;
$pfb_output = @fopen("{$pfb['dnsbl_file']}.conf", 'w');
diff --git a/pkg_config.10.xml b/pkg_config.10.xml
index c3c70cdc..71dc8e2f 100644
--- a/pkg_config.10.xml
+++ b/pkg_config.10.xml
@@ -118,7 +118,7 @@
<category>Security</category>
<pkginfolink>https://forum.pfsense.org/index.php?topic=102470.0</pkginfolink>
<config_file>https://packages.pfsense.org/packages/config/pfblockerng/pfblockerng.xml</config_file>
- <version>2.0.5</version>
+ <version>2.0.6</version>
<status>RELEASE</status>
<required_version>2.2</required_version>
<maintainer>BBcan177@gmail.com</maintainer>