Talk:Scripts:UDP Based Advert System

From BF2 Technical Information Wiki
Revision as of 00:57, 11 October 2005 by Kybber (Talk | contribs)

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

Hi, what about the security of this script? Is it possible that other people can send messages on my server?

Martin

Just a concept

The scripts are not supposed to work - they simply outline the concept of how a UDP-based ad-system could work.

Necessary precautions need to be made in such a system to ensure that unwanted programs may not announce on your server. This can be handled in many ways, but the easiest by far would be to bind the ad-server to listen to localhost only and let the ad-client run on localhost. Other approaches, if you want to have the ad-client on a different system, could be to use a firewall which only allows traffic from wherever the client is located, or even better: encryption/digital signing of the messages.

--Kybber 04:35, 5 Jul 2005 (MDT)

One thing, then I am happy...

Hi, OK, but I can't program python so it would be really great when you tell me how to bind the ad-server to listen to localhost.

Thanks, Martin

Sorry for ridiculously late response

This is already done in the script. Look for this:

port = 29600
addr = ('localhost',port)
s = socket.socket(socket.AF_INET,socket.SOCK_DGRAM) # Defines the socket object
s.bind(addr) # Binds the socket to listen to localhost, port 29600 as defined above

--Kybber 02:57, 11 Oct 2005 (MDT)

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox