SSH

What is Secure Shell (SSH)?

Secure Shell (SSH) is a cryptographic network protocol for secure data communication, remote shell services or command execution and other secure network services between two networked computers that connects, via a secure channel over an insecure network, a server and a client (running SSH server and SSH client programs, respectively). SSH is typically used to log into a remote machine and execute commands. It can transfer files using the associated SSH file transfer (SFTP) or secure copy (SCP) protocols. The standard port used to connect through SSH is 22.

Enabling SSH Access

IT Itch supports SSH access on all its Linux (Single Domain, Multi Domain and Reseller) Hosting Servers.

Connecting to a Server through SSH

SSH connection to IT Itch's Linux Hosting Servers will be through a key based authentication.

Generating a SSH Key Pair

The user needs to generate key (public key and private key) pair on his local computer.

For Linux:

Run the below command:

ssh-keygen -t dsa

OR

ssh-keygen -t rsa

The output would be similar to:

Generatingpublic/private dsa key pair.Enter file in which to save the key (~/.ssh/id_dsa):Press[Enter] key 
Enter passphrase (empty forno passphrase):Press[Enter] key 
Enter same passphrase again:Press[Enter] key 
Your identification has been saved in~/.ssh/id_dsa 
Yourpublic key has been saved in~/.ssh/id_dsa.pub 
The key fingerprint is:<some string>

OR

Generatingpublic/private dsa key pair.Enter file in which to save the key (~/.ssh/id_dsa):Press[Enter] key 
Enter passphrase (empty forno passphrase):Press[Enter] key 
Enter same passphrase again:Press[Enter] key 
Your identification has been saved in~/.ssh/id_dsa 
Yourpublic key has been saved in~/.ssh/id_dsa.pub 
The key fingerprint is:<some string>

id_dsa or id_rsa is the private key and id_dsa.pub or id_rsa.pub is the public key.

For Windows:

  1. Download PuTTY.

  2. Download PuTTYgen.

  3. Open PuTTYgen.

  4. Select the SSH-2 RSA (or SSH-2 DSA) option and click the Generate button.

  5. Move mouse randomly over the empty space below the progress bar to create some randomness in the generated key.

  6. Click the Save private Key button, without providing any passphrase.

  7. Click Yes on the window asking for confirmation for saving the key without a password.

  8. Save the key file with an appropriate name, say ssh_private_key.ppk.

Authorize the SSH Server to use the Public Key

For Linux:

  • Create a directory as .ssh (note the preceding dot) under /home/<username>/ for your hosting package on the remote host. You will then have to create a file named authorized_keys inside this .ssh directory.

  • Copy the content of the local ~/.ssh/id_dsa.pub or ~/.ssh/id_rsa.pub file into the authorized_keys file.

For Windows:

  • Create a directory as .ssh (note the preceding dot) under /home/<username>/ for your hosting package on the remote host. You will then have to create a file named authorized_keys inside this .ssh directory.

  • Copy the content under the Public-Lines section in the file called ssh_private_key.ppk on the local computer.

  • Edit the authorized_keys file on the remote host, type the word ssh-rsa (including spaces on both ends of the word) and paste the copied content. Remove the carriage return at end of each line, merging four lines into one single line. Be careful not to delete any characters while doing that. Final output would be similar to:

    ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAIEAnjXf5VEuIfOHmbNGn7NZAYDjSp8mYK9sDF+RZR75V4gyu3FeaXcAlwA/jwzzgpIvhK2why5t9DtokyInlocq
    P9SbNd9xOnrvXEV+ImvKiBf4+tFk7uagZJ+CLrr0tK7M4lKskjfad38UF5cJ0+YU24V1sCDs6QTJC4kG3PO1eeE=

Accessing the Remote Server

For Linux:

Run the below command:

ssh -l user remote-server

For Windows:

  1. Open Putty and enter the Remote Host Name or IP Address.

     

  2. In the left menu, click Data under Connection and enter the cPanel username in the Auto-login username field.

     

  3. In the left menu, click Auth under Connection -> SSH and enter the path of the saved private key file.

  4. Click the Open button to connect to the server.

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Accessing Your Hosting

To access your web hosting, go to your hosting management dashboard. This can be found by logging...

[t3] Error Message: Invalid Username/Password, or your User account maybe Inactive or Suspended

If you change the email address associated with your account, you may see the following error...

FTP

You can find your FTP details in your hosting management dashboard. Go to:"My Services > View...

Dedicated IP

To add a dedicated IP to your webhosting service, navigate to:"My Services > View Details >...

Adding Additional Domains to a Multi-Domain Shared Hosting Account

Please complete these two simple steps to add additional domains to a multi-domain shared hosting...