🎉 Celebrating 25 Years of GameDev.net! 🎉
Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!
quake2 Network engine
Someone mentioned to me once that it is vary hard to get a fake client to stay connected to a Quake3Arena server as its using some form of packet sequencing that they don''t know about. And I have had a wee look at the quake2.31 source code and have noticed a comment about:
"combined with the tight window of valid
reliable acknowledgement numbers provides protection against malicious
address spoofing." in net_chan.c
I take it that some more advanced form of packet sequencing is being used in Q2/Q3 can anyone explain it a bit more to me or point me to the bits in the Q2 source that explain it a bit more? I know the Quake3 method is likely to be more advanced but it would be nice to see how it was done in Q2 as well. I know the Q3A Mod source quite well but don''t know my way about the Q2 source at all really so any help would be apreciated!!!
Cheers,
Convict@Large
A common technique is to include a psuedo-random number in the packet. Both the server and the client use the same generator and seed, and if the client starts sending bad packets, the server disconnects them.
I take it the seed is set by the server at the start of the game and sent ot each client on connection. How do you define the random number as being bad? Once it (the random num from the client) is outside a range generated by the server?
Convict@Large
Convict@Large
most random numbers are generated using a pseudo-random algorithm. So you seed the algo on the server and the client with the same seed (possibly generated by the server and sent to the client). Then both algos will generate the exact same sequence of random numbers. So, if a client (malicious) doesn''t know the algo, then it can''t duplicate the sequence and is disconnected.
-Brannon
-Brannon
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement