aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbmeeks8 <bmeeks8@bellsouth.net>2014-09-07 17:55:47 -0400
committerbmeeks8 <bmeeks8@bellsouth.net>2014-09-07 17:55:47 -0400
commit98d54bcb91d1d9775c28f566655d49b4d9962bb1 (patch)
tree2469bf3926f7b7c42c3ef7bcf2dec0e9b13514b8
parent4f8c39dad0c17ef2e8f26c84fdf22c6f1066127e (diff)
downloadpfsense-packages-98d54bcb91d1d9775c28f566655d49b4d9962bb1.tar.gz
pfsense-packages-98d54bcb91d1d9775c28f566655d49b4d9962bb1.tar.bz2
pfsense-packages-98d54bcb91d1d9775c28f566655d49b4d9962bb1.zip
Fix typo in tooltip & ignore invalid block.log entries when dispaying.
-rw-r--r--config/suricata/suricata_blocked.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/config/suricata/suricata_blocked.php b/config/suricata/suricata_blocked.php
index c29d5745..842d4073 100644
--- a/config/suricata/suricata_blocked.php
+++ b/config/suricata/suricata_blocked.php
@@ -208,7 +208,7 @@ if ($savemsg) {
<input name="download" type="submit" class="formbtns" value="Download" title="<?=gettext("Download list of blocked hosts as a gzip archive");?>"/>
&nbsp;<?php echo gettext("All blocked hosts will be saved."); ?>&nbsp;&nbsp;
<input name="remove" type="submit" class="formbtns" value="Clear" title="<?=gettext("Remove blocks for all listed hosts");?>"
- onClick="return confirm('<?=gettext("Are you sure you want to remove all blocked hosts? Click OK to continue or CANCLE to quit.");?>');"/>&nbsp;
+ onClick="return confirm('<?=gettext("Are you sure you want to remove all blocked hosts? Click OK to continue or CANCEL to quit.");?>');"/>&nbsp;
<span class="red"><strong><?php echo gettext("Warning:"); ?></strong></span>&nbsp;<?php echo gettext("all hosts will be removed."); ?>
</td>
</tr>
@@ -260,8 +260,11 @@ if ($savemsg) {
/* 0 1 2 3 4 5 6 7 8 9 10 */
/* File format timestamp,action,sig_generator,sig_id,sig_rev,msg,classification,priority,proto,ip,port */
while (($fields = fgetcsv($fd, 1000, ',', '"')) !== FALSE) {
- if(count($fields) < 11)
+ if(count($fields) != 11) {
+ log_error("[suricata] ERROR: block.log entry failed to parse correctly with too many or not enough CSV entities, skipping this entry...");
+ log_error("[suricata] Failed block.log entry fields are: " . print_r($fields, true));
continue;
+ }
$fields[9] = inet_pton($fields[9]);
if (isset($tmpblocked[$fields[9]])) {
if (!is_array($src_ip_list[$fields[9]]))