aboutsummaryrefslogtreecommitdiffstats
path: root/config/ipblocklist/ipblocklist.tmp
diff options
context:
space:
mode:
authorTom Schaefer <tom@tomschaefer.org>2010-08-19 23:31:07 -0400
committerTom Schaefer <tom@tomschaefer.org>2010-08-19 23:31:07 -0400
commitcb04733b4420ba7d590a2ab3aee1317f8e98cca9 (patch)
tree53d531de4656226bcb1bcb8661f260c90506020e /config/ipblocklist/ipblocklist.tmp
parentf7e327b49312454703f19f9ea587f033a0df4f1b (diff)
downloadpfsense-packages-cb04733b4420ba7d590a2ab3aee1317f8e98cca9.tar.gz
pfsense-packages-cb04733b4420ba7d590a2ab3aee1317f8e98cca9.tar.bz2
pfsense-packages-cb04733b4420ba7d590a2ab3aee1317f8e98cca9.zip
ipblocklist add logging option, stats, and added dependancy
modified: config/ipblocklist/convert-execute.sh modified: config/ipblocklist/ipblocklist.inc modified: config/ipblocklist/ipblocklist.tmp modified: config/ipblocklist/ipblocklist.xml new file: config/ipblocklist/p5-Net-CIDR-0.13.tbz new file: config/ipblocklist/perl-5.8.9_2.tbz modified: pkg_config.7.xml modified: pkg_config.8.xml modified: pkg_config.8.xml.amd64
Diffstat (limited to 'config/ipblocklist/ipblocklist.tmp')
-rwxr-xr-xconfig/ipblocklist/ipblocklist.tmp38
1 files changed, 35 insertions, 3 deletions
diff --git a/config/ipblocklist/ipblocklist.tmp b/config/ipblocklist/ipblocklist.tmp
index baa0ff09..3c07817b 100755
--- a/config/ipblocklist/ipblocklist.tmp
+++ b/config/ipblocklist/ipblocklist.tmp
@@ -1,5 +1,5 @@
<?php
- //Version 2.1
+ //Version 2.2
require_once('config.inc');
require("guiconfig.inc");
@@ -90,7 +90,22 @@ else {
echo "<input name='enable' type='checkbox' value='1'>\n";
}
?>
-
+<?php
+if(isset($_POST['formSubmit']))
+ {
+
+
+ if(isset($_POST['formlogging']))
+ {
+ exec("touch logging");
+ }
+ else
+ {
+ exec("rm logging");
+ }
+
+ }
+?>
<strong>Enable IP-Blocklist</strong><br><br>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
@@ -98,8 +113,17 @@ else {
<?php if ($savemsg_dnsb) print_info_box($savemsg_dnsb); ?>
</form>
+ <?php
+
+ if (file_exists("logging")) {
+ echo "<input name='formlogging' type='checkbox' value='Yes' checked/>";
+ } else {
+ echo "<input name='formlogging' type='checkbox' value='Yes'/>";
+ }
+?>
+ Enable Logging <input type="submit" name="formSubmit" value="Save" /><br />
<center>
- <iframe frameboarder=0 boarder=0 src="ipblocklist_list.php" name="lists" id="lists" width="100%" height="200">
+ <iframe frameboarder=0 boarder=0 src="ipblocklist_list.php" name="lists" id="lists" width="100%" height="200">
</iframe>
</center>
<br/>
@@ -130,6 +154,14 @@ else {
echo "<br/><span style='color:red'>";
echo $results;
echo "</span>";
+
+ //Get IP Count
+ echo "<br>You are blocking ";
+ ob_start();
+ $results = exec("pfctl -T show -t ipblocklist |grep -v -c Z");
+ ob_end_clean();
+ echo $results;
+ echo " IPs";
?>