From 94a84b4c2f78a2375fae3460169cb161b3d702a6 Mon Sep 17 00:00:00 2001 From: Jon Bergli Heier Date: Sat, 13 Aug 2011 15:37:30 +0200 Subject: Fixed generating session IDs. --- session.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/session.py b/session.py index 9928992..0787be8 100644 --- a/session.py +++ b/session.py @@ -8,7 +8,7 @@ class Session(object): cookie = Cookie.SimpleCookie(environ['HTTP_COOKIE'] if 'HTTP_COOKIE' in environ else None) sessionid = cookie.get('sessionid') if not sessionid: - sessionid = hashlib.sha1(str(time.time) + environ['REMOTE_ADDR']).hexdigest() + sessionid = hashlib.sha1(str(time.time()) + environ['REMOTE_ADDR']).hexdigest() cookie['sessionid'] = sessionid start_response('302 Found', [ ('Set-Cookie', cookie['sessionid'].OutputString()), -- cgit v1.2.3