Yes, I can help you.
Cyril M.
asked 11/22/21Python activity method
Can somebody help me with my activity? this is the procedure.
1.Done with caution
2. On the first run of the program, a text (.txt) file will be created. If the .txt file already exists, creation will be skipped. The filename of the .txt file will be your id number like (13-0011.txt). The directory of the .txt file is the same where the .py program is saved. The program will ask to input the username and password to open the text file. The confirmation message to save will follow just like in the example below:
Enter Username to open:
Enter Password to open:
Are you sure you want to save this? [yes | no]
If the answer is yes, your program will save the username and password to the .txt file in an encrypted format. Encryption is the process that scrambles readable text so it can only be read by the person who has the secret code, or decryption key. It helps provide data security for sensitive information (AG Johansen, 2020)
After that, your program will end and you have to restart the program.
3. When the program is re-run, this will check whether the .txt file exists. If not, step #2 will be repeated. If the .txt file exists, your program should be intelligent enough to know if there is a valid username and password to open stored in the .txt file. If there is a valid username and password, this will continue to step 4. Otherwise, a message will be displayed “File Exists but no records found.” And repeat step #2.
4. Your program will ask the user to input the username and password to open. If the username or password is incorrect. Your program will ask to input again. The user has only 5 times input incorrect username and password. On the 4th consecutive attempt of incorrect username or password, your program will display a warning message that if an incorrect password or username will be input again, the .txt file will be deleted permanently; and ask whether to continue or exit the program. If the user inputs 5times incorrect username or password, the .txt file will be deleted permanently and on the re-run of the program, step #2 will start again.
5. Once successfully entered the correct username and password, a menu will display next:
A – Add account
B – View Account
C – Exit Program
When the user selects A – Add Account, this will enable the user to add account credentials. The values to be added are Name of Account, Username, and Password and ask confirmation message to save like:
Example of User input:
Enter the name of the Account: Facebook
Enter the username of your Facebook: admin
Enter the password of your Facebook: 123admin
Do you want to save Facebook credentials? [Y|N]:
If the selection is Yes, then the credentials will be saved to the .txt file in an encrypted format.
When the user selects B – View Account, this will display, in 4 columns, all the stored account credentials in a readable format (decrypted) like:
# Account Name Username Password
1 Facebook admin 123admin
2 Google user 123user
Assuming that the user already has 2 accounts saved in the .txt file. The order of the display is from the first account to the last account saved.
When the user selects C – Exit, a confirmation message will display. If the user inputs yes, step #7 will be next otherwise, step #6 will be performed.
6. The program will then ask whether the user wants to make another selection. If yes, step #5 will be repeated. If not, the program will exit.
7. Your program will display “Thank you.”
1 Expert Answer
Still looking for help? Get the right answer, fast.
Get a free answer to a quick problem.
Most questions answered within 4 hours.
OR
Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.