kesto.de Cheatsheets

SSH

Map port 22 at host to local port 2208 ("backconnect"); reverse port forwarding

ssh -N -R 2208:localhost:22 example.org

Create a key in Dropbear

dropbearkey -t rsa -f id_rsa

Create SOCKS proxy

ssh -D8080 host

then either configure SOCKS4-proxy in browser (localhost:8080) or use tsocks

Use password authentication

ssh -o PreferredAuthentications=password user@example.org

Use specific key for authentication

ssh -i ~/.ssh/private_key_file user@example.org

Inspect key (show host key fingerprint / inspect private key)

ssh-keygen -l -f /etc/ssh/ssh_host_rsa_key

can be used for ~/.ssh/private_key_file too