Yesterday when I read a post of HVA asking about which is better when using password or public key to authorize to SSH Server. When I read this post, I remembered that I already activated SSH on my Bluehost account, but I never used it. So I decided to try to open a SSH connection in Bluehost and saw what happened when I used password/public key to authorize myself. When I understand the communicate process, I can find out my own answer for the question above.
First, what I need is a SSH Client and Putty is a good candidate. Putty is a free implementation of Telnet and SSH for Win32 and Unix platforms, along with an xterm terminal emulator. You can download at its homepage Putty’s hompage. After downloading Putty, let’s try to log-in SSH Server with 2 ways discussed above : one is with password and one is with public key.
1. Start Putty, enter your host-name without www. Click open.
2. On the next black screen, enter the name and password which you are supplied when you registered Bluehost. You can find the username on first screen of CPanel. The password is the password for login into CPanel.
Ok that is the way I can login to SSH Server.
With public key
1. You must first create a key pair on Bluehost. To do that, on CPanel site, go to SSH/Shell Access –> Manage SSH Keys –> Generate new key. Enter necessary information.
2. After creating new keypair, download your private key to your computer. Remember using passphrase and save your private key under .ppk format.
3. Open your putty, enter your host name. At text box “Saved Sessions”, enter a name for it. Save it.
4. Browse to SSH Category –> Auth –> Browse to your private key which is download in step above. And then browse back to Session Category and click save to update so that Putty knows that he must use the private key for the current session.
5. Click open, enter username (which can be read at CPanel site like above), enter passphrase (which is applied to encrypt private key at step 2) and you are connected…
So I finished with trying to authorize myself with password and public key. How does the communicate process really work? I’ll post in my blog in next days.