Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Port Forwarding ?

Status
Not open for further replies.

ockerb

Technical User
Oct 11, 2002
139
0
0
Port Forwarding is mentioned a lot when using various torrent clients. I haven't quite grasped the concept of it yet and remain slightly confused. Can some give me a quick lesson on this in layman's terms please. Specifically matching ports to IP addresses. Thanks for your time
Ockerb
 
When you use a Broadband router to allow multiple connections to a single "Public" or "WAN" or "Internet address", the router uses "NAT" - Network Translation to create behind the router a private network that will forward IP requests that are not found in the LAN to the public interface -- the internet.

So if your IP is a NAT or private IP of 192.168.1.101, you can talk to a fellow LAN member workstation at 192.168.1.103 without bothering anyone on the internet.

Now you need to access an address that is not a network segment or subnet mask fit for the 192.168.1.x that allows you to reach others in your LAN. This is exactly what a router means -- it sends the request for those IP addresses outside using its "WAN" or "Internet" connection, and hopes somebody there can help.

This works in the main perfectly well if you are requesting an IP address outside of your LAN; the router reads the IP number, and forwards it outbound. It attaches a few little bits so that if there is a response, it knows to send it to you, rather than someone else on the LAN.

Now you want you best friend in the whole world to be able to use Remote Desktop (or similar) services. You have to give them your "Public" or "Internet" IP, as your private LAN IP is of no help.

So your best friend requests to use Remote Desktop to your machine, he does not use your LAN IP of 192.168.1.101, but your public IP.

So what is the router supposed to do with this request from the outside? For outbound communications, it can add some information to know how to handle a reply from the outside and make sure you get it. Now we have a case of an unsolicited request on your Public IP address, and the router is clueless as to whom to send it to.

Thus, the port forwarding entry. You explicitly state that if an outside request appears (for the Remote Desktop example from earlier) on TCP port 3389, forward that request to local LAN IP 192.168.1.101 which is me.

Without instructions as to handle unsolicited requests on the public interface of the router, the router has no clue as to whom to send this packet of information to so that it is handled appropriately.

The point of port forwarding is to allow a NAT private LAN client to receive communications on specified ports so that it can perform as a server, rather than the less active role required to open a simple web page.

You need to tell even the most simple of routers what to do with a requires from "outside" you LAN on port type xxx, and port number xxxx, otherwise the communication from your best friend will never reach you.


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top