diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2006-10-07 05:11:49 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2006-10-07 05:11:49 +0000 |
commit | e7c0e87ea83d3f74b77d2005ccfa80feee72d4b4 (patch) | |
tree | ea2ec625afd0b8de276cc8edc1059f08f05e1af2 | |
parent | 712adaf673ea2f0e3d5a10c5024d22b13beed0b6 (diff) | |
download | pfsense-packages-e7c0e87ea83d3f74b77d2005ccfa80feee72d4b4.tar.gz pfsense-packages-e7c0e87ea83d3f74b77d2005ccfa80feee72d4b4.tar.bz2 pfsense-packages-e7c0e87ea83d3f74b77d2005ccfa80feee72d4b4.zip |
Woops, reverse the numbers.
-rw-r--r-- | packages/snort/snort.inc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/snort/snort.inc b/packages/snort/snort.inc index 039a03a7..fb0b7343 100644 --- a/packages/snort/snort.inc +++ b/packages/snort/snort.inc @@ -489,9 +489,9 @@ function get_snort_alert($ip) { $file_split = split("\n", file_get_contents("/var/log/snort/alert")); foreach($file_split as $fileline) { if (preg_match("/\[\*\*\] (\[.*\]) (.*) (\[\*\*\])/", $fileline, $matches)) - $alert_title = $matches[0]; + $alert_title = $matches[2]; if (preg_match("/(\b(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\b)/", $fileline, $matches)) - $alert_ip = $matches[2]; + $alert_ip = $matches[0]; if($alert_ip == $ip) return $alert_title; } |