Decrypting RSA when given N and E but not d

12.7k Views Asked by At

The cipher text is O1v3nFbVCbuZLUeJDZO9L9 using the base-64 alphabet N=15241604814814604814814604814814609737853 e=47 I know to work out d you factorize n which equals p and q then you get (p-1)(q-1) and finally e^-1 mod (p-1)(q-1) and then c^d mod N gives you the plaintext. Struggling with the base-64 side of the Question!

1

There are 1 best solutions below

6
On BEST ANSWER

Using the code in my previous answer I get as the decimal number equivalent of the ciphertext: $3473726822818613085692498216956767492477$

Wolfram alpha factorises your $N$ as

$$123457 \times 123456789123456789123456789123456829$$

This gives $$d=1297147349619189902810679264512807332559$$

and thus $$m= 42856312891220705415$$

which becomes Llanymynech (Welsh course?)

Remark:

If you know the answer is (again) a Welsh place name, take a list of them and encrypt each of them till you find a match for your ciphertext. There only a few 100 places to try at most, peanuts for computers nowadays. This already shows that the scheme is quite flawed in this form, even with larger $N$ (this one is tiny by realistic scenarios), as with such public key schemes random padding is added to elimate such attack scenarios.