Mac查看.ssh文件夹的方法

Mac查看.ssh文件夹的方法

在终端输入命令:$ cd ~/.ssh 查看是否存在ssh文件

存在

打开终端输入 open ~/.ssh

cat id_rsa.pub //打开id_rsa.pub文件,复制密钥

不存在

$ ssh-keygen -t rsa -C "邮箱地址" #邮箱地址为公司的gitlab邮箱,生成KEY

Generating public/private rsa key pair.

Enter file in which to save the key (/c/Users/用户/.ssh/id_rsa): //密钥的目录

Created directory '/c/Users/用户/.ssh'.

Enter passphrase (empty for no passphrase): //密码设置为空

Enter same passphrase again:

Your identification has been saved in /c/Users/用户/.ssh/id_rsa.

Your public key has been saved in /c/Users/用户/.ssh/id_rsa.pub.

The key fingerprint is:

SHA256:******* **** //公钥

The key's randomart image is:

+---[RSA 3072]----+

| o.*+ . .o.. |

| + *o*. .. . |

| *.B o |

| +. . . .|

| . S E . . |

| . . + = .o |

| . . + +.*. . |

| . o.+o@. |

| o*B.o |

+----[SHA256]-----+

相关推荐

猎豹加速器使用指南:提升上网速度的不二之选
best365官网投注链接

猎豹加速器使用指南:提升上网速度的不二之选

📅 07-21 👍 81
世界杯全胜传奇,三强不败神话,巴西双冠荣耀
365名品汇推荐码多少

世界杯全胜传奇,三强不败神话,巴西双冠荣耀

📅 08-14 👍 490
地球的核心究竟有什麼?
s365国网公司健步走app

地球的核心究竟有什麼?

📅 07-09 👍 680