2. In RSA, we know that factoring n allows you to recover φ(n). Show it works the other way as well: given φ(n), give an algorithm to efficiently recover the factors of n. As a test that your method works, provide the factors of n given below. Hand in your python source along with the factors.
n = 1565548969872265465246036414997755958596184387096896694310755704575264720478601522962278179860838506157941
φ(n) = 1565548969872265465246036414997755958596184387096896588825919091033285362770995843274094868624380615603584
3. Here is one way in which RSA can be misused: suppose you have n = pq for distinct large primes p and q, and distinct encryption exponents e1, e2 where gcd(e1, e2) = 1. You publish n along with e1, e2. Show that if an adversary has C1 = M e1 mod n and C2 = M e2 mod n, then she can recover M. (Note: M is the same for C1 and C2.)
Use your solution to compute M for the parameters given below; hand in any code you use to aid your computation. (You need not hand in code that was re-used above.)
n = 640434271860669796692811836922138143942513719203565769421924022297363333847089887235971007435680486193657059
e1 = 65537
e2 = 65539
M e1 mod n = 400030256839145194441034228199292487980894977737102147552044462667917219509871638663296814615652770720888715
M e2 mod n = 48384876797138828670281479166255073593234801358795810198774095180850824157124747742456773738763877257747936
5. Use Pollard's Rho algorithm to factor the number below. Please include your
source code with your solution.
$N =$ 121932632103337941464563328643500519
6. What irrational is represented by [1,3,3,3,3,...]? Show your work.
7. Let n be the product of distinct primes p,q and let e,d be inverses mod φ(n). Here d is less than 1/3 * n1/4 and p is between q and 2q. Factor n for the following values:
n = 151339355784268862864759120910925660361478568759617718849686393875476226860927728820162298798444560267328429 e = 47011760371307472336991404805847545822065047648754062545767018099994341894667675275660856278086265516059587