ssh

Updated: 07 November 2024

Prefer password authentication over public key

ssh -o PreferredAuthentications=password -o PubkeyAuthentication=no user@example.com

Use a non-standard port

ssh user@192.168.1.1 -p 26

Generate a key pair

ssh-keygen -t rsa

Copy key to clipboard

cat ~/.ssh/id_rsa.pub | xclip -sel clip

Use one specific private key

ssh -o "IdentitiesOnly=yes" -i /home/me/path/to/private/key/id_rsa user@host