diff --git a/.gitignore b/.gitignore index f07e7b4..0516b64 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,2 @@ data -src/static/uploads/ +src/static/uploads diff --git a/src/main.py b/src/main.py index b640d05..32721d1 100644 --- a/src/main.py +++ b/src/main.py @@ -169,14 +169,14 @@ def register(): # creates a random string random_string = secrets.token_hex(16) - print(random_string) + # uses the string to create the message that wll be encrypted challenge_phrase = f"this is the unencrypted string: {random_string}" - print(challenge_phrase) + # encrypts message fingerprint, encrypted_msg = pgp_encrypt_and_import(data["pgp"], challenge_phrase) - print(challenge_phrase) - print(encrypted_msg) + + # checks fingerprint if not fingerprint or not encrypted_msg: @@ -209,7 +209,7 @@ def verify(): # retrieve the phrase from the session expected_phrase = session.get("pgp_expected_phrase") - print(expected_phrase) + # check to see if data exists if not data or not expected_phrase: @@ -232,7 +232,6 @@ def verify(): # saves the correcty formated date of birth dob = date.fromisoformat(data["date_of_birth"]) - # stores the data on the database new_user = User( username=data["username"],