Koozali.org: home of the SME Server

question about ports

CD

question about ports
« on: March 08, 2003, 03:57:39 PM »
Hello everyone I downloaded e-smith portforwarding-0.1.0-20.rpm and also downloaded e-smith-packetfilter-1.13.0-04.noarch.rpm.  And then installed the packetfilter using these commands:
# rpm -Uvh --force e-smith-packetfilter-1.13.0-04.noarch.rpm --nodeps
# /sbin/e-smith/signal-event post-upgrade
# service masq restart

Then installed the portforwarding -0.1.0-20.rpm and rebooted. I now have the portforwarding option in my service manager now. The question I have is
what is the source port and destination port mean? I know the destination ip is the ip of my lan computer. Lets say I wanted to forward for example 28900 (Master Server List Request) for gamespy arcade would 28900 be the source or the destination port also whats the  difference between the two. To me 28900 would be the source port but what would I have the destination port be in this situation. Thanks

Terry Brummell

Re: question about ports
« Reply #1 on: March 08, 2003, 06:03:12 PM »
Generally you keep the source and destination ports the same, but that is not always true.  The source port is the port you wish to forward on the gateway, the destination is the port the service is listening on on the internal machine.
An example of forwarding to different ports would be for a mail scanner.  You'd forward port 25 from the gateway to say port 1025 (where the scanner has been programmed to listen) on the internal mail scanner, which then scans and sends to port 25 on the mail server for distribution to the local accounts.
In your case, for gamespy, you just want to keep the source and destination the same.
HTH, Terry

CD

Re: question about ports
« Reply #2 on: March 08, 2003, 06:33:25 PM »
KK thanks  terry,well I tried to do the ports listed for gamespy with the same ports listed but I don't think the portforwarding is working properly Not sure why. Terry is whats the difference in tcp and udp all that I added the privious ports was for tcp not sure If I should go through the same ports and add it for udp also, but if anyone plays games and also plays on gamespy and care to help me out that would be good also is there a program to tell me every port that is open,closed and stealth both tcp and udp? Thanks

Terry Brummell

Re: question about ports
« Reply #3 on: March 08, 2003, 06:55:39 PM »
Well, that's a whole different conversation in networking, but I'll give it a quick shot.  TCP is used as a transport protocol, it establishes connections between the remote and host.  All packets transfered are sequentially numbered, if the remote misses a packet in the sequence it can request that the packet be sent again.  UDP is also a tranport protocol, there is no connection between the remote and host established, packets are not sequentially numbered.  If a message is sent using UDP, the remote server does not know if it has a complete packet or not, it reassembles what it has and goes with it, it cannot request a packet be sent again because it doesn't know which in the sequence it is missing.  There are pro's and con's for both protocols, TCP is better at getting complete data streams from host to remote because of its checksums, but UDP is much faster because there is no checksums or connections made.
I'd check with gamespy to see if they are using TCP or UDP.
Ohh ya, also, UDP packets cannot be forwarded....

Terry

CD

Re: question about ports
« Reply #4 on: March 09, 2003, 10:12:10 PM »
Ok thanks man, I don't think this is working or not everytime I free a port nothing happens different :( I wish they was a way I could test it to be sure tho. And also I wish there was a better program made for this purhaps range of ports like warzone2100 it's some where between 6000-8000 I'm not sure what ports exactly I just know that range is there a way possible to do ranges with this portforwarding thing? thanks