Message226056
The cookielib module uses time.time(), which produces a timestamp in the local timezone (as read from the system time?), as the timestamp against which expiration dates in cookies are compared.
However, typical usage of HTTP cookies would be specifying the expiration date in UTC. This assumption seems to be supported for example by the inclusion of cookielib.http2time, which (only) supports UTC timestamps.
This behaviour is also included in e.g. MozillaCookieJar, which (erroneously) excludes cookies from being saved/loaded based on the local timestamp from time.time().
See the attached file for a small example where the check if a cookie is expired against a UTC time is correct but the check against local time fails (simulating the behaviour of the cookielib module). |
|
Date |
User |
Action |
Args |
2014-08-29 10:00:50 | regu0004 | set | recipients:
+ regu0004 |
2014-08-29 10:00:50 | regu0004 | set | messageid: <1409306450.24.0.723741077293.issue22296@psf.upfronthosting.co.za> |
2014-08-29 10:00:50 | regu0004 | link | issue22296 messages |
2014-08-29 10:00:49 | regu0004 | create | |
|