I have an RSA Private key file my_private_key.pem
with the header -----BEGIN RSA PRIVATE KEY-----
. I can parse that with the openssl
utility: openssl asn1parse < my_private_key.pem
That shows me a bunch of integers: a 4096 bit integer, a 17 bit integer, another 4096 bit integer, and then five 2048 bit integers.
I understand the textbook RSA primitive where the private key is $(p,q,e)$ where $p,q$ are large secret primes and $e$ is the encryption exponent where $\gcd(e, (p-1)(q-1)) = 1$ and you encrypt plaintext $m$ by $c \equiv m^e \pmod{N}$ where $N=p \cdot q$. How does that textbook version of RSA relate to these integer numbers I see in a .pem
file?
I'm sure this is a newbie question. Where do I start to read on this?