PuTTY and a private key
To in to a server via SSH with PuTTY and a public key, perform the following steps:
- From the Windows Start menu, open the client.
- Navigate to the PuTTY Key Generator interface.
- Under the Actions heading, click Generate. PuTTY will generate the key and display the result under the Key menu.
- Copy the public key and paste it in the
- Enter a passphrase in the Key passphrase and Confirm passphrase text boxes.
- Click Save private key and save the key as a
- In the Session interface, from the Saved Sessions menu, select your preferred authorization session and click Load.
- Navigate to the Auth interface under the SSH category.
- Click Browse, select the private key file to upload, and click Open.
- Navigate to cPanel's interface ( Home >> Security >> SSH Access >> Manage SSH Keys) and import the server's keys.
MacOS or Linux
To log in to your MacOS or Linux server via SSH, perform the following steps:
- Open a terminal session.
Run the following command:
ssh -p port user@IP
In the above command:
portrepresents the port number.
userrepresents your username.
IPrepresents your IP address.
Manage SSH keys
This section of cPanel's SSH Access interface allows you to create, import, manage, and remove SSH keys. The system will use these keys when you confirm that a specific computer has the right to access your website’s information with SSH.
Generate a New Key
Use this section of the interface to create new SSH key pairs, which include a public key and a private key.
To generate a new SSH key pair, perform the following steps:
- Click Manage SSH Keys.
- Click Generate a New Key.
- To use a custom key name, enter the key name in the Key Name (This value defaults to id_rsa): text box.
- Enter and confirm the new password in the appropriate text boxes.
- Select the desired key type.
- DSA keys provide quicker key generation and signing times.
- RSA keys provide quicker verification times.
Select the desired key size.
Click Generate Key. The interface will display the saved location of the key.
To import an existing SSH key, perform the following steps:
Click Manage SSH Keys.
Click Import Key.
To use a custom key name, enter the key name in the Choose a name for this key (defaults to id_dsa) text box.
Paste the public and private keys into the appropriate text boxes.
- Click Import.
Manage your keys
The Public Keys and Private Keys tables display the following information about your existing keys:
|Name||The key's name. Public and private keys use the same key name.|
Whether you authorized the key.
You must authorize new keys before you attempt to use them.
This column only displays in the Public Keys table.
You can perform the following actions: