diff -U0 fail2ban-0.8.10/ChangeLog.mailx fail2ban-0.8.10/ChangeLog --- fail2ban-0.8.10/ChangeLog.mailx 2013-08-28 11:57:02.631137995 -0600 +++ fail2ban-0.8.10/ChangeLog 2013-08-28 11:58:10.150945945 -0600 @@ -23,0 +24,3 @@ + Rolf Fokkens + * action.d/dshield.conf and complain.conf -- reorder mailx arguements. + https://bugzilla.redhat.com/show_bug.cgi?id=998020 diff -up fail2ban-0.8.10/config/action.d/complain.conf.mailx fail2ban-0.8.10/config/action.d/complain.conf --- fail2ban-0.8.10/config/action.d/complain.conf.mailx 2013-06-12 11:21:12.000000000 -0600 +++ fail2ban-0.8.10/config/action.d/complain.conf 2013-08-28 11:57:02.631137995 -0600 @@ -58,7 +58,7 @@ actioncheck = actionban = ADDRESSES=`whois | perl -e 'while () { next if /^changed|@(ripe|apnic)\.net/io; $m += (/abuse|trouble:|report|spam|security/io?3:0); if (/([a-z0-9_\-\.+]+@[a-z0-9\-]+(\.[[a-z0-9\-]+)+)/io) { while (s/([a-z0-9_\-\.+]+@[a-z0-9\-]+(\.[[a-z0-9\-]+)+)//io) { if ($m) { $a{lc($1)}=$m } else { $b{lc($1)}=$m } } $m=0 } else { $m && --$m } } if (%%a) {print join(",",keys(%%a))} else {print join(",",keys(%%b))}'` IP= if [ ! -z "$ADDRESSES" ]; then - (printf %%b "\n"; date '+Note: Local timezone is %%z (%%Z)'; grep '' ) | "Abuse from " $ADDRESSES + (printf %%b "\n"; date '+Note: Local timezone is %%z (%%Z)'; grep '' ) | "Abuse from " $ADDRESSES fi # Option: actionunban diff -up fail2ban-0.8.10/config/action.d/dshield.conf.mailx fail2ban-0.8.10/config/action.d/dshield.conf --- fail2ban-0.8.10/config/action.d/dshield.conf.mailx 2013-06-12 11:21:12.000000000 -0600 +++ fail2ban-0.8.10/config/action.d/dshield.conf 2013-08-28 11:57:02.632137993 -0600 @@ -39,7 +39,7 @@ actionstart = # Values: CMD # actionstop = if [ -f .buffer ]; then - cat .buffer | "FORMAT DSHIELD USERID TZ `date +%%z | sed 's/\([+-]..\)\(..\)/\1:\2/'` Fail2Ban" + cat .buffer | "FORMAT DSHIELD USERID TZ `date +%%z | sed 's/\([+-]..\)\(..\)/\1:\2/'` Fail2Ban" date +%%s > .lastsent fi rm -f .buffer .first @@ -80,7 +80,7 @@ actionban = TZONE=`date +%%z | sed 's/\( LASTREPORT=$(($NOW - `cat .lastsent`)) LINES=$( wc -l .buffer | awk '{ print $1 }' ) if [ $LINES -ge && $LASTREPORT -gt ] || [ $LOGAGE -gt ]; then - cat .buffer | "FORMAT DSHIELD USERID TZ $TZONE Fail2Ban" + cat .buffer | "FORMAT DSHIELD USERID TZ $TZONE Fail2Ban" rm -f .buffer .first echo $NOW > .lastsent fi @@ -95,7 +95,7 @@ actionunban = if [ -f .first ]; NOW=`date +%%s` LOGAGE=$(($NOW - `cat .first`)) if [ $LOGAGE -gt ]; then - cat .buffer | "FORMAT DSHIELD USERID TZ `date +%%z | sed 's/\([+-]..\)\(..\)/\1:\2/'` Fail2Ban" + cat .buffer | "FORMAT DSHIELD USERID TZ `date +%%z | sed 's/\([+-]..\)\(..\)/\1:\2/'` Fail2Ban" rm -f .buffer .first echo $NOW > .lastsent fi diff -up fail2ban-0.8.10/THANKS.mailx fail2ban-0.8.10/THANKS --- fail2ban-0.8.10/THANKS.mailx 2013-08-28 11:57:02.631137995 -0600 +++ fail2ban-0.8.10/THANKS 2013-08-28 11:58:34.542879375 -0600 @@ -38,6 +38,7 @@ Patrick Börjesson Raphaël Marichez René Berber Robert Edeker +Rolf Fokkens Russell Odom Sireyessire silviogarbes