Page 1 of 2 1 2 LastLast
Results 1 to 10 of 14

Thread: Zm Crash

  1. Default Zm Crash

    Zombie Mod just crashed from a Client Overflow.

    Timeleft was being spammed.

    Just informing.

  2. Default

    Can we write an eventscript to prevent timeleft floods?

    Possibly auto-permabanning the perpetrator?

  3. Default

    Quote Originally Posted by walterbrunswick View Post
    Can we write an eventscript to prevent timeleft floods?

    Possibly auto-permabanning the perpetrator?
    That would be awesome...

  4. Default

    Quote Originally Posted by ๖ReS View Post
    That would be awesome...
    # Here I'll help you start...

    import es;
    import playerlib;

    def es_client_command(event_var):
    if(str(event_var['command']) == 'timeleft'):
    es.tell(event_var['userid'], "Banned for flooding timeleft.");
    es.server.queuecmd("banid %i %s" %(0, event_var['userid'], ));

    # I'm too lazy to write the rest... good luck ... :)




    Yay for programming experience :D
    Last edited by walterbrunswick; 07-08-2009 at 04:26 PM.

  5. Default

    Quote Originally Posted by mastercheff View Post
    heres the link for whats causing all this timeleft crap http://www.fpsbanana.com/scripts/2704 your welcome :P
    It's an everlasting war between the black-hat hackers and the white-hat hackers.

    The wannabe script kiddies are cannon fodder.

    And computer science advances...

  6. Default

    well i hope they make a campaign to get rid of that script :P i hate server crashes =(

  7. Default

    Okay I updated my script...

    Nothing fancy. Just a starting point. You can use whatever database you prefer. I was using dictionaries and tuples to store the userid and timediff integers.

    TODO: More state control.

    NOTE: DO NOT FIRE THIS BITCH UP, THE LOGIC IS WRONG! I need to fix that once I stop being lazy.

    import es;
    import time;

    # Set these values to your preference.
    # floodthresh requests in timeforflood seconds...

    floodthresh = 5;
    timeforflood = 10;

    cl = dict();

    def es_client_command(event_var):
    if(str(event_var['command']) == 'timeleft'):
    userid = event_var['userid'];
    ct = abs(time.time());
    if(not(cl.has_key(userid))):
    cl[userid] = (1, ct);
    return;
    tdiff = cl.get(userid)[1] - ct;
    cl[userid] = (cl.get(userid)[0] + 1, ct);
    if((cl.get(userid)[0] > floodthresh) and (tdiff <= timeforflood)):
    es.tell(userid, "Banned for flooding timeleft (%i requests in % secs)." % (cl.get(userid)[0], tdiff));
    es.server.queuecmd("banid %i %s" %(0, userid, ));
    elif((cl.get(userid)[0] < floodthresh) and (tdiff > timeforflood)):
    cl[userid] = (0, 0);
    return;
    Last edited by walterbrunswick; 07-09-2009 at 09:56 PM.

  8. Default

    Autobanning :P Theres this guy i know thats amazing with scripts, and he has like basically a hack proof server. anyone who changes there name more then 3 times on a server, is auto kicked, anyone without a name, is auto kicked. and they have some sort of auto ban system where, if anyone tries rcon, once, and gets it wrong, is perma banned, and also alot of other cool stuff :P

  9. Default

    Quote Originally Posted by Apocalypse View Post
    Autobanning :P Theres this guy i know thats amazing with scripts, and he has like basically a hack proof server. anyone who changes there name more then 3 times on a server, is auto kicked, anyone without a name, is auto kicked. and they have some sort of auto ban system where, if anyone tries rcon, once, and gets it wrong, is perma banned, and also alot of other cool stuff :P
    Apoc you should use your hacking skills for good:)

    DON'T JOIN THE DARK SIDE! RESISTANCE!

    Also, who is this guy? Link me!

  10. Default

    yea he sounds cool

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •