diff options
author | jim-p <jimp@pfsense.org> | 2013-12-12 14:31:32 -0500 |
---|---|---|
committer | jim-p <jimp@pfsense.org> | 2013-12-12 14:32:02 -0500 |
commit | 940ef0e3bd2e95f43e0eafed01e8b20b08cc20c1 (patch) | |
tree | 8287be47ed38ff5d2189ddc3bec6100394482faf /etc/inc/filter_log.inc | |
parent | aebf41dfa424604315e42bf0cc3ca545760989ea (diff) | |
download | pfsense-940ef0e3bd2e95f43e0eafed01e8b20b08cc20c1.zip pfsense-940ef0e3bd2e95f43e0eafed01e8b20b08cc20c1.tar.gz |
Fix parsing of the rule number in the pf log on FreeBSD 10.x, part of Bug #2122
Diffstat (limited to 'etc/inc/filter_log.inc')
-rw-r--r-- | etc/inc/filter_log.inc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/etc/inc/filter_log.inc b/etc/inc/filter_log.inc index 31d3f60..7160c10 100644 --- a/etc/inc/filter_log.inc +++ b/etc/inc/filter_log.inc @@ -154,7 +154,9 @@ function parse_filter_line($line) { $flent['interface'] = convert_real_interface_to_friendly_descr($flent['realint']); $tmp = explode("/", $rule); - $flent['rulenum'] = $tmp[0]; + // Format of the rule number in FreeBSD 9.x and later seems to be X..Y where X is the matched rule and Y is the maximum possible rule number. + $rulenum_parts = explode("..", $tmp[0]); + $flent['rulenum'] = $rulenum_parts[0]; $proto = array(" ", "(?)"); /* Attempt to determine the protocol, based on several possible patterns. |