1

This seems like maybe a bug? I've changed my email in GitHub to use the noreply form that is more private. I tried changing the email in the ~/.ssh/id_rsa.pub file and using ssh-add ~/.ssh/id_rsa, but it says my old email. I've only adding this key (with no other key on this machine) today. So I tried using ssh-add -d ~/.ssh/id_rsa to delete the the keys and add again, and also manually deleted them, and checked both the known_hosts and authorized_keys files and deleted known_hosts.old file, but still the old email. Tried exiting the shell, restarting sshd, and then had to use eval ssh-agent to appease the "Could not open a connection to your authentication agent." error, but still no success. Any ideas?

Identity added: /home/user/.ssh/id_rsa ([email protected])

Oddly, when I remove the same key it says:

Identity added: /home/user/.ssh/id_rsa ([email protected])

Luckily my GH fetch worked, but still very puzzling. This post says its just stored as comment and not inside the hash: https://serverfault.com/questions/309171/possible-to-change-email-address-in-keypair

    1 Answer 1

    1

    Yes, you change the comment via the command below, then you can remove and add it back.

    $> ssh-keygen -c Enter file in which the key is (/Users/bob/.ssh/id_rsa): id_ed25519 Enter passphrase: Old comment: [email protected] New comment: [email protected]

    then

    ssh-add -d ~/.ssh/id_ed25519 ssh-add ~/.ssh/id_ed25519 

      You must log in to answer this question.

      Start asking to get answers

      Find the answer to your question by asking.

      Ask question

      Explore related questions

      See similar questions with these tags.