Use the mac terminal to generate the RSA private key and public key file, and the mac terminal to generate the rsa
89 :~ Zhangwenquan $
89 :~ Zhangwenquan $ openssl
OpenSSL> genrsa-out rsa_private_key.pem 1024
Generating RSA private key, 1024 bit long modulus
...
...
E is 65537 (0x10001)
OpenSSL> pkcs8-topk8-inform PEM-in rsa_private_key.pem-outform PEM-nocrypt
----- Begin private key -----
MIICdQIBADANBgkqhkiG9w0BAQEFAASCAl8wggJbAgEAAoGBALldSA5HtPvyhEUK
A6M + Cn2jwUQx1lekTK0gM7jSFhzKhcY7ADeVhL + AjGtnYvlGY + npOEM1DqJPBBiu
CbPkyBtPHErZRjN0r0rZiqS0AY7j/EvG656W8S + rhN59AWtV3zuCF0C6pOWnUiMr
Bytes
Oaemwtz%25yva + g4eqRhUxAYNZmsRhzh8JrXv +/aSHlj60uPC + ZhMfGpwzAYo1
I0KR + dQT5uoP1nhqVZev + cxicabj1_kczbvdifz1txl8n1_1ulssnltxdn68qvwh
/WSz/7ppGdKrgVIM4QJBAOS36NuVMsut6iPxLmtOpRz + VTZj8jS1yXz0/sv + WIoj
ZcBabuMTVixMvuK49dBZTTOd5AXCizzKDx4qdD/vdukcqqdpeyyjjtpcie rsosyok
+ Response
TxKlAkAqyGgLYw48YUzR6lR3iB + Em + KOqQVubK7C7AUZXXtsY6QiHght + 3j8EmMG
F/Snapshot
WhBsfyMqU6GHTgEWR7hNEo2A9mhNUDzzUjgPtFExbrZH8uYqthVZAkB2/TLnvwDM
Bytes
FELfsTQfy0Dz
----- End private key -----
OpenSSL> rsa-in rsa_private_key.pem-pubout-out rsa_public_key.pem
Writing RSA key
OpenSSL>
Red indicates the command to be entered.
The red box is in pkcs8 format. Remember to copy it and use it in the background.
Go to the folder to find the pem Certificate
This is the pem file to be generated.