Now, it’s easy to transfer your data over a network from one device to another with an FTP connection for your client. But we all know that FTP is not that safe, hence you can use SFTP, which is secure and prevent unauthorized access.
Isn’t that great that you gain free security!
We will take through 2 main steps, so let’s get started:
1.Installing OpenSSH on Windows-based Servers.
You need to Download OpenSSH from the GitHub.
Then, extract the archive to the Program Files folder.
Now, just open the PowerShell as an administrator, and paste the below-given command in the window, to navigate to the folder: cd “C:\Program Files\OpenSSH-Win64”.
SSH needs two services to run, sshd and ssh-agent.
Therefore, to install you will have to paste the below command in the PowerShell window: powershell.exe -ExecutionPolicy Bypass -File install-sshd.ps1.
You will get the message: “sshd and ssh-agent services successfully installed”.
Now you can close the PowerShell window and start the services manually or you can set them to open automatically, by using Services.msc. This creates the folder “C:\ProgramData\ssh” which is crucial for the service to work with your host key.
Note: The services will be named as OpenSSH Authentication Agent and OpenSSH SSH Server.
2.Opening the SSH port in the Windows Firewall manually
The SSH uses port 22 for transfer/authentication, which is closed in Windows because SSH isn’t included by, default. Therefore to open it, open the Windows Firewall from the Control Panel.
Then, click on Inbound Rules – you can see that in the left pane.
Click new rule, select Port and click on Next, which is in the right pane
If you get stuck anywhere, you can raise a ticket and our Technical Assistant will guide you further.
Next, type the number 22, in the Specific local ports option, and click Next.
You need to choose “Allow the Connection”, and click Next, and then select “Private” for the network option.
You can give the rule a name like SSH or OpenSSH.
Then click on Finish.
Hope you have successfully completed the installation.
Take a moment to check: How to Install and Configure ProFTPD on Linux Server