{"id":458,"date":"2023-02-25T13:25:29","date_gmt":"2023-02-25T05:25:29","guid":{"rendered":"https:\/\/www.appblog.cn\/?p=458"},"modified":"2023-04-29T20:58:55","modified_gmt":"2023-04-29T12:58:55","slug":"linux-generate-ssh-public-and-private-keys","status":"publish","type":"post","link":"https:\/\/www.appblog.cn\/index.php\/2023\/02\/25\/linux-generate-ssh-public-and-private-keys\/","title":{"rendered":"Linux\u7684\u751f\u6210.ssh\u516c\u79c1\u94a5"},"content":{"rendered":"<pre><code>ssh-keygen -t rsa\nssh-keygen -t rsa -C yezhou@appblog.cn<\/code><\/pre>\n<p>\u7ecf\u8fc7\u4e09\u6b21\u56de\u8f66\uff0c\u751f\u6210<code>.ssh<\/code>\u6587\u4ef6\u5939\uff0c\u53ef\u4ee5\u770b\u5230\u4e24\u4e2a\u6587\u4ef6\uff08<code>id_rsa<\/code>\u548c<code>id_rsa.pub<\/code>\uff09<\/p>\n<p><!-- more --><\/p>\n<pre><code># ssh-keygen -t rsa\nGenerating public\/private rsa key pair.\nEnter file in which to save the key (\/root\/.ssh\/id_rsa): \nCreated directory &#039;\/root\/.ssh&#039;.\nEnter passphrase (empty for no passphrase): Jenkins\nEnter same passphrase again: Jenkins\nYour identification has been saved in \/root\/.ssh\/id_rsa.\nYour public key has been saved in \/root\/.ssh\/id_rsa.pub.\nThe key fingerprint is:\nSHA256:65FmI4U3LkNfhXfchHz7p+v7Er9qZGe3tUTm50Mpnn8 root@appblog-cn\nThe key&#039;s randomart image is:\n+---[RSA 2048]----+\n|             . ..|\n|           . .oo.|\n|          . o o.o|\n|       .   o . + |\n|      o S .   + o|\n|     . = =   +.B*|\n|      + X   + B=B|\n|       B o   +o+E|\n|        .   .o*B=|\n+----[SHA256]-----+<\/code><\/pre>\n<p><code>id_rsa<\/code>\u662f\u79c1\u94a5<br \/>\n<code>id_rsa.pub<\/code>\u662f\u516c\u94a5<\/p>\n","protected":false},"excerpt":{"rendered":"<p>ssh-keygen -t rsa ssh-keygen -t rsa -C yezhou@appblog.c [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[96],"class_list":["post-458","post","type-post","status-publish","format-standard","hentry","category-devops-base","tag-ssh"],"_links":{"self":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/458","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=458"}],"version-history":[{"count":0,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/458\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/media?parent=458"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/categories?post=458"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/tags?post=458"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}