summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
authorDavid Baker <dbkr@users.noreply.github.com>2016-11-03 11:21:07 +0000
committerGitHub <noreply@github.com>2016-11-03 11:21:07 +0000
commit9164bfa1c35c7c92b44feab8a40bd37d7c5b509d (patch)
treef09b1f2b56a48685574207e5761bbc36059273be /synapse
parentMerge pull request #1190 from matrix-org/markjh/media_cors (diff)
parentDon't error on non-ascii passwords (diff)
downloadsynapse-9164bfa1c35c7c92b44feab8a40bd37d7c5b509d.tar.xz
Merge pull request #1191 from matrix-org/dbkr/non_ascii_passwords
Don't error on non-ascii passwords
Diffstat (limited to 'synapse')
-rw-r--r--synapse/handlers/auth.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/handlers/auth.py b/synapse/handlers/auth.py
index 3635521230..3851b35889 100644
--- a/synapse/handlers/auth.py
+++ b/synapse/handlers/auth.py
@@ -653,7 +653,7 @@ class AuthHandler(BaseHandler):
         Returns:
             Hashed password (str).
         """
-        return bcrypt.hashpw(password + self.hs.config.password_pepper,
+        return bcrypt.hashpw(password.encode('utf8') + self.hs.config.password_pepper,
                              bcrypt.gensalt(self.bcrypt_rounds))
 
     def validate_hash(self, password, stored_hash):