0
votes

I'm setting up SSH keys for a new class (completely new to this stuff) and when I get to the step that states, "Go to GitHub's SSH key settings. Click New SSH key. When the form pops up, enter a name for your computer in the Title input. In the Key input, paste the SSH key you copied."

I follow the instructions and it tells me, "Key is invalid. It must begin with 'ssh-ed25519', 'ssh-rsa', 'ssh-dss', 'ecdsa-sha2-nistp256', 'ecdsa-sha2-nistp384', or 'ecdsa-sha2-nistp521'. Check that you're copying the public half of the key."

  1. I know this isn't good, although I have no idea what it means.
  2. How do I fix this?

Any help would be greatly appreciated.

Sincerely,

A Complete Newbie

1
I suppose it means that your key needs to start with one of those words. This is not on-topic for SO which deals with programming questions, not basic questions about account management. You may have better luck at Super User or just google "set up public key for github".miken32

1 Answers

1
votes

When you create an ssh key, two files get created in your .ssh directory named, e.g., id_rsa and id_rsa.pub. What you should paste to github is the contents of the .pub file. The .pub file begins with one of those strings, e.g., "ssh-rsa".