You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
1.5 KiB
13 lines
1.5 KiB
# Generate public/private key pair
|
|
|
|
**Forces:** When we are doing distributed development, it is necessary to log in and out of a multidude of different machines when doing basic tasks. Since this is a frequent activity, we want to make it as easy as possible. On the other hand, in this modern world, we cannot afford to take risks by making it easy to log in to our remote accounts. We need to share our credentials, but not give everyone access.
|
|
|
|
**Solution:** RSEd25519A is a particular type of encryption that lets the user share a "public" key whilst maintaining a "private" key. The public key may be given away freely, but it is of no use in an exchange without the corresponding private key. Ssh uses this to securely authenticate who is trying to login. As long as your private key is known only to you, this is one of the most secure forms of authentication.
|
|
|
|
Ssh allows the user to create a file named, authorized_keys, that holds the public key information for every user allowed to use that remote account. Meanwhile, ssh allows the user to create a config file that allows the user to specify shortcuts to use when logging into remote accounts.
|
|
|
|
Generate an Ed25519 key pair if you do not have one. (Do this from a bash shell or a powershell).
|
|
```
|
|
ssh-keygen -t ed25519 -C "your_email@example.com"
|
|
```
|
|
This command creates a key pair of type ed25519. You should replace "your_email@example.com" with your actual email. It will create two files, id_ed25519 and id_ed25519.pub in your .ssh directory. Never share the id_ed25519 file with anyone! |