Force client_flood_burst_rate and client_flood_burst_rate to at least rfc1459 values (5).

This commit is contained in:
Jilles Tjoelker 2011-10-04 22:16:01 +02:00
parent 5a72f20c2c
commit 894325fe41

View file

@ -863,9 +863,13 @@ validate_conf(void)
}
/* RFC 1459 says 1 message per 2 seconds on average is acceptable,
* so allow at least that.
/* RFC 1459 says 1 message per 2 seconds on average and bursts of
* 5 messages are acceptable, so allow at least that.
*/
if(ConfigFileEntry.client_flood_burst_rate < 5)
ConfigFileEntry.client_flood_burst_rate = 5;
if(ConfigFileEntry.client_flood_burst_max < 5)
ConfigFileEntry.client_flood_burst_max = 5;
if(ConfigFileEntry.client_flood_message_time >
ConfigFileEntry.client_flood_message_num * 2)
ConfigFileEntry.client_flood_message_time =