From 9d3f03d3fea13ff965f6541cbbd8ba54ef79871f Mon Sep 17 00:00:00 2001 From: lostcontrol Date: Wed, 5 Sep 2007 20:43:47 +0000 Subject: [PATCH] - Fixed timezone bug with epoch date template. Thanks to Michael Hanselmann git-svn-id: https://fail2ban.svn.sourceforge.net/svnroot/fail2ban/branches/FAIL2BAN-0_8@618 a942ae1a-1317-0410-a47c-b1dcaea8d605 --- CHANGELOG | 2 ++ server/dateepoch.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG b/CHANGELOG index b5d4f549..0d3063b7 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -12,6 +12,8 @@ ver. 0.8.2 (2007/??/??) - stable - Fixed named filter. Thanks to Yaroslav Halchenko - Fixed wrong path for apache-auth in jail.conf. Thanks to Vincent Deffontaines +- Fixed timezone bug with epoch date template. Thanks to + Michael Hanselmann ver. 0.8.1 (2007/08/14) - stable ---------- diff --git a/server/dateepoch.py b/server/dateepoch.py index b6ee14d0..4d9eeb23 100644 --- a/server/dateepoch.py +++ b/server/dateepoch.py @@ -40,5 +40,5 @@ class DateEpoch(DateTemplate): dateMatch = self.matchDate(line) if dateMatch: # extract part of format which represents seconds since epoch - date = list(time.gmtime(float(dateMatch.group()))) + date = list(time.localtime(float(dateMatch.group()))) return date