Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added userdb
Binary file not shown.
6 changes: 5 additions & 1 deletion users.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import pickle
import hashlib
from getpass import getpass


class User:
def __init__(self, username, pwhash):
Expand All @@ -15,8 +17,10 @@ def create_hash(username, password):

def get_username_password():
username = input("Enter username: ")
password = input("Enter password: ")
# password = input("Enter password: ")
password = getpass()
hashed_pw = create_hash(username, password)

return username, hashed_pw

def create_user():
Expand Down