I am gonna write down formulas that I know and use to generate RSA keys.
- we choose
N = p*q
- choose e such as
- 1 < e < f(n)
- coprime with N, f(n)
- choose d so that
d * e (mod f(n) ) = 1
That’s it. With these, if we have
q=7, I succesfully get
e=5 which is correct.
Now Imagine, that I only have private key which is
d=11, N=14). How do I get
e=5. I understand that with
N, you can’t directly get
e, but as RSA works, it tries different variants of
e , then checks and if it’s valid, that’s how you get public key from private key.
Can anyone explain to me what steps should I take here to figure out what
e could be and then from those, which
e should I choose ?