cliss/accidentalbot — pull request #6 by jeremybanks (2014-06-22 05:36:27+00:00)
Title: Disconnect IP addresses which are flooding requests/messages

(Depends on #5, since that gives us accurate IP addresses.)

Very basic, probably inadequate, but hopefully helpful DOS protection. This disconnects any users who send more than 50 messages or connection requests in a 5-second window. (This could probably be set *a lot* more aggressively if you wanted.)

In my limited testing this made a significant difference in how much a single flooding user could affect the responsiveness for other users. However, my testing failed to bring down a local server or a Heroku instance, so it might be much less than whatever this was attacking during the last show.