After ssh-keygen, the generated passwords are called id_rsa.pub. Can I change the name?
大家讲道理2017-05-02 09:36:06
The generated one is the public key id_rsa.pub and the private key id_rsa
You can use ssh-keygen -f othername to generate the specified file name, or you can rename both after generation
But the ssh command will only read the private key id_rsa by default, so if it is another name, you need to add the configuration file ~/.ssh/config
For example, the following is the configuration of the key I generated specifically for github
Host github.com gist.github.com api.github.com
IdentityFile /path/to/othername
为情所困2017-05-02 09:36:06
That’s not a password,,, that’s just the name of a secret key file. You will never look at it again. Why do you care about it?
黄舟2017-05-02 09:36:06
id_rsa is the private key, id_rsa.pub is the public key
The key is to look at the content inside, just make sure you are happy with the name
PHPz2017-05-02 09:36:06
ssh-keygen -t rsa -f ~/.ssh/你开心就好
will be in ~/.ssh/
目录下生成你开心就好
的私钥和你开心就好.pub
’s public key.