From a1f148f8e001567775012baa64ad306eb7c1c194 Mon Sep 17 00:00:00 2001 From: "R. Richard" Date: Fri, 7 Jun 2019 15:10:29 +0200 Subject: [PATCH] Rename variable to be more precise --- solvable/src/webservice/crypto.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/solvable/src/webservice/crypto.py b/solvable/src/webservice/crypto.py index 27ed1f5..051ff22 100644 --- a/solvable/src/webservice/crypto.py +++ b/solvable/src/webservice/crypto.py @@ -9,9 +9,9 @@ class PasswordHasher: return PasswordHasher.scrypt(password, salt).hex()+salt.hex() @staticmethod - def verify(password, hashdigest): - salt = bytes.fromhex(hashdigest[64:]) - hashdigest = bytes.fromhex(hashdigest[:64]) + def verify(password, salted_hash): + salt = bytes.fromhex(salted_hash[64:]) + hashdigest = bytes.fromhex(salted_hash[:64]) return PasswordHasher.scrypt(password, salt) == hashdigest @staticmethod