Showing posts with label rsa. Show all posts
Showing posts with label rsa. Show all posts

Saturday, 1 March 2014

Public Key Authentication SSH (Debian, Ubuntu)

Generate RSA keys on Client

mkdir ~/.ssh 
chmod 700 ~/.ssh 
ssh-keygen -t rsa -b 4096

Transfer Client Key to Host

ssh-copy-id username@host

Test

ssh username@host

Disable Password Authentication On Host

sudo nano /etc/ssh/sshd_config


Look for <#PasswordAuthentication yes> and change it to <no>.

Restart SSH

sudo service ssh restart

DONE