View the step-by-step solution to:

Question

This question was created from ExtraCreditRSAEncryptionProblem.docx https://www.coursehero.com/file/36540153/ExtraCreditRSAEncryptionProblemdocx/

4. Compute d &gt; 25 in the range 1 &lt; d &lt; n such that d*e = 1 mod I: thetan ) == e*d - 1 == *thetan
This statement can be computed as follows: Find a d (an integer! such that e*d -1 == k(thetan) D d = [k*thetan +1] /e for k = 1, 2 3 4 etc.
Suggestion: use a while loop for k = 1, 2, 3 4 until [thetan +1] fe does NOT result in a decimal value
for d; this is your cl Remember cl has to be &lt; n the operators / and {’1' may help
The private key is the pair (in) This should be kept secret! Print cl, e and e‘d -1 5. Ask the u5er for a key from the dictionary (call it m) See below
The user input should be an integer (key) from the dictionary d Decide how to handle the case where the user input is NOT a key in the dictionary
Print m 6. Encode the message m by using the public keys as follows: I: = me mod n (Show all work) See Khan video for assistance You can use the exponent
function in python as well as the 56 function (mod)
print c in the following format : printl“the encrypted text Is “, c)

### Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

• ### -

Study Documents

Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

Browse Documents