[Logwatch] Logwatch 4.3 Issues

David Zaroski dez@geekgadgets.org
Mon, 13 Jan 2003 10:49:33 -0700 (MST)


On Mon, 13 Jan 2003, Dino Nardini wrote:

DN>I've just upgraded to logwatch 4.3 on RedHat 7.2 servers, and ran into the 
DN>following issue:
DN>
DN>  --------------------- ftpd-messages Begin ------------------------
DN>
DN>syntax error at /etc/log.d/scripts/services/ftpd-messages line 70, near "elsif"
DN>syntax error at /etc/log.d/scripts/services/ftpd-messages line 74, near "}"
DN>Execution of /etc/log.d/scripts/services/ftpd-messages aborted due to 
DN>compilation errors.
DN>
DN>  ---------------------- ftpd-messages End -------------------------

Got the same message here.  Just looks like some misplaced brackets, this should fix it:

[begin diff]

*** ftpd-messages~      2003-01-12 21:31:37.000000000 -0700
--- ftpd-messages       2003-01-13 10:40:45.000000000 -0700
***************
*** 67,76 ****
     } elsif ( ($Host,$User,$IP) = ( $ThisLine =~ /(.*)\: (.*)\: SITE .* \[(.*)\] tried to/) ) {
        $Temp = "   " . $Host . " ($IP): " . $User . " - ";
        $SecurityViolations{$Temp}++;
!    elsif ( ($Host,$IP) = ( $ThisLine =~ /^FTP LOGIN FAILED \(cannot set guest privileges\) for ([^ ]+) \[(.*)\], ftp$/ ) ) {
        $Temp = "   " . $Host . " (" . $IP . "): - ";
        $RefusedAnonLogins{$Temp}++;
-    }
     } else {
        # Report any unmatched entries...
        push @OtherList,$ThisLine;
--- 67,75 ----
     } elsif ( ($Host,$User,$IP) = ( $ThisLine =~ /(.*)\: (.*)\: SITE .* \[(.*)\] tried to/) ) {
        $Temp = "   " . $Host . " ($IP): " . $User . " - ";
        $SecurityViolations{$Temp}++;
!    } elsif ( ($Host,$IP) = ( $ThisLine =~ /^FTP LOGIN FAILED \(cannot set guest privileges\) for ([^ ]+) \[(.*)\], ftp$/ ) ) {
        $Temp = "   " . $Host . " (" . $IP . "): - ";
        $RefusedAnonLogins{$Temp}++;
     } else {
        # Report any unmatched entries...
        push @OtherList,$ThisLine;

[end diff]

.....Dave