Why is ssh-add adding duplicate identity keys?
Posted
by
skyblue
on Ask Ubuntu
See other posts from Ask Ubuntu
or by skyblue
Published on 2011-01-29T10:22:02Z
Indexed on
2011/01/29
15:33 UTC
Read the original article
Hit count: 397
I have created a private/public SSH key pair using "ssh-keygen". I use this to authenticate to remote servers. However, I find that when I log in, "ssh-add -l" already lists my identity key even though I have not added it! If I use the command "ssh-add" it prompts me for my passphrase and loads my identity key. If I then list my keys with "ssh-add -l", it now shows two identity keys! These are obviously the same as both have the same fingerprint, but their descriptions are different (the automatically is "user@host (RSA)" and the one added using ssh-add is "/home/user/.ssh/id_rsa (RSA)").
So why does my identity key appear to be loaded without any action on my part, and why does ssh-add add the same key again? Obviously something must be doing this automatically, but what is it, and how can I stop it?
© Ask Ubuntu or respective owner