ssh-keygen的-C后面的邮箱有什么用?

每次生成密钥,看到国内的博客,都要求输入邮箱。但不知道意义何在。

后来在stackOverFlow上看到这个答案。

The email is only optional field to identify the key.
邮箱仅仅是识别用的key

When you create the ssh you type (for example):
ssh-keygen -t rsa -C “any comment can be here”
当你创建ssh的时候

-t = The type of the key to generate
密钥的类型
-C = comment to identify the key
用于识别这个密钥的注释
So the Comment is for you only and you can put anything inside.
Many sites and software are using this comment as the key name.
所以这个注释你可以输入任何内容,很多网站和软件用这个注释作为密钥的名字

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注