Page 1 of 1

Browsing website hosted on PC via phone

Posted: Thu Aug 16, 2018 6:35 pm
by achronos
First off, excuse my ignorance at anything VPN related, it's not my field of expertise.

Basically, I've got the following:
* Home office network behind a telco-provided router
* PC and phone connect with Wi-Fi to that home network
* PC running Viscosity
* PC running a site using IISExpress, of which the site requires the VPN connection to access certain servers it relies on.

Up until recently I was able to follow the instructions to connect from my phone (with no VPN setup) to my PC, by entering my PC's local network ip address (issued by home router), followed by port number, with relevant binding on IIS site settings and port allowed in firewall.

However, we just changed our VPN slightly, so that now my external IP is considered 54.***.**.***. I'm not totally across this change, but it would seem that it caused my inability to access site from phone as before.

According to that linked article, I may need to setup VPN on phone, so I've done that. But now I've tried all combinations of IP addresses I see to access the site from phone and none work:
* PC's router-issued address as before: 192.168.*.**
* Client IP listed by Viscosity: 192.168.***.*
* Server IP listed by Viscosity: 54.***.**.***

First off, which would be the correct IP to use, as the article isn't clear on that.

Any other suggestions about what I'm doing wrong? Does the traffic go through the VPN server and need to be explicitly allowed?

Actually I'm just thinking now that if I'm using the 54.** external IP my home router would probably need to be port forwarding the port my site is running against. Will try that.

Thanks for the help!

Re: Browsing website hosted on PC via phone

Posted: Tue Aug 21, 2018 1:38 pm
by Eric
Hi achronos,

It sounds like you're trying to do one of two things so I'll address both and hopefully it answers your questions:

A) You're trying to access your PC via the public internet with your phone at 54.*.*.*. This one is complex. Chances are your VPN is doing NAT which means that your public IP isn't actually the address of your PC while on the VPN, it's simply the server you are connecting to. To make this work, you need to do some form of port forwarding on your VPN server to forward requests from the server through the VPN to your PC.

B) You're trying to access your PC from your phone while both are connected to the same VPN server. If this is the case, you will need to go to the Client IP listed in Viscosity as your phone and PC will basically be on the same network when connected to the VPN. If this isn't working, you either need to play with your firewall settings on the server, on your PC, or you might need to add the --client-to-client command to your VPN server instance, this would be a checkbox on firewall appliances in their configuration if you have a GUI to configure with.

I hope this points you in the right direction.