function helper_honeypot_reject in Helper 7
Implements hook_honeypot_reject().
Automatically block the IP addresses of anonymous honeypot failures.
See also
https://drupal.org/comment/8579275#comment-8579275
https://drupal.org/sandbox/pwetosaurus/2148397
File
- ./
helper.module, line 282
Code
function helper_honeypot_reject($form_id, $uid, $type) {
if (empty($uid) && helper_is_tweak_enabled('honeypot_block_anonymous_ips')) {
$limit = variable_get('helper_honeybot_block_anonymous_ip_threshold', 2);
if (!flood_is_allowed('honeypot', $limit)) {
system_block_ip_action();
}
}
}