SSH

From GHER

Jump to: navigation, search

Create a SSH key

ssh-keygen -t rsa -b 4096 -C "some comment"

rsa is the algorithm used and 4096 is the key length. Copy the key to the list of authorized keys on a remote machine:

ssh-copy-id -i /home/abarth/.ssh/id_rsa.2 <hostname>

Import CECI SSH key into Seahorse (Gnome Keyring Application)

  • Delete previous CECI key (if present)
  • Copy CECI private key into ~/.ssh
  • Generate private key from public key (without public key, Seahorse will not import the ssh key correctly; it will be treated as a certificate):
ssh-keygen -y -f ~/.ssh/id_rsa.ceci > ~/.ssh/id_rsa.ceci.pub
  • You may add a comment a the end of ~/.ssh/id_rsa.ceci.pub after == such as "Secure Shell Key (CECI 2015)"
  • Open Seahorse can check if there is a entry under OpenSSH keys (no need to import it)
  • Connect to a CECI machine, a dialog will pop-up to request your passphrase and you can choose to unlock the key when you login into gnome.

Troubleshooting

Host key verification failed.
fatal: Could not read from remote repository.

$ ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts
Personal tools