Skip to content

Commit

Permalink
Fixed an issue with wrong timezones being used for EPOCH calculation.
Browse files Browse the repository at this point in the history
  • Loading branch information
mitsuhiko committed Feb 22, 2012
1 parent 249a517 commit 59f3bf7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
8 changes: 8 additions & 0 deletions CHANGES
@@ -1,6 +1,14 @@
It's Dangerous Changelog
------------------------

Version 0.12
~~~~~~~~~~~~

- Fixed a problem with the local timezone being used for the epoch
calculation. This might invalidate some of your signatures if you
were not running in UTC timezone. You can revert to the old behavior
by monkey patching itsdangerous.EPOCH.

Version 0.11
~~~~~~~~~~~~

Expand Down
3 changes: 2 additions & 1 deletion itsdangerous.py
Expand Up @@ -27,7 +27,8 @@
import json as simplejson


EPOCH = time.mktime((2011, 1, 1, 0, 0, 0, 0, 0, 0))
# 2011/01/01 in UTC
EPOCH = 1293840000


def constant_time_compare(val1, val2):
Expand Down

0 comments on commit 59f3bf7

Please sign in to comment.