Docs/linux基础/将openssl生成的公私钥转换成ssh-keygen识别的格式.txt
2022-10-18 16:59:37 +08:00

19 lines
595 B
Text

<<<<<<< HEAD
1、使用openssl genrsa工具产生私钥
openssl genrsa -out private.pem 2048
2、根据私钥产生对应的公钥。
openssl rsa -pubout -in private.pem -out tmp.pem
3、使用ssh-keygen将公钥转换成ssh格式。
ssh-keygen -f tmp.pem -i -mPKCS8 > public.pem
=======
1、使用openssl genrsa工具产生私钥
openssl genrsa -out private.pem 2048
2、根据私钥产生对应的公钥。
openssl rsa -pubout -in private.pem -out tmp.pem
3、使用ssh-keygen将公钥转换成ssh格式。
ssh-keygen -f tmp.pem -i -mPKCS8 > public.pem
>>>>>>> 28bec05... 20200611