[Checkins]
SVN: PluggableAuthService/trunk/plugins/CookieAuthHelper.py
Handle a foreign cookie gracefully
Wichert Akkerman
wichert at wiggy.net
Fri Apr 6 08:16:02 EDT 2007
Log message for revision 74033:
Handle a foreign cookie gracefully
Changed:
U PluggableAuthService/trunk/plugins/CookieAuthHelper.py
-=-
Modified: PluggableAuthService/trunk/plugins/CookieAuthHelper.py
===================================================================
--- PluggableAuthService/trunk/plugins/CookieAuthHelper.py 2007-04-06 11:29:31 UTC (rev 74032)
+++ PluggableAuthService/trunk/plugins/CookieAuthHelper.py 2007-04-06 12:16:01 UTC (rev 74033)
@@ -119,7 +119,11 @@
elif cookie and cookie != 'deleted':
cookie_val = decodestring(unquote(cookie))
- login, password = cookie_val.split(':')
+ try:
+ login, password = cookie_val.split(':')
+ except ValueError:
+ # Cookie is in a different format, so it is not ours
+ return creds
creds['login'] = login
creds['password'] = password
More information about the Checkins
mailing list