diff options
author | David Baker <dave@matrix.org> | 2016-11-03 10:42:14 +0000 |
---|---|---|
committer | David Baker <dave@matrix.org> | 2016-11-03 10:42:14 +0000 |
commit | 9084720993c3481142a256729aa49de592ba21eb (patch) | |
tree | f09b1f2b56a48685574207e5761bbc36059273be /synapse/handlers/auth.py | |
parent | Merge pull request #1190 from matrix-org/markjh/media_cors (diff) | |
download | synapse-9084720993c3481142a256729aa49de592ba21eb.tar.xz |
Don't error on non-ascii passwords
Diffstat (limited to '')
-rw-r--r-- | synapse/handlers/auth.py | 2 |
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): |