Skip to content

Instantly share code, notes, and snippets.

@b-bot
Created January 18, 2019 09:44
Show Gist options
  • Save b-bot/5f8914a3110d82fc023c666906037866 to your computer and use it in GitHub Desktop.
Save b-bot/5f8914a3110d82fc023c666906037866 to your computer and use it in GitHub Desktop.
$ brew install putty
Place the two keys in the .ssh folder in the user directory.
Now convert the PPK keys to SSH keypairs
$ cd ~/.ssh
Private key generation:
$ puttygen id_rsa.ppk -O private-openssh -o id_rsa
Public key generation:
$ puttygen id_rsa.ppk -O public-openssh -o id_rsa.pub
Set permissions for the keys:
$ chmod 600 ~/.ssh/id_dsa
$ chmod 666 ~/.ssh/id_dsa.pub
Connecting using new keys:
$ ssh -i ~/.ssh/id_rsa username@servername
Connecting to remote server using port forwarding:
$ ssh -i ~/.ssh/id_rsa -L 9001:127.0.0.1:3306 username@serverName
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment