Damian Mehers' Blog Evernote and Wearable devices. All opinions my own.

26May/1118

How to: Windows 7 incoming VPN from Android

A couple of weeks ago I tried to get my HTC Incredible S, running Gingerbread to connect via VPN to my Windows 7 box.  I failed, but today I succeeded.  This is how.

I created the incoming VPN on Windows 7 by following instructions I found on the web:

Open the Network and Sharing Center

image

Click on Change Adapter Settings

image

Press Alt-F, and select New Incoming Connection

image

Configure the incoming connection

imageimageimage

Change the IPV4 properties to specify a DHCP range

Make sure the range you specify is on your LAN, and out of the range served by your DHCP server (you can updated your DHCP server to exclude this range).

image

Check the firewall

I went to Advanced Settings under Windows Firewall, clicked on Inbound Rules, clicked on the Local Port column to sort by that column, and then verified that the line for port 1723 was set up and enabled (Routing and Remote Access (PPTP-In).

image

Set up port forwarding

I then went to my Router configuration, and set up port forwarding, so that external connections to port 1723 were forwarded to the machine I just configured (which is always allocated the same IP address by the router):

image

Now my Android device can connect to my internal VPN using the default settings.  You’ll need to know your external IP address.  You can find it using tools like http://www.whatismyip.com/ but it may change.  I have mine set up using http://www.dyndns.com/

Filed under: Android Leave a comment
Comments (18) Trackbacks (3)
  1. Wouldn’t it be simpler just to use a Remote Desktop client from your Android into your Win7 machine? That’s what I use on my Epic4G and it works pretty well; only problem is that it requires IP instead of machine name so I periodically have to look that up for it to work.

  2. Great guide!

    Dave, connecting to one box via RDP is definitely not the same thing as accessing an entire network via VPN.

  3. You can use a dynamic DNS service, such as dyndns.org, to automatically translate your changing public IP address to a hostname that stays the same (eg. samplename.dyndns.org). most routers have the ability to configure this service; just sign up for a free account, and enter the account info in the dynamic dns section of your router. Then you wont need to worry about checking to see if your ip address has changed.

  4. sorry, i just realized that dyndns.org is mentioned at the bottom of the article. anyway check it out, it works.

  5. This is absolutely fabulous! I’ve been searching for days trying to find out what VPN protocol to use (I didn’t know which one the Win7 built-in VPN server used), this made everything work.
    I have 3 PC’s at home, all of which have files that I like to be able to reach from the ‘Net and RDP is not a viable option. This way, I can get to my stuff at home with my phone if I need to.

  6. Set up the VPN, but cannot connect on my android device. Keeps giving me wrong username/password error. Ports are forwarded. :/

  7. Hi,
    Rob….you have to do exacly like in this guide. There is a known error with PPTP on Android. I had the same issue. The problem was with IP range.
    Change the IPV4 properties to specify a DHCP range

    Make sure the range you specify is on your LAN, and out of the range served by your DHCP server (you can updated your DHCP server to exclude this range).

    Without this it would not work.

  8. Happy belated new year to all!
    How EXACTLY should I do to “Make sure the range I specify is on my LAN”?,
    I believe I know where to check the range served by my DHCP server though.

    Thanks in advance guys :)

    JDL

  9. @Javier DL
    Control Panel\Network and Internet\Network Connections
    Double click on Incoming Connections Icon
    Networking Tab / Properties of IPV4
    If your router is say set to provide say 192.168.0.3 – 192.168.0.30, then you could enter 192.168.0.31 to 192.168.0.35 (or any range that does not overlap the router range and is a valid ip address.

    For others..
    If you are trying to connect to the VPN with a device already on the network via wifi try using your data connection instead.. I guess you would not be able to VPN onto a network that you are already on?

  10. Thank you so much for this guide. It has helped me get this working on my Galaxy S3.

  11. Hi – Thanks for the info. My problem comes after the VPN connection has been establish. Do I need another application to view my shared files on my Windows 7 computer on my Android? If this is true can you suggest one from the Google On Line Software Library

  12. everything is perfect, connected. now, how to view files??

  13. I was able to setup the incoming connection on my windows 7 computer, now i have an android device, i started setting up the VPN, first it asked for the name so i entered a name of my choice, then it asked for a server address so i entered the Local IP Address of my computer, then it asked for username and a password but i am wondering where i can find it. And yes I had setup the port forwarding for VPN-PPTP on the router as per the guide above. Someone please help!

  14. i follow the instruction above but when i try to connect using my android phone it fails..,,,,,

  15. I tried this once before and beat my head against the wall trying to get it working. I followed this article to the letter and got it working on the first try!

  16. anyone knows if this will encrypt the traffic between the 2?

  17. From the Netherlands.

    I was searching too the whole weekend.
    Thanks for the comments on this page.
    It is working..

    But i always wanna know, how does it works? I mean, whats happening when i make a connection?

    Thanks. Arend

  18. Thanks, this is the only guide that mentions the known error with PPTP on Android, which is mother-effing critical in the setup.


Leave a comment