Secure Shell or SSH is a network protocol that allows data to be exchanged using a secure channel between two networked devices.
With more computing and data storage moving to cloud, secure communication between machines is inevitable. For enabling that secure connection SSH is widely used.
SSH uses Private-Public Keys to establish the authenticity of sender and receiver. More on that here on wiki.
For generating this key pair, if you are using Windows here is what you should do:
1. Make sure you have puttygen. You can download it from here:
After you have downloaded the program please run the program
2. Make sure SSH2 RSA is selected.
3. Press Generate, and provide entropy for the key by moving the mouse around.
4. Change the Key comment field to some meaningful description.
5. Enter a passphrase which is used to encrypt the private key.
6. Save the public key.
7. Save the private key.
8. To save the public key in the OpenSSH2 format (required for EC2):
Select all of the text as shown, and copy to the clipboard
Then paste the OpenSSH2 version to a new text file, for example yourname_rsa_new.pub.
Once you have the public keys generated you can use public key for communicating with other machines over network for example Amazon EC2 instances.
Feel free to share your experience regarding generating keys on different machines.