summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2013-04-02 12:54:22 -0400
committerjim-p <jimp@pfsense.org>2013-04-02 12:54:22 -0400
commit068e6891e2c2c03a427e477d03d309e1f9d47255 (patch)
tree8532efe60031c38c940963f4792cfcc9838d6b58
parent643bc7b01fc53409872728d0c1b2955cfe34bfcf (diff)
downloadpfsense-068e6891e2c2c03a427e477d03d309e1f9d47255.zip
pfsense-068e6891e2c2c03a427e477d03d309e1f9d47255.tar.gz
Show a little indicator icon if the direction of a firewall log entry is OUT, rather than the usual 'in'. No indicator is shown for IN.
-rw-r--r--etc/inc/filter_log.inc4
-rwxr-xr-xusr/local/www/diag_logs_filter.php6
2 files changed, 7 insertions, 3 deletions
diff --git a/etc/inc/filter_log.inc b/etc/inc/filter_log.inc
index 85548da..db0131c 100644
--- a/etc/inc/filter_log.inc
+++ b/etc/inc/filter_log.inc
@@ -136,9 +136,9 @@ function collapse_filter_lines($logarr) {
function parse_filter_line($line) {
global $config, $g;
$log_split = "";
- preg_match("/(.*)\s(.*)\spf:\s.*\srule\s(.*)\(match\)\:\s(.*)\s\w+\son\s(\w+)\:\s\((.*)\)\s(.*)\s>\s(.*)\:\s(.*)/", $line, $log_split);
+ preg_match("/(.*)\s(.*)\spf:\s.*\srule\s(.*)\(match\)\:\s(.*)\s(\w+)\son\s(\w+)\:\s\((.*)\)\s(.*)\s>\s(.*)\:\s(.*)/", $line, $log_split);
- list($all, $flent['time'], $host, $rule, $flent['act'], $flent['realint'], $details, $src, $dst, $leftovers) = $log_split;
+ list($all, $flent['time'], $host, $rule, $flent['act'], $flent['direction'], $flent['realint'], $details, $src, $dst, $leftovers) = $log_split;
list($flent['srcip'], $flent['srcport']) = parse_ipport($src);
list($flent['dstip'], $flent['dstport']) = parse_ipport($dst);
diff --git a/usr/local/www/diag_logs_filter.php b/usr/local/www/diag_logs_filter.php
index edb43ca..c24f67e 100755
--- a/usr/local/www/diag_logs_filter.php
+++ b/usr/local/www/diag_logs_filter.php
@@ -325,7 +325,11 @@ include("head.inc");
<img border="0" src="<?php echo find_action_image($filterent['act']);?>" width="11" height="11" align="middle" alt="<?php echo $filterent['act'];?>" title="<?php echo $filterent['act'];?>" />
<?php if ($filterent['count']) echo $filterent['count'];?></a></center></td>
<td class="listMRr" nowrap="nowrap"><?php echo htmlspecialchars($filterent['time']);?></td>
- <td class="listMRr" nowrap="nowrap"><?php echo htmlspecialchars($filterent['interface']);?></td>
+ <td class="listMRr" nowrap="nowrap">
+ <?php if ($filterent['direction'] == "out"): ?>
+ <img border="0" src="/themes/<?= $g['theme']; ?>/images/icons/out.gif" alt="Direction=OUT" title="Direction=OUT"/>
+ <?php endif; ?>
+ <?php echo htmlspecialchars($filterent['interface']);?></td>
<?php
if ($config['syslog']['filterdescriptions'] === "1")
echo("<td class=\"listMRr\" nowrap=\"nowrap\">".find_rule_by_number_buffer($filterent['rulenum'],$filterent['act'])."</td>");
OpenPOWER on IntegriCloud