By default, each VPS you will log in with the root username and root password that the provider sent you when renting the VPS, but using a password always has 2 big risks:
Therefore, to make authentication of connections from outside to the VPS more secure, password authentication over SSH is disabled by default on all servers connecting to FlashVPS and is not re-enabled.
SSH Key is an authentication method of logging in with the server through SSH access by comparing a pair of keys, including a private key (private key) and a public key (public key). Private key and Public key are closely related to each other for the purpose of identifying each other.
SSH Keys are often used as an ALTERNATIVE OF PASSWORD by verifying access. Simply put, this login is a question and answer format, where one party presents a question and the other has to provide a valid answer in order to be authenticated.
For Mac :
brew install putty
For Linux :
sudo apt install putty-tools
Generate SSH Key (version 2)
puttygen -t rsa -b 2048 -o /home/flashvps/.ssh/id_putty_flashvps --ppk-param version=2
Generate SSH Key (version 3)
puttygen -t rsa -b 2048 -o /home/flashvps/.ssh/id_putty_flashvps
After running the above command, the Private Key file will be saved at the path you entered, To use the key you need a Public Key. Create the Public Key as follows:
puttygen -L /home/flashvps/.ssh/id_putty_flashvps
After running the above command, you will see the returned content in the form of
ssh-rsa AAAA...you copy this code and add it to your server.
In case you need to save
Public Keysomewhere you run the following command:
puttygen -L /home/flashvps/.ssh/id_putty_flashvps > /path/to/save/filename.pub
The file will be saved at
/home/flashvps/.ssh/id_putty_flashvpsto the path to save your file.
Enable OpenSSH Client on Windows 10 by:
After activating the OpenSSH Client, open it
command linewith admin rights and run the following command:
ssh-keygen -t rsa -m PKCS8 -b 2048 -f "C:\Users\your_username\.ssh"
C:\Users\your_username\.sshwith the path where your ssh key is stored.
ssh-keygen -t rsa -m PKCS8 -b 2048 -f $HOME/.ssh/id_rsa_flashvps
After running the above command at the path
$HOME/.ssh/there will be 2 files named
id_rsa_flashvps(Private Key) and
id_rsa_flashvps.pub(Public Key) you copy the Public Key content and add it to your server.
Before connecting the server with FlashVPS, you should enter the SSH Key in the SSH Keys page so that every time you connect a new server, the entered SSH Keys will be automatically added to the new server without having to do anything. .
To manually add SSH Key to the server, go to panel > Select Server > SSH Key and add the SSH Key like the steps above.