diff options
Diffstat (limited to 'config/countryblock/countryblock.inc')
-rw-r--r-- | config/countryblock/countryblock.inc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/config/countryblock/countryblock.inc b/config/countryblock/countryblock.inc index f8335d53..f67fd76f 100644 --- a/config/countryblock/countryblock.inc +++ b/config/countryblock/countryblock.inc @@ -103,8 +103,10 @@ function php_install_command_cb() exec("cp /tmp/interfaces.txt /usr/local/www/packages/countryblock/interfaces.txt"); unlink_if_exists("/tmp/interfaces.txt"); - exec("cp /tmp/CIDR.php /usr/local/www/packages/countryblock/CIDR.tar.gz"); - unlink_if_exists("/tmp/CIDR.php"); + exec("/usr/bin/fetch -o /tmp https://raw.github.com/tommyboy180/pfsense-bin/2812cb9e1c9357bbf2027eff82096773bc4ddc5d/countryblock/CIDR.tar.gz"); + + exec("cp /tmp/CIDR.tar.gz /usr/local/www/packages/countryblock/CIDR.tar.gz"); + unlink_if_exists("/tmp/CIDR.tar.gz"); exec("tar xzf /usr/local/www/packages/countryblock/CIDR.tar.gz -C /usr/local/www/packages/countryblock/CIDR"); exec("rm /usr/local/www/packages/countryblock/CIDR.tar.gz"); @@ -112,7 +114,6 @@ function php_install_command_cb() exec("mkdir /usr/local/www/packages/countryblock/lists"); exec("touch /usr/local/www/packages/countryblock/lists/countries.txt"); - conf_mount_ro(); config_unlock(); } @@ -127,6 +128,7 @@ function deinstall_command_cb() exec("rm -R /usr/local/www/packages/countryblock/countryblocks"); exec("rm -R /usr/local/www/packages/countryblock"); exec("rm /usr/local/etc/rc.d/countryblock.sh"); + exec("rm /usr/local/pkg/pf/countryblock.sh"); exec("pfctl -t countryblock -T kill"); exec("sed -i -e '/countryblock/d' /tmp/rules.debug"); exec("pfctl -o basic -f /tmp/rules.debug"); |