]> git.ipfire.org Git - people/stevee/ipfire-2.x.git/commitdiff
guardian: Fix message forwarding to responsible handlers.
authorStefan Schantl <stefan.schantl@ipfire.org>
Fri, 16 Jan 2015 12:06:08 +0000 (13:06 +0100)
committerStefan Schantl <stefan.schantl@ipfire.org>
Fri, 16 Jan 2015 12:06:08 +0000 (13:06 +0100)
config/guardian/guardian

index 8d38e3f18388c93b7b9765bc334ae1469028074c..87f98b05da1d65495d3eeadc5d65571d673cf7a9 100644 (file)
@@ -205,7 +205,7 @@ while () {
                # Logfiles with a single line are pretty easy to handle.
                } else {
                        # Get log message.
-                       my $message = <FILE>;
+                       $message = <FILE>;
 
                        # Remove newline.
                        chomp $message,
@@ -247,7 +247,7 @@ while () {
 ## Function to detect SSH-Bruteforce Attacks.
 #
 sub handle_ssh ($) {
-       my $message = $_[0];
+       my $message = @_[0];
 
        # Check for failed password attempts.
        if ($message =~/.*sshd.*Failed password for .* from (\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}).*/) {
@@ -291,7 +291,7 @@ sub handle_snort (@) {
 ## Function to detect HTTPD Login-Bruteforce attempts.
 #
 sub handle_httpd ($) {
-       my $message = $_[0];
+       my $message = @_[0];
 
        # This should catch Bruteforce Attacks on the WUI
        if ($message =~ /.*\[error\] \[client (\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})\] user(.*) not found:.*/) {