As a hacker, it is necessary to know the basics of port opening and forwarding. Why is that? Computer enthusiasts usually setup firewalls so that they can be online with less worries of an outside intrusion from the untamed Internet. They also usually have programs that require access to a port. Some programs include BitTorrent (Shame on you!), P2P Gnutella programs like Phex (Shame on you!), NetMeeting, some instant messaging programs, and servers (like HTTP, Remote Desktop, FTP). Since firewalls block all ports, it is necessary to manually open the ones that are needed.
Most firewall programs let you choose which ports to leave open. I use the native Windows XP Firewall, which makes it pretty simple.
Go to the “Control Panel” and open “Network Connections.” Right click on the connection that you use to access the Internet. Most of the time, it is “Local Area Connection.” Select “Properties”.
Go to the “Advanced” tab and click “Settings” under “Windows Firewall.”
Depending on which version of Windows XP you have (Original Build, SP1, SP2) you may see something different. Regardless, you should have upgraded to SP2. If not, shame on you!
Go to the Exceptions Tab (in SP2).
If you just want to give a program unlimited access to any port, click “Add Program.” I personally think that is too risky so I just give access on a port-by-port basis and click “Add Port.”
Give the port a name, any name, a name that will inspire and astound you, a name that is descriptive of the activity that will be going through it (i.e. “Gnuttella Traffic”). Or, you can just call it “asdfjkah jfhdas;jh fj;;sjfku;.” It’s your pick. “Port Number” is a bit more restrictive. Give the number of the port that needs to be opened. You may have to look this up online if it is not a common port. HTTP uses 80, FTP uses 21, P2P Gnutella uses a range of ports, as does BitTorrnet. Specify which protocol you want to use, TCP or UDP. To be sure, just do this process twice selecting TCP the first time and UDP the second time.
OK? OK! Click OK, OK, OK, OK! Voila! You have opened a port!
You’ve opened a port. So, the program (or server) should work right? Wrong! If you are sharing an Internet connection with anyone else, if you are sharing an IP address, or if you are using a router, more than likely, port forwarding is necessary. Why? In a typical home networking setup, you have the Internet coming from a DSL or Cable modem. That modem is connected to a router, which is then connected to your computers by Ethernet or WiFi. The router is the device that the Internet sees; it holds the public IP address. Your computer, on the other hand, is invisible to the Internet as it holds a local IP address (normally 192.168.0.2). Port forwarding is necessary in the router because computers will send information directed to the public IP address and the router needs to know where to send that information, your computer or any other computers on the network.
To forward a port, you need to have access to the device (i.e. router) that holds the public IP address. For most networks, this is your local IP address with the last number at 1. For example, if your computer is on 192.168.55.100, the administration console for the device is 192.168.55.1. Just type that into an Internet browser. When it asks for the username and password it is usually “admin” and no password. See the router manual or just hard reset it (with a paperclip) if you don’t remember the password.
Administration consoles are different with each router. Basically look for “port forwarding,” “firewall,” or “virtual server.” All the routers that I have used mask port forwarding as “Virtual Server.”
Basically, you will enter any name for the port that you want to forward. For Private IP, give the IP address of the computer on your network that will need this port. Protocol is whichever one you need for your setup. Do both like you did in the port opening example above to make sure you will get correct access to the port. Private port is the port that is opened on your local computer end. Public port is the port that you want to forward on the router. Usually these two will be the same.
Presto! You have port forwarding! If you have any questions, leave a comment and I will try to answer them.