Hacking+RSA

Due October 14, 2009.


 * __ Hacking RSA __** means decrypting a text which has been encrypted with RSA, using only the two numbers given in the RSA encryption program.

I want to emphasize that the optimal way to break an electronic security system is insider information, usually procured through a bribe. So if you're part of an internet security team, make sure the people who are creating the security software are well-paid and reasonably stable people.

Now, back to living in the digital world. The whole reason a course like this is timely is because some people have figured out a few strategies to factor a product of large primes. Before we look at their strategies, let's see why factoring the (P1)(P2) gives a clever person all the information necessary to decrypt the message.

The situation is this: you have intercepted a message encrypted with RSA. You have the two numbers made public in the encryption process. You'd like to decrypt the message because the original message contains the access information to a large supply of Tiffany Easter Eggs. By some amazing luck, you've found the factors P1 and P2. How could you decrypt?

Here are some examples from previous pages. Don't just go back and find the original message. Use your brains to get the original message your self. Then you can go back and check. Try finding and m and y different from those used previously. In other words, find less obvious m and y pairs. See if these pairs also decrypt.

From Second Day, Dave gave C1 = 143 = 11 *13, N1 = 7. encrypted message: 14. (Laura found answer) I used a different m and y and arrived at the same answer. After Figuring P1= 11 and P2= 13, I figured out K which is 120 Next, finding m and y using the equation 120y = 7m-1 After trying a few numbers I arrived at m=223 and y=13 Now, given that the encryted message is intercepted, and using the public encyphering key [7, 143] 14^(223)mod143= 27, the original message. user:D_Sweeney From Second Day, Trevor gave C1 = 35 = 5*7 and N1 = 5 encrypted message 18 (Anna found answer)

key [5,35] and 24y = 5m-1. some integer (m,y) pairs that work in this equation are (29,6), (53,11), (77,16), and (101,21). (18^26)mod35=23 (original message!) (18^53)mod35=23 (18^77)mod35=23 (18^101)mod35=23 user:wrighann

Problem 3 Make your own RSA example from scratch. Decrypt your answer using a DIFFERENT m, y pair from the first pair used. Give all the details.

P1=61, P2=73 C1=4453, K=60*72=4320 N1=17 17m-4320y=1 (m,y)=(2033,8) message:1331 encripted message: (1331^17)mod(4320)=2711 new (m,y): (36593,144) (2771^36593)mod(4320)=1331 user:wrighann

VERY NICE! user:mcdaniel30

P1= 59; P2= 79 C1= 4661; k= 4524; N1= 17 m= 2129; y= 8 Message = 1990 1990^17 mod 4661 = 1041 (New Message)

using new m,y m= 6653; y= 25 1041^6653 mod 4661 = 1990 (Original Message) user:MattJohnson1013

Problem 4 Are you stuck somewhere with only a calculator? Here's one to try! This time, I'm following Stinson's notation. P1 = 7 P2 = 13 7 * 13 = 91. I did some work and got the 5 you see below. You use the 7, 13 and 5 knowledge to get the 44 back. Show your work, of course.

Message = 44. 44^5 mod91 = 18, the encrypted message. According to Stinson's notation the 5 = b. So I need to find a s.th. a*5 = 1(mod(P1 - 1)*(P2 - 1)) = 1(mod 72). Therefore a = 29. ( 29*5 = 145 = 1(mod 72) ) So to decrypt the message we use the y^a mod n notation: 18^29 mod 91 = 44. user:LauraShuman

Problem 5 Use Stinson notation and make up your own, using beefier numbers than Problem 4. Set your example up just like Problem 4.

P1 = 37 P2 = 53 37 * 53 = 1961 I did some work to get the 11. Use 37, 53, and 11 to get 182 back.

Message = 182. 182^11 mod 1961 = 83, the encrypted message. user:LauraShuman Smart stuff.user:mcdaniel30

P1=59 P2=67 P1*P2=3953 a*b = 1(mod(P1 - 1)*(P2 - 1)) a*b=1mod(3828) so then ab would equal 3829, right? so a=547 and b=7. Im thinking I'm doing this wrong....

Message = 452. 452^7 mod 3953 =2405 - encrypted but when i try to decrypt it to see if i did it right i get 2405 back. I am thinking im not understanding this right. user:TrevorBarton

P1 = 81 P2 = 53 81 * 53 = 4293. I did some work and got the 23. Use 81, 53, and 23 to get 1013 back.

Message = 1013. 1013^23 mod 4293 = 146, the encrypted message. user:MattJohnson1013