What Ports

From BF2 Technical Information Wiki
Revision as of 15:37, 12 November 2007 by Woody (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Introduction

Q:Why are you whining about this port thingy ?
A:Because it's fairly important to a server admin if he wants his server to be seen in the browser list AND to let people play on it.

Q: OMG! STFU!! EA have TOLD us what ports a server uses!
A: ahem that wasn't a question it was a statement..a FALSE one too!
see here..the "list" that they gave us does not diffrentiate on INCOMING and OUTGOING ports!
A fairly important little detail.

Q: I STILL don't understand why you are so anal about it!
A: well..1) I'm a bit security conscious 2) EA have said they will remove servers that don't respond properly on queries from browser/master server from the master server

Q: But<BZZZT>
A: ahh..I so love the defibrillator.

Well, onwards and upwards as they say :)

The first step

a little background: Linux Fedora Core 2 Kernel 2.4.22-1.2174.nptlsmp #1 SMP the server has 2 IP's

so first...

I set both sv.serverIP and sv.interfaceIP to the IP I wanted to use..seemed to do the trick.

now on running lsof -i | grep bf2 I get the following

UDP :29900 
UDP *:53667 
UDP :16567 
TCP *:4711 (LISTEN)
UDP *:55124 
UDP *:55125 UDP 29900 : Gamespy Port (but not the only one)
UDP 53667 : A random port, it changes for everytime you restart the server, i've put a sniffer on it and have not detected any traffic so far.

TCP 4711 : Rcon port, for remote managment (Rcon)
UDP 16567 : the game port, you know the one you tag on at the end of IP to join servers with
UDP 55124 : Voice IP BFServer port
UDP 55125 : Voice IP Server Port
  • so..first I didn't open ANY port..not possible to join..weird eh :)

opened UDP/16567 and UDP/29900 and things started flowing a little better.

  • rcon didnt work so I opened TCP/4711 and that was okay too.
  • Voice didnt work, and my firewall log started screaming about access to port UDP/55125, opened that and Voice started working.
  • Got a couple of buddies to join the server and watched the log for a while.

And sure enough, I start seeing drops in the log from people attempting to connect to UDP/29901-29904 , I open these too.

  • And my "mystery connection" from gamespy again...

Ive mentioned this one earlier, its connection attempts from aphexmaster1.gamespy.com aphexmaster2.gamespy.com

with source port of UDP/29910, oh well as EA has said they will block not only the "hacked" servers but also the "zero" ping server (servers that probably havent opened enough ports so the master server/client ain't getting ping data on them or something) I'm not taking ANY chances , open all traffic from these addresses on port 29910/UDP.

I've made a iptable ruleset for my server that works, take a look here for more info on this.

--Per 02:52, 25 Jun 2005 (MDT)

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox