How do you manage SSH keys?

You can use the last part of each lines in .ssh/authorized_keys is intended for comments. From man sshd:

Protocol 1 public keys consist of the following space-separated fields: options, bits, exponent, modulus, comment. Protocol 2 public key consist of: options, keytype, base64-encoded key, comment.

And to answer the question, I use vim but any editor should do it.

My comments usually contains:

  • creation date
  • physical location: creation computer / USB stick (I prefer not to move private key but generate/revoke them and know where they are)
  • 1-2 words about purpose (for which login, for which client, for which script)

I'd checkout the Monkeysphere project. It uses OpenPGP's web of trust concepts to manage ssh's authorized_keys and known_hosts files, without requiring changes to the ssh client or server.