diff options
-rw-r--r-- | config/countryblock/countryblock.inc | 2 | ||||
-rwxr-xr-x | config/countryblock/countryblock.tmp | 16 | ||||
-rw-r--r-- | config/countryblock/countryblock.xml | 7 | ||||
-rwxr-xr-x[-rw-r--r--] | config/countryblock/countryblock_if.tmp | 8 | ||||
-rw-r--r-- | config/countryblock/interfaces.txt | 1 | ||||
-rwxr-xr-x | pkg_config.7.xml | 2 | ||||
-rwxr-xr-x | pkg_config.8.xml | 2 | ||||
-rwxr-xr-x | pkg_config.8.xml.amd64 | 2 |
8 files changed, 27 insertions, 13 deletions
diff --git a/config/countryblock/countryblock.inc b/config/countryblock/countryblock.inc index e716f25b..46429563 100644 --- a/config/countryblock/countryblock.inc +++ b/config/countryblock/countryblock.inc @@ -84,6 +84,8 @@ function php_install_command_cb() unlink_if_exists("/tmp/purge.tmp"); exec("cp /tmp/whitelist.tmp /usr/local/www/packages/countryblock/whitelist.php"); unlink_if_exists("/tmp/whitelist.tmp"); + exec("cp /tmp/interfaces.txt /usr/local/www/packages/countryblock/interfaces.txt"); + unlink_if_exists("/tmp/interfaces.txt"); diff --git a/config/countryblock/countryblock.tmp b/config/countryblock/countryblock.tmp index f95c2e7c..785329a2 100755 --- a/config/countryblock/countryblock.tmp +++ b/config/countryblock/countryblock.tmp @@ -2586,12 +2586,16 @@ ob_end_clean(); - <u>Usage</u> + <p><u>Usage</u> <br/> - Check the country that you would like to block completely. Affects in & out traffic. - <br/><span style="color:red">Warning!</span> - Apply after every firewall change or state reset. Use at your own risk. - <br/><br/> - <input type="submit" name="formSubmit" value="Commit Countries" /> + Check the country that you would like to block completely. Choose if you want to block outbound access and if you want to log attempts. Click "Commit Countries" to store your settings. <br/> + When your settings are stored select "Enable Country Block" and press save to enable to package.<br /> + To run countryblock as a cron job use /usr/local/etc/rc.d/countryblock.sh <br /> + To whitelist a CIDR range press <a href="whitelist.php" target="_parent"><img src="../../themes/nervecenter/images/icons/icon_plus.gif" ALT="Manual"></a> and to specify interfaces press <a href="countryblock_if.php" target="_parent"><img src="../../themes/nervecenter/images/icons/icon_cablenic.gif" ALT="Manual"></a>. By default all interfaces are selected. <br /> + <span style="color:red">Warning!</span> - Apply after every firewall change or state reset. Use at your own risk. + <br/><br/> + <input type="submit" name="formSubmit" value="Commit Countries" /> + </p> </form> <br/> @@ -2630,7 +2634,7 @@ ob_end_clean(); </td> </tr> -</table> +</table><br /> <input type="submit" value="Save/Update"> </form> diff --git a/config/countryblock/countryblock.xml b/config/countryblock/countryblock.xml index 4edc4a6e..b89a38f5 100644 --- a/config/countryblock/countryblock.xml +++ b/config/countryblock/countryblock.xml @@ -41,7 +41,7 @@ <requirements>Active Internet</requirements> <faq>http://forum.pfsense.org/index.php/topic,25732.0.html</faq> <name>Country Block Settings</name> - <version>0.1.5</version> + <version>0.1.6</version> <title>Settings</title> <include_file>/usr/local/pkg/countryblock.inc</include_file> <menu> @@ -67,6 +67,11 @@ <additional_files_needed> <prefix>/usr/local/pkg/</prefix> <chmod>0755</chmod> + <item>http://www.pfsense.org/packages/config/countryblock/interfaces.txt</item> + </additional_files_needed> + <additional_files_needed> + <prefix>/usr/local/pkg/</prefix> + <chmod>0755</chmod> <item>http://www.pfsense.org/packages/config/countryblock/countryblock.inc</item> </additional_files_needed> <additional_files_needed> diff --git a/config/countryblock/countryblock_if.tmp b/config/countryblock/countryblock_if.tmp index 405e1aec..11a81414 100644..100755 --- a/config/countryblock/countryblock_if.tmp +++ b/config/countryblock/countryblock_if.tmp @@ -148,9 +148,11 @@ include("head.inc"); <?php if ($portname == $iface['if']) { ob_start(); + $resultsany = exec("cat interfaces.txt | grep any"); $results = exec("cat interfaces.txt | grep $portname"); ob_end_clean(); - if ($results == $portname) + + if ($results == $portname || $resultsany == any) echo "<input name='$portname' type='checkbox' value='$portname' checked/>$portname"; else echo "<input name='$portname' type='checkbox' value='$portname' />$portname"; @@ -174,8 +176,8 @@ include("head.inc"); <p><br> <input type="submit" class="formbtn" value="Save"> </p> - <p>Select the interfaces you want secured. </p> - <p>I <strong>highly</strong> recommend selecting <u>all</u> interfaces. <br> + <p>Select the interfaces you want secured. It's recommended to select all interfaces. </p> + <p>Default: All interfaces are seleted. <br> <br> </p> <p></p></td> diff --git a/config/countryblock/interfaces.txt b/config/countryblock/interfaces.txt new file mode 100644 index 00000000..124009d7 --- /dev/null +++ b/config/countryblock/interfaces.txt @@ -0,0 +1 @@ +any
\ No newline at end of file diff --git a/pkg_config.7.xml b/pkg_config.7.xml index 54440bfa..006d18f8 100755 --- a/pkg_config.7.xml +++ b/pkg_config.7.xml @@ -23,7 +23,7 @@ <pkginfolink>http://forum.pfsense.org/index.php/topic,25732.0.html</pkginfolink> <config_file>http://pfsense.org/packages/config/countryblock/countryblock.xml</config_file> <depends_on_package_base_url>http://files.pfsense.org/packages/7/All/</depends_on_package_base_url> - <version>0.1.5</version> + <version>0.1.6</version> <status>Beta</status> <required_version>1.2.2</required_version> <maintainer>tom@tomschaefer.org</maintainer> diff --git a/pkg_config.8.xml b/pkg_config.8.xml index 3ba5236b..c1e03811 100755 --- a/pkg_config.8.xml +++ b/pkg_config.8.xml @@ -26,7 +26,7 @@ <pkginfolink>http://forum.pfsense.org/index.php/topic,25732.0.html</pkginfolink> <config_file>http://pfsense.org/packages/config/countryblock/countryblock.xml</config_file> <depends_on_package_base_url>http://files.pfsense.org/packages/7/All/</depends_on_package_base_url> - <version>0.1.5</version> + <version>0.1.6</version> <status>Beta</status> <required_version>1.2.2</required_version> <maintainer>tom@tomschaefer.org</maintainer> diff --git a/pkg_config.8.xml.amd64 b/pkg_config.8.xml.amd64 index 152adf6f..c5c911c1 100755 --- a/pkg_config.8.xml.amd64 +++ b/pkg_config.8.xml.amd64 @@ -43,7 +43,7 @@ <pkginfolink>http://forum.pfsense.org/index.php/topic,25732.0.html</pkginfolink> <config_file>http://pfsense.org/packages/config/countryblock/countryblock.xml</config_file> <depends_on_package_base_url>http://files.pfsense.org/packages/amd64/8/All/</depends_on_package_base_url> - <version>0.1.5</version> + <version>0.1.6</version> <status>Beta</status> <required_version>1.2.2</required_version> <maintainer>tom@tomschaefer.org</maintainer> |