I just copied over your code and noticed that the end of
your regular expression (the "/" character) runs across a
newline. Once I moved that back up to this:
next unless
/Sig:\s*(\d+)\s+Subsig:\s*(\d+)\s+Sev:\s*(\d+)([^\[]+)\[([\d\.]+):(\d+)\s*->\s*([\d\.]+):(\d+)/;
$x is incremented. I wonder if that's your problem.
Dave
On Wed, 24 Sep 2008 01:30:22 -0400
"Stephen Reese" <[EMAIL PROTECTED]> wrote:
Hello Stephen,
I think the problem might be with your regular
expression and not $x.
If your regular expression does not match the current
line then every line
will be skipped.
What does the line that is being processed look like?
Dave
Here are two lines from the log file.
Sep 24 00:41:13 172.16.2.1 184512: 3725router: Sep 24
04:56:58:
%IPS-4-SIGNATURE: Sig:3051 Subsig:1 Sev:4 TCP Connection
Window Size
DoS [71.7.229.205:4693 -> 68.156.62.111:49613]
Sep 23 21:11:58 172.16.2.1 180743: 3725router: Sep 24
01:27:10:
%IPS-4-SIGNATURE: Sig:2157 Subsig:1 Sev:4 ICMP Hard
Error DoS
[91.97.234.152:0 -> 68.156.62.111:0]
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/