Forwarding a routers IP to a web server on an internal IP

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
User avatar
jayshields
DevNet Resident
Posts: 1912
Joined: Mon Aug 22, 2005 12:11 pm
Location: Leeds/Manchester, England

Forwarding a routers IP to a web server on an internal IP

Post by jayshields »

I think this should be fairly easy, but I'm having a pretty hard time doing it and/or finding out any generic advice (non-router specific).

I can go to my (routers) IP from a different machine and I get the login page for my router settings. That is expected. I also guess that setting a "Firewall Rule" which redirects any port 80 TCP connections to the internal IP won't do anything, because that would overwrite the router settings web page connection port.

So, if I create a "Firewall Rule" to redirect port 8080 TCP to my internal IP (and also set Windows Firewall to allow 8080 TCP, and also set Apache to listen to 8080) I would expect it to work, well it doesn't and Firefox gives me a generic "Failed to Connect" page, which says this "Though the site seems valid, the browser was unable to establish a connection.", giving me a glimmer of hope.

To clarify, I can connect to my web server through another internal machine, using my internal IP. I am rebooting the router after making changes. I am using a router provided by Sky Broadband (UK), which I believe is manufactured by Sagem. I have UPNP turned on, although the port map table is empty. I also have my internal IP set as the default DMZ server, which, as far as I know, opens my machine to anything and everything.

Does anyone know what I am doing wrong? There seems to be a whole load of message board I can find through Google with people saying how bad the Sky router is, but I think that's the same for any router. I have a spare NetGear router that I could swap it out for, but surely that's not necessary.

Thanks.
Doug G
Forum Contributor
Posts: 282
Joined: Sun Sep 09, 2007 6:27 pm

Re: Forwarding a routers IP to a web server on an internal IP

Post by Doug G »

Many routers prevent using the external IP to access a site from within the LAN. There are some security concerns about this. Check your router configuration and see if there are any settings that control this behavior, I seem to recall seeing such an option in a recent router I worked on.
User avatar
VladSun
DevNet Master
Posts: 4313
Joined: Wed Jun 27, 2007 9:44 am
Location: Sofia, Bulgaria

Re: Forwarding a routers IP to a web server on an internal IP

Post by VladSun »

If you router port-forwarding setup is ok (double check it), then maybe your firewall does not permit connectios to port 8080 from "untrusted" IPs (I mean "outside" your private network) - check it.
There are 10 types of people in this world, those who understand binary and those who don't
User avatar
jayshields
DevNet Resident
Posts: 1912
Joined: Mon Aug 22, 2005 12:11 pm
Location: Leeds/Manchester, England

Re: Forwarding a routers IP to a web server on an internal IP

Post by jayshields »

@Doug G: I now know the router settings pages like the back of my hand and there really are no settings.
@VladSun: I'm pretty sure it's configured to allow IPs from outside the network.

Anyway, I think I've found the problem. Turns out my ISP provides the routers with things like this hard-coded to be disabled. I realised this because the "Remote Management" option checkbox is greyed out in the settings and there doesn't seem to be any way of turning it on. This turns out to be a known issue, which I guess is related.

Weird thing is that remote management does actually work, because I gave a friend my IP and he got my router settings login page.

Another really awful thing is that it seems my ISP has hard-coded my login details into the router, so I can't swap the router out for another one! I might try it anyway later on though.
User avatar
VladSun
DevNet Master
Posts: 4313
Joined: Wed Jun 27, 2007 9:44 am
Location: Sofia, Bulgaria

Re: Forwarding a routers IP to a web server on an internal IP

Post by VladSun »

In other words - your "ISP" is not an "Internet Service Provider" but something else ;)
There are 10 types of people in this world, those who understand binary and those who don't
Post Reply