Setup SSH (OpenSSH) server for windows XP

Posted by Shek on August 7, 2010 under Misc | Be the First to Comment | Total View: 13,961 views

Editor’s note: SSH provides a secure way to transfer data through the web and therefore I have decided to install a SSH server for my windows machine recently. I found a package OpenSSH which really easy to install and I record the steps of the installation here. The system I am using is Windows XP.

Windows Preparation

First, make sure that your windows user account has a password, as it will be used for the OpenSSH as well, if not go to “control panel” -> “User Accounts” and setup a password for your account.

Installation of the OpenSSH Server

  1. Download Cygwin from by clicking the icon at the top right corner of the site:Cygwin
  2. Double click on the setup.exe file to excute the installation proceed.
  3. Click Next for this:
  4. Choose “Install from Inernet” and click “next”:
  5. Choose “All users” here and click “next”:
  6. Create a folder for the installation files:
  7. Choose “Direct Connection” and click “next’:
  8. Choose a Download site near you and click “next”:
  9. A setup alert will pop up, click ok:
  10. In the search box, type in “openssh” to look for it, the search result will appear under it. Expand the net category by pressing the “+” sign, you will see openssh,  make sure the check box of the B column is checked. Click “next” when done:
  11. Click “next” here:
  12. Installation Completed:

Configuration of OpensSSH server

  1. Run the “Cygwin Bash Shell”:
  2. In the Shell, type in the command “ssh-host-config”.
  3. There are a few query:
    * Should privilege separation be used? yes
    * new local account ‘sshd’? yes
    * Do you want to install sshd as a service? yes
    * Enter the value of CYGWIN for the daemon: [ntsec]
  4. Configuration is done here, type in “net start sshd” to start the service.

Firewall and router configuration

SSH default port is 22 tcp and therefore:

  1. For windows firewall, open port 22: go to “Control panel” -> “windows firewall” -> “exceptions” -> “Add a port” type in SSH for the name and 22 for port number, choose TCP for it.
  2. For router, depends on your router model, forward TCP 22 to the local IP of the windows SSH server.


  1. Install putty (SSH client)  into another local computer which can be downloaded from here.
  2. Run putty and the interface will appear, type in the SSH server local IP into the “Host Name (or IP address), then click “Open”:
  3. If connection is ok, the putty windows will appear and ask for “login as”, type in your windows username and press “Enter”.
  4. Now it will ask for the password, key in and done.

By default, the OpenSSH will load as a service when every time windows starts.

Not what you want? Try a Search

Add A Comment