subject

We are working on Public Key Crypto, RSA, Extended Euclidean algoLet n = 2419 = 41 ∗ 59 and e = 7. (1) Find the private key d. (2) Encrypt the message 6. (3) Sign the message 10. Assume RSA is used. Use the egcd. py program at the lecture attachments folder, described in section 10.3.3, to compute d. For parts 2 and 3, you only need to show the formula; there is no need to calculate the final results. egcd. py#!/usr/bin/python3def egcd(a, b):if a == 0:return (b, 0, 1)else:g, x, y = egcd(b % a, a)return (g, y - (b // a) * x, x)print ('This program gets two integers and calculates their gcd')print ('Example: input e=18 phi=24, output gcd(18,24)=6 d=-1 y=1')e = int(input('Input a number for e: '))phi = int(input('Input a number for phi: '))g, x, y = egcd(e, phi)print ('gcd = ', g)print ('d = ', x)print ('y = ', y)

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 17:30
Working on this program in python 3.7: a year in the modern gregorian calendar consists of 365 days. in reality, the earth takes longer to rotate around the sun. to account for the difference in time, every 4 years, a leap year takes place. a leap year is when a year has 366 days: an extra day, february 29th. the requirements for a given year to be a leap year are: 1) the year must be divisible by 42) if the year is a century year (1700, 1800, the year must be evenly divisible by 400some example leap years are 1600, 1712, and 2016.write a program that takes in a year and determines whether that year is a leap year.ex: if the input is 1712, the output is: 1712 is a leap year. ex: if the input is 1913, the output is: 1913 is not a leap year. your program must define and call the function isleapyear(useryear). the function should return true if the input year is a leap year and false otherwise.
Answers: 1
question
Computers and Technology, 23.06.2019 18:40
How does is make you feel when you're kind to others? what are some opportunities in your life to be more kind to your friends and loved ones? imagine a world where kindness has be outlawed. how would people act differently? would your day-to-day life change significantly? why or why not?
Answers: 2
question
Computers and Technology, 23.06.2019 22:20
Read “suburban homes construction project” at the end of chapters 8 and 9 (in the textbook) and then develop a wbs (work breakdown structure) in microsoft excel or in microsoft word (using tables)
Answers: 1
question
Computers and Technology, 24.06.2019 00:40
What is the error in the following pseudocode? module main() call raisetopower(2, 1.5) end module module raisetopower(real value, integer power) declare real result set result = value^power display result end module
Answers: 1
You know the right answer?
We are working on Public Key Crypto, RSA, Extended Euclidean algoLet n = 2419 = 41 ∗ 59 and e = 7. (...
Questions
question
Mathematics, 25.02.2021 03:10
Questions on the website: 13722363