summaryrefslogtreecommitdiff
path: root/src/leap
diff options
context:
space:
mode:
Diffstat (limited to 'src/leap')
-rw-r--r--src/leap/bitmask/crypto/srpregister.py3
-rw-r--r--src/leap/bitmask/gui/wizard.py4
2 files changed, 3 insertions, 4 deletions
diff --git a/src/leap/bitmask/crypto/srpregister.py b/src/leap/bitmask/crypto/srpregister.py
index 5c0a8efc..61f1899a 100644
--- a/src/leap/bitmask/crypto/srpregister.py
+++ b/src/leap/bitmask/crypto/srpregister.py
@@ -108,7 +108,8 @@ class SRPRegister(QtCore.QObject):
:rparam: (ok, request)
"""
- username = username.lower()
+ username = username.lower().encode('utf-8')
+ password = password.encode('utf-8')
salt, verifier = self._srp.create_salted_verification_key(
username,
diff --git a/src/leap/bitmask/gui/wizard.py b/src/leap/bitmask/gui/wizard.py
index 6ba65410..e9c1d86c 100644
--- a/src/leap/bitmask/gui/wizard.py
+++ b/src/leap/bitmask/gui/wizard.py
@@ -226,9 +226,7 @@ class Wizard(QtGui.QWizard):
self._registration_finished)
threads.deferToThread(
- partial(register.register_user,
- username.encode("utf8"),
- password.encode("utf8")))
+ partial(register.register_user, username, password))
self._username = username
self._password = password