{"id":540,"date":"2023-02-25T16:47:39","date_gmt":"2023-02-25T08:47:39","guid":{"rendered":"https:\/\/www.appblog.cn\/?p=540"},"modified":"2023-04-29T20:39:24","modified_gmt":"2023-04-29T12:39:24","slug":"openssl-generate-rsa-public-and-private-key","status":"publish","type":"post","link":"https:\/\/www.appblog.cn\/index.php\/2023\/02\/25\/openssl-generate-rsa-public-and-private-key\/","title":{"rendered":"OpenSSL\u751f\u6210RSA\u516c\u79c1\u94a5"},"content":{"rendered":"<p>\u751f\u6210PKCS1\u683c\u5f0f\u79c1\u94a5\uff08PHP\u4f7f\u7528\uff09<\/p>\n<pre><code class=\"language-shell\">openssl genrsa -out rsa_private_key.pem 2048<\/code><\/pre>\n<p><!-- more --><\/p>\n<p>PKCS1\u683c\u5f0f\u79c1\u94a5\u8f6c\u6362\u4e3aPKCS8\u683c\u5f0f\u79c1\u94a5\uff08Java\u53caPython\u4f7f\u7528\uff09<\/p>\n<pre><code class=\"language-shell\">openssl pkcs8 -topk8 -inform PEM -in rsa_private_key.pem -outform PEM -nocrypt &gt; rsa_private_key.txt<\/code><\/pre>\n<p>\u751f\u6210RSA\u516c\u94a5<\/p>\n<pre><code class=\"language-shell\">openssl rsa -in rsa_private_key.pem -pubout -out rsa_public_key.pem<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u751f\u6210PKCS1\u683c\u5f0f\u79c1\u94a5\uff08PHP\u4f7f\u7528\uff09 openssl genrsa -out rsa_private_key. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[97],"tags":[146,108],"class_list":["post-540","post","type-post","status-publish","format-standard","hentry","category-tools-skills","tag-openssl","tag-rsa"],"_links":{"self":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/540","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/comments?post=540"}],"version-history":[{"count":0,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/540\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/media?parent=540"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/categories?post=540"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/tags?post=540"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}