diff --git a/inc/config.php b/inc/config.php index fb51dc3b..4dc8ec1e 100644 --- a/inc/config.php +++ b/inc/config.php @@ -343,11 +343,11 @@ * Read more: http://tinyboard.org/docs/index.php?p=Config/Filters */ - // Minimum time between between each post by the same IP address. + // Minimum time between between each post by the same IP address. $config['flood_time_ip'] = 10; // Minimum time between between each post with the exact same content $config['flood_time_repost'] = 30; - // Minimum time between between each post with the exact same content AND same IP address. + // Minimum time between between each post with the exact same content AND same IP address. $config['flood_time_ip_repost'] = 120; // Minimum time between between any opening post on the same board. $config['flood_time_board_op'] = 30; @@ -355,47 +355,47 @@ $config['flood_time_ip_op'] = 180; // Minimum time between posts by the same IP address (all boards). - $config['filters'][] = array( - 'condition' => array( + $config['filters'][] = array( + 'condition' => array( 'flood-match' => array('ip'), // Only match IP address 'flood-time' => &$config['flood_time_ip'] - ), - 'action' => 'reject', + ), + 'action' => 'reject', 'message' => &$config['error']['flood'] - ); + ); // Minimum time between between each post with the exact same content (all boards) - $config['filters'][] = array( - 'condition' => array( + $config['filters'][] = array( + 'condition' => array( 'flood-match' => array('body'), // Only match post body 'flood-time' => &$config['flood_time_repost'] - ), - 'action' => 'reject', - 'message' => &$config['error']['flood'] - ); + ), + 'action' => 'reject', + 'message' => &$config['error']['flood'] + ); // Minimum time between posts by the same IP address with the same text (all boards) - $config['filters'][] = array( - 'condition' => array( + $config['filters'][] = array( + 'condition' => array( 'flood-match' => array('ip', 'body'), // Only match IP address and post body 'flood-time' => &$config['flood_time_ip_repost'], - '!body' => '/^$/', // Post body is NOT empty - ), - 'action' => 'reject', - 'message' => &$config['error']['flood'] - ); + '!body' => '/^$/', // Post body is NOT empty + ), + 'action' => 'reject', + 'message' => &$config['error']['flood'] + ); // Minimum time between between each opening post (same board) - $config['filters'][] = array( - 'condition' => array( + $config['filters'][] = array( + 'condition' => array( 'OP' => true, 'flood-match' => array('board'), // Only match OPs on the same board 'flood-match' => array('isop'), 'flood-time' => &$config['flood_time_board_op'] - ), - 'action' => 'reject', + ), + 'action' => 'reject', 'message' => 'New threads are being created too quickly.' - ); + ); // Minimum time between opening posts by the same IP address (all boards) $config['filters'][] = array(