Setting up VPN

Step by step guide to integrating OpenVPN with TunerFreeMCE for UK users

Instructions here refer to AlwaysVPN as an example, but that should not be seen as an endorsement. It worked for me OK though.

1) You will need to download and install a version of OpenVPN which allows the password to be entered in a plain text file, e.g.;

http://botsikas.blogspot.com/2008/10/building-openvpn-with-enable-password.html

2) Buy a proxy server package, e.g. AlwaysVPN. Download and install the config file from them (just the config file – you already have the OpenVPN client downloaded in step 1).

3) Go to  C:\Program Files (x86)\OpenVPN\config and create a text file with your username for the VPN service on the first line, and your password on the second. Save it as “user_auth.txt“, e.g.

martin.millmore
bananas

3) Edit your config file to add the full name of the password text file after the text auth-user-pass. Also change any certificate references to be full paths, e.g.;

ca “C:\\Program Files (x86)\\OpenVPN\\config\\alwaysvpn2_ca.crt”
tls-auth “C:\\Program Files (x86)\\OpenVPN\\config\\alwaysvpn-ta.key” 1
auth-user-pass “C:\\Program Files (x86)\\OpenVPN\\config\\user_auth.txt”

4) Create a text file with the following command in it, and save it as “openUSVPN.bat“;

“C:\Program Files (x86)\OpenVPN\bin\openvpn.exe” –config “C:\Program Files (x86)\OpenVPN\config\AlwaysVPN-Compatible.ovpn”

5)  Create a text file with the following command in it, and save it as “closeUSVPN.bat“;

taskkill /f /im openvpn.exe

6) Edit your preferences to enter these scripts in the UK and US VPN command boxes;

7) Right click on Media Center, and select Run as administrator.This is important, because the openVPN command needs to run as administrator to configure the network settings.

8)  When you browse to hulu, it will open your US VPN connection. When you go to UK programs, it will kill the VPN connecton so that you can watch UK programs though your regular UK broadband connection.

Step by step guide to integrating Windows native VPN with TunerFreeMCE for UK users

1) Set up your windows VPN connection as described by your VPN provider. This will create a network connection in the Network and Sharing center. In this example, we will say the connection is called “MYUSVPN”.

2) Create a text file with the following command in it, and save it as “openUSVPN.bat“;

RasDial MYUSVPN username password

where username and password are your username and password

3)  Create a text file with the following command in it, and save it as “closeUSVPN.bat“;

RasDial MYUSVPN /disconnect

4) edit the preferences as described above

Here's a list of different services that have been tested by TunerFreeMCE users. This is not an endorsement of the sites that work, but is just provided to help people.

Name Status
AlwaysVPN Works fine with Vista 32bit and Vista 64bit, but e-mail them to enable hulu support
Anonymizer Does not work with Media Center
HideMyIP Does not work with Media Center
UKiVPN Works fine. RasDial can be used to script the proxy switching

VPN setup for US users

Follow the same instructions as for UK users, but set your default country to US, and create an openUKVPN.bat file that opens the UK VPN, and a closeUKVPN.bat file that closes the VPN. Put the openUKVPN.bat file in the UK VPN Command prefernce, and the closeUKVPN.bat file in the US VPN Command prefernce.

VPN setup for other countries

If you not in either the UK or the US, you will need to open a VPN connection for both countries. To do this, set the default country to your home country (e.g. CA for Canada), and create two command files, openUKVPN.bat and openUSVPN.bat. In the openUKVPN file, put a command to close the US connection and then open the UK one. In the openUSVPN file, put a command to close the UK connection and then open the US one. This will swap between the two connections fine. When you exit media center, just kill any remaining VPN connections.

Step by step guide to integrating Proxy Switching with TunerFreeMCE for UK users

1) Get the details of your proxy server. In the following example, we will assume it has the server name “myproxy”

2) Create a a text file with the following command in it, and save it as “openUSVPN.bat“;

netsh winhttp set proxy myproxy:80

3)  Create a text file with the following command in it, and save it as “closeUSVPN.bat“;

netsh winhttp reset proxy

4) Edit the preferences as described above.

As before, if you are connecting from a different country, simply change the commands to suit.

 

Administrator privileges

Some VPN connections require you to run as an administrator, which is a pain on Vista in particular. There is a great solution to this documented here. In summary, you create a task in the Task Scheduler to run your VPN command, and select the Run With Highest Privileges option. Don't set any triggers so that it doesn't run on it's own. Then create a bat file which runs the task, e.g. it should have C:\Windows\System32\schtasks.exe /run /tn “Start VPN” where Start VPN is the name of your task. Then add that bat file as your VPN command.