ok -- fixed package was uploaded to sid/unstable which should close the bug there. To don't mess with creating packages for all releases please use following snippet (while being root), which you can also download from http://www.onerussian.com/Linux/deb/fail2ban-leapyear-autopatch.sh or here it is in its entirety ---------------------------------------- cd / && cat <<EOF | patch -p0 && pycentral pkginstall fail2ban && /etc/init.d/fail2ban restart --- /usr/share/fail2ban/server/datestrptime.py 2008/01/16 22:55:04 645 +++ /usr/share/fail2ban/server/datestrptime.py 2008/01/16 22:55:04 645 @@ -129,7 +129,14 @@ except ValueError: # Try to convert date string to 'C' locale conv = self.convertLocale(dateMatch.group()) - date = list(time.strptime(conv, self.getPattern())) + try: + date = list(time.strptime(conv, self.getPattern())) + except ValueError: + # Try to add the current year to the pattern. Should fix + # the "Feb 29" issue. + conv += " %s" % MyTime.gmtime()[0] + pattern = "%s %%Y" % self.getPattern() + date = list(time.strptime(conv, pattern)) if date[0] < 2000: # There is probably no year field in the logs date[0] = MyTime.gmtime()[0]
EOF ---------------------------------------- Enjoy the rare 29th of Feb ;-) On Fri, 29 Feb 2008, [EMAIL PROTECTED] wrote: > > Could you try this patch please? > > http://fail2ban.svn.sourceforge.net/viewvc/fail2ban/branches/FAIL2BAN-0_8/server/datetemplate.py?r1=645&r2=652&view=patch&pathrev=652 > The patch works fine, except in 0.7.5 the function is in datestrptime.py. -- Yaroslav Halchenko Research Assistant, Psychology Department, Rutgers-Newark Student Ph.D. @ CS Dept. NJIT Office: (973) 353-5440x263 | FWD: 82823 | Fax: (973) 353-1171 101 Warren Str, Smith Hall, Rm 4-105, Newark NJ 07102 WWW: http://www.linkedin.com/in/yarik
signature.asc
Description: Digital signature

