diff options
author | Nishant Limbachia <nishant@mnspace.net> | 2014-09-28 16:12:46 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2014-09-28 16:12:46 +0700 |
commit | 8d373c2d190cd5e6b0f9750b9232a8f6bb0020d8 (patch) | |
tree | 74a7a53659647d884dc1b122d1cdf9d2a6e21c1e | |
parent | 0e83480f1f9a9bc186348c6126b8b970240c1247 (diff) |
network/fail2ban: Updated for version 0.9.0.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
-rw-r--r-- | network/fail2ban/README.SBo | 6 | ||||
-rw-r--r-- | network/fail2ban/config/paths-slackware.conf | 34 | ||||
-rw-r--r-- | network/fail2ban/doinst.sh | 2 | ||||
-rw-r--r-- | network/fail2ban/fail2ban.SlackBuild | 18 | ||||
-rw-r--r-- | network/fail2ban/fail2ban.info | 6 | ||||
-rw-r--r-- | network/fail2ban/fail2ban.logrotate | 3 | ||||
-rw-r--r-- | network/fail2ban/patches/fail2banreader-logwarning-fix.patch | 11 | ||||
-rw-r--r-- | network/fail2ban/patches/jail.conf.patch | 11 | ||||
-rw-r--r-- | network/fail2ban/rc.fail2ban | 2 |
9 files changed, 82 insertions, 11 deletions
diff --git a/network/fail2ban/README.SBo b/network/fail2ban/README.SBo index 8f68e2c11e963..500a3cb342182 100644 --- a/network/fail2ban/README.SBo +++ b/network/fail2ban/README.SBo @@ -47,4 +47,8 @@ Upgraded to new version 0.8.8 Upgraded to new version 0.8.9, updated logrotate script. There have been quite a few new features and changes to conf files. 06/11/2013 -Upgraded to version 0.8.10.
\ No newline at end of file +Upgraded to version 0.8.10. +11/13/2013 +Upgraded to version 0.8.11 +09/25/2014 +Upgraded to version 0.9.0 diff --git a/network/fail2ban/config/paths-slackware.conf b/network/fail2ban/config/paths-slackware.conf new file mode 100644 index 0000000000000..81c66fac05020 --- /dev/null +++ b/network/fail2ban/config/paths-slackware.conf @@ -0,0 +1,34 @@ +# Slackware + +[INCLUDES] + +before = paths-common.conf + +after = paths-overrides.local + +[DEFAULT] + +syslog_mail = /var/log/maillog + +syslog_mail_warn = /var/log/syslog + +syslog_authpriv = /var/log/secure + +# syslog_auth = /var/log/auth.log +# +syslog_user = /var/log/syslog + +syslog_ftp = /var/log/syslog + +syslog_daemon = /var/log/messages + +syslog_local0 = /var/log/messages + +apache_error_log = /var/log/httpd/*error.log + +apache_access_log = /var/log/httpd/*access.log + +# Default for Slackware provided below, +# please change according to your proftpd config file. +proftpd_log = /var/log/proftpd.log + diff --git a/network/fail2ban/doinst.sh b/network/fail2ban/doinst.sh index f6a20b4af0755..74390be489e70 100644 --- a/network/fail2ban/doinst.sh +++ b/network/fail2ban/doinst.sh @@ -26,6 +26,8 @@ preserve_perms etc/rc.d/rc.fail2ban.new config etc/logrotate.d/fail2ban.new config etc/fail2ban/fail2ban.conf.new config etc/fail2ban/jail.conf.new +config etc/fail2ban/paths-common.conf.new +config etc/fail2ban/paths-slackware.conf.new for conf_file in etc/fail2ban/action.d/*.new; do config $conf_file diff --git a/network/fail2ban/fail2ban.SlackBuild b/network/fail2ban/fail2ban.SlackBuild index 964fae5803dcd..e210f7d712a48 100644 --- a/network/fail2ban/fail2ban.SlackBuild +++ b/network/fail2ban/fail2ban.SlackBuild @@ -3,7 +3,7 @@ # Slackware Package Build Script for fail2ban # Git Hub: https://github.com/fail2ban/fail2ban/ -# Copyright (c) 2008-2013, Nishant Limbachia, Hoffman Estates, IL, USA +# Copyright (c) 2008-2014, Nishant Limbachia, Hoffman Estates, IL, USA # <nishant _AT_ mnspace _DOT_ net> # All rights reserved. @@ -26,7 +26,7 @@ # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. PRGNAM="fail2ban" -VERSION=${VERSION:-0.8.11} +VERSION=${VERSION:-0.9.0} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} @@ -49,7 +49,9 @@ find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ -o -perm 511 \) -exec chmod 755 {} \; -o \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ - -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + +( cd fail2ban/client; patch -p0 < $CWD/patches/fail2banreader-logwarning-fix.patch ) python setup.py install --root=$PKG @@ -66,17 +68,23 @@ install -m 0644 man/jail.conf.5 $PKG/usr/man/man5 done ) +( cd $PKG/etc/fail2ban; patch -p0 < $CWD/patches/jail.conf.patch ) + find $PKG/usr/man -type f -exec gzip -9 {} \; for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done # install startup script install -D -m 0644 $CWD/rc.fail2ban $PKG/etc/rc.d/rc.fail2ban.new +install -D -m 0644 $CWD/config/paths-slackware.conf $PKG/etc/fail2ban/paths-slackware.conf.new + +# remove non-slackware specific stuff +rm -f $PKG/etc/fail2ban/paths-{debian,fedora,freebsd,osx}.conf.new # install logrotate script install -D -m 0644 $CWD/fail2ban.logrotate $PKG/etc/logrotate.d/fail2ban.new -# make directory for socket and pid file -mkdir -p $PKG/var/run/fail2ban +# make directory for socket, pid file & db file +mkdir -p $PKG/var/{run,lib}/fail2ban # remove /usr/share/doc rm -fr $PKG/usr/share/doc diff --git a/network/fail2ban/fail2ban.info b/network/fail2ban/fail2ban.info index 377aec2174a8b..73d0d45a0caf4 100644 --- a/network/fail2ban/fail2ban.info +++ b/network/fail2ban/fail2ban.info @@ -1,8 +1,8 @@ PRGNAM="fail2ban" -VERSION="0.8.11" +VERSION="0.9.0" HOMEPAGE="https://github.com/fail2ban/fail2ban/" -DOWNLOAD="https://github.com/fail2ban/fail2ban/releases/download/0.8.11/fail2ban-0.8.11.tar.gz" -MD5SUM="da14a0ebc8b6362a2290efd49db808aa" +DOWNLOAD="https://github.com/fail2ban/fail2ban/releases/download/0.9.0/fail2ban-0.9.0.tar.bz2" +MD5SUM="53fda22414d138f8bc010b33afc3547d" DOWNLOAD_x86_64="" MD5SUM_x86_64="" REQUIRES="" diff --git a/network/fail2ban/fail2ban.logrotate b/network/fail2ban/fail2ban.logrotate index 8af60998873d6..4521d28aeb56f 100644 --- a/network/fail2ban/fail2ban.logrotate +++ b/network/fail2ban/fail2ban.logrotate @@ -1,11 +1,12 @@ # 5/23/2013 - updated logrotate script based on suggestion by Sebastian Arcus # and official github documentation. +# 09/25/2014 - updated logrotate script for version 0.9.0 /var/log/fail2ban.log { weekly rotate 7 missingok nocompress postrotate - /usr/bin/fail2ban-client set logtarget /var/log/fail2ban.log 1>/dev/null || true + /usr/bin/fail2ban-client flushlogs 1>/dev/null || true endscript } diff --git a/network/fail2ban/patches/fail2banreader-logwarning-fix.patch b/network/fail2ban/patches/fail2banreader-logwarning-fix.patch new file mode 100644 index 0000000000000..a0a8547cc1e83 --- /dev/null +++ b/network/fail2ban/patches/fail2banreader-logwarning-fix.patch @@ -0,0 +1,11 @@ +--- fail2banreader.py.orig 2014-09-27 23:40:05.512547198 -0500 ++++ fail2banreader.py 2014-09-27 23:41:27.294412338 -0500 +@@ -45,7 +45,7 @@ + return ConfigReader.getOptions(self, "Definition", opts) + + def getOptions(self): +- opts = [["int", "loglevel", "INFO" ], ++ opts = [["string", "loglevel", "INFO" ], + ["string", "logtarget", "STDERR"], + ["string", "dbfile", "/var/lib/fail2ban/fail2ban.sqlite3"], + ["int", "dbpurgeage", 86400]] diff --git a/network/fail2ban/patches/jail.conf.patch b/network/fail2ban/patches/jail.conf.patch new file mode 100644 index 0000000000000..31a358ac5d1cb --- /dev/null +++ b/network/fail2ban/patches/jail.conf.patch @@ -0,0 +1,11 @@ +--- jail.conf.new.orig 2014-04-17 22:24:50.833320465 -0500 ++++ jail.conf.new 2014-04-17 22:25:12.317055028 -0500 +@@ -33,7 +33,7 @@ + [INCLUDES] + + #before = paths-disto.conf +-before = paths-debian.conf ++before = paths-slackware.conf + + # The DEFAULT allows a global definition of the options. They can be overridden + # in each jail afterwards. diff --git a/network/fail2ban/rc.fail2ban b/network/fail2ban/rc.fail2ban index 3022f989f0ac8..d32af3b656b27 100644 --- a/network/fail2ban/rc.fail2ban +++ b/network/fail2ban/rc.fail2ban @@ -1,6 +1,6 @@ #!/bin/sh # -# Copyright (c) 2008-2013, Nishant Limbachia, Hoffman Estates, IL, USA +# Copyright (c) 2008-2014, Nishant Limbachia, Hoffman Estates, IL, USA # <nishant _AT_ mnspace _DOT_ net> # /etc/rc.d/rc.fail2ban # |