Wednesday, November 10, 2010

Setup a VPN on HomeServer in 5 minutes (or less)

Setting up a VPN server on Windows Home Server (WHS) is extremely easy, free and requires no software to install on either the Home Server or the clients. Since WHS is based on Windows 2003 Server, it includes the VPN capability by default and simply needs to be enabled. Here is how:

Configuring the Windows Home Server
Step 1: Log into your Home Server using RDP.
Note that you will need to log in using the RDP client not the WHS client.

Step 2: Open the New Connection Wizard
From the start menu, select "Network Connection" > "New Connection Wizard". The "New Connection Wizard" should open:

Step 3: Select "Setup an advanced connection"

Step 4: Select "Accept incoming connection"


Step 5: Select "Allow virtual private connections"

Step 6: Select Users
Select the users that you want to allow in through the VPN connection. The users will be able authenticate using the sames passwords they use to connect to the WHS shares. Make sure that these users have strong passwords, guessable passwords may allow unauthorized users access into your private network.

Step 7: Configure IP Addresses
You'll need to configure TCP/IP stack in order to assign IP addresses to the clients that connect. Select "Internet Protocol (TCP/IP)" and press the "Properties" button:

In the properties window, assign the clients an address range that you know will not be assigned to other hosts on your network. In other words, don't assign the range 192.168.0.1-5 if you know that you already have clients with IP addresses in this range since this may result in an IP address conflict. A better choice would be to assign IP addresses near the top of the range (such as 192.168.0.250-254) where you know that no conflicts will occur. In my case, I setup my firewall to assign IPs in the range 192.168.200-249 and the VPN to assign IPs in the 192.168.250-254.

Click next through the rest of the dialogs to create the connection. Afterwards you can edit the connection by selecting "Network Connection" > "Incoming Connection" from the start menu:


Configuring Your Router/Firewall
Your firewall/router must allow and forward TCP port 1732 (PPTP) and IP protocol 47 (GRE) to the Home Server. The exact instructions depend on the router you are using. Generally, this can be done by adding your Home Server to the DMZ (if your router supports such a feature). The best method is to forward TCP/1723 and GRE to the Home Server since it does not expose the other services that the Home Server is running.

Connecting a Windows 7/Vista Client

Step 1: Open "Connect to Network" wizard
Open the Control Panel, select "Network and Internet", then select "Connect to a network" under the section titled "Network and Sharing Center":

Step 2: Open "Connect to Network" wizard
Click "Set up a connection or network":


Step 3: Click "Connect to a Workspace"




Step 4: Click "Use My Internet connection (VPN)":




Step 5: Enter the Address of the Home Server
Enter the external DNS name of the Home Server. Setup an external DNS name using  if you don't have one yet.


Step 6: Enter Your username and Password
Enter the credentials for your user account that you gave VPN access:



Press connect and you should get an icon in your system tray indicating that you are connected.

Connecting an iPod Touch or iPhone
You can connect an iPod touch or iPhone too. See http://support.apple.com/kb/ht1424 for details. Make sure to use PPTP protocol.