Last active
November 6, 2019 21:54
-
-
Save danhodge/141f6a994438ff7e2929e4f50f261879 to your computer and use it in GitHub Desktop.
SSH notes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Establish a local SSH tunnel to a remote server | |
$ ssh -f <user>@<ip> -L <local_port>:<ip>:<remote_port> -N | |
Generate a SSH public/private key pair (4096 bits, with no comment at the end of the public key) | |
$ ssh-keygen -b 4096 -C "" | |
Extract the public key from a private key | |
$ openssl rsa -in private_key.pem -pubout # PEM formatted | |
$ ssh-keygen -y -f private_key.pem # SSH formatted |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment