summaryrefslogtreecommitdiff
path: root/src/leap
diff options
context:
space:
mode:
authordrebs <drebs@leap.se>2013-05-01 12:11:35 -0300
committerdrebs <drebs@leap.se>2013-05-01 12:11:35 -0300
commit718a10190b5da5eb9e63157658b4035822fb866e (patch)
tree1976ce139edff59da7da882f3488c897b667a98b /src/leap
parent30e8535d9af643d2ab722a4921ab52d94c2930dd (diff)
Fix HTTP request bug.
Base64 encoding returned a \n at the end of the string and that was causing trouble on the HTTP request when the token was added as an http header.
Diffstat (limited to 'src/leap')
-rw-r--r--src/leap/soledad/auth.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/leap/soledad/auth.py b/src/leap/soledad/auth.py
index 080bb806..a099c1a6 100644
--- a/src/leap/soledad/auth.py
+++ b/src/leap/soledad/auth.py
@@ -53,6 +53,6 @@ def _sign_request(self, method, url_query, params):
if 'token' in self._creds:
uuid, token = self._creds['token']
auth = '%s:%s' % (uuid, token)
- return [('Authorization', 'Token %s' % auth.encode('base64'))]
+ return [('Authorization', 'Token %s' % auth.encode('base64')[:-1])]
else:
return HTTPClientBase._sign_request(self, method, url_query, params)