split->partition, thanks Ricardo

This commit is contained in:
mdipierro
2013-03-11 14:28:48 -05:00
parent 3e550b3e97
commit fd4c775710
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -1 +1 @@
Version 2.4.2-stable+timestamp.2013.03.11.14.22.04
Version 2.4.2-stable+timestamp.2013.03.11.14.27.56
+2 -2
View File
@@ -1789,8 +1789,8 @@ class Auth(object):
if basic_auth_realm:
raise http_401
return (True, False, False)
(username, password) = base64.b64decode(basic[6:]).split(':')
is_valid_user = self.login_bare(username, password)
(username, sep, password) = base64.b64decode(basic[6:]).partition(':')
is_valid_user = sep and self.login_bare(username, password)
if not is_valid_user and basic_auth_realm:
raise http_401
return (True, True, is_valid_user)