hide user password on user creation
This commit is contained in:
parent
4f77cc464f
commit
f54993e5de
2
auth.py
2
auth.py
|
@ -14,7 +14,7 @@ def authenticate(username, hashed_password, pwdb):
|
||||||
return hashed_password == pwdb[username]
|
return hashed_password == pwdb[username]
|
||||||
|
|
||||||
def add_user(username, pwdb):
|
def add_user(username, pwdb):
|
||||||
pwdb[username] = pwhash(input(f'Enter password for {username}: '))
|
pwdb[username] = pwhash(getpass(f'Enter password for {username}: '))
|
||||||
return pwdb
|
return pwdb
|
||||||
|
|
||||||
def read_pwdb(PWDB_PATH):
|
def read_pwdb(PWDB_PATH):
|
||||||
|
|
Loading…
Reference in a new issue