Page 1 of 1

- Download the files: ciphertext.txt, key.txt. Since the prime number and the keys used are 20-digit integers, to avoid

Posted: Thu Jul 14, 2022 2:18 pm
by answerhappygod
Download The Files Ciphertext Txt Key Txt Since The Prime Number And The Keys Used Are 20 Digit Integers To Avoid 1
Download The Files Ciphertext Txt Key Txt Since The Prime Number And The Keys Used Are 20 Digit Integers To Avoid 1 (79.86 KiB) Viewed 31 times
- Download the files: ciphertext.txt, key.txt. Since the prime number and the keys used are 20-digit integers, to avoid typing error, I include those integers in the text file key.txt. You can copy and paste the numbers into your program. In key.txt, p is the prime number used in this exercise, wangpub is my public key, and studentprv is the student's private key. I also include the student's public key studentpub, in case you want to check your program. The ciphertext.txt is a text file encrypted by the student's public key. - Make a Python module named Ex3Module_Lastname.py consisting of all functions used for the ElGamal Public-key Cryptosystem over the prime field Fp​. - Make a plain text file named plain.txt containing only US keyboard characters (Python's text editor can verify it). - Make a Python file named Ex3_Lastname.py. In it, import all the functions from Ex3Module_Lastname.py, use the function decode() and the student's private key to decrypt the file ciphertxt.txt and save the result in the file plaintext_Lastname.txt - Also in Ex3_Lastname.py, use the function encode() and my public key to encrypt your plain.txt and save the result in the file ciphertext_Lastname . txt.