Ticket #11 (assigned task)

Opened 3 years ago

Last modified 2 years ago

Flood Protection

Reported by: anonymous Assigned to: giuseppe.bilotta (accepted)
Priority: normal Milestone: rbot 1.0
Component: irc Version: 0.9.9
Severity: normal Keywords: flood protection
Cc:

Description

Per-user/client and global flood protection options, eggdrop style, as in lines/timeframe

a per-user flood protection setting of 4/30 would stop responding to queries from any user who has passed 4 queries in a 30 second period. a global setting of 12/60 would prevent the bot from sending out more than 12 responses in a 1 minute period.

this is a pretty important feature. (Just had a major issue with bots triggering each other repeatedly as a result of an attacker, and flood protection would have stopped this)

Attachments

Flood.ini (11.7 kB) - added by anonymous on 04/17/06 17:39:49.

Change History

04/17/06 17:39:49 changed by anonymous

  • attachment Flood.ini added.

07/24/06 13:21:40 changed by giuseppe.bilotta

The new message queueing mechanism is a good step in this direction. If not else, bot-flooding in one channel doesn't hurt all other channels, or at least hurts a lot less. Rather than actually ignoring flooding users, I would suggest delaying responses directed at them.

07/29/06 05:58:21 changed by giuseppe.bilotta

  • owner changed from giblet to giuseppe.bilotta.
  • type changed from defect to task.

Section 5.8 of RFC 2813 reads:

5.8 Flood control of clients

   With a large network of interconnected IRC servers, it is quite easy
   for any single client attached to the network to supply a continuous
   stream of messages that result in not only flooding the network, but
   also degrading the level of service provided to others.  Rather than
   require every 'victim' to provide their own protection, flood
   protection was written into the server and is applied to all clients
   except services.  The current algorithm is as follows:

   * check to see if client's `message timer' is less than current time
     (set to be equal if it is);

   * read any data present from the client;

   * while the timer is less than ten (10) seconds ahead of the current
     time, parse any present messages and penalize the client by two (2)
     seconds for each message;

   * additional penalties MAY be used for specific commands which
     generate a lot of traffic across the network.

   This in essence means that the client may send one (1) message every
   two (2) seconds without being adversely affected.  Services MAY also
   be subject to this mechanism.

I'll look into implementing it this way.

10/23/06 17:22:50 changed by giuseppe.bilotta

  • milestone changed from rbot 0.9.10 to rbot 1.0.

10/23/06 19:45:23 changed by giuseppe.bilotta

  • status changed from new to assigned.

10/23/06 20:27:54 changed by giuseppe.bilotta

  • component changed from misc to irc.

10/27/06 10:25:40 changed by giuseppe.bilotta

Proper global flood protection has been implemented in [551].

I'm leaving this ticket open because of the suggestion of per-user flood protection.