diff --git a/secutils.py b/secutils.py new file mode 100644 index 0000000..cdaca71 --- /dev/null +++ b/secutils.py @@ -0,0 +1,6 @@ +from hashlib import sha256 + + +def hash_password(password: str): + """Hash a password for storing.""" + return sha256(password.encode("utf-8"), usedforsecurity=True).hexdigest()