WordPress 7.1.2: critical core security fix. Update now, then check inactive themes and comments.

Details

Developers

Filter secnin_cf_check_blocked_hosts

Re-enable hostname reverse-DNS matching in Filter Suspicious Queries. Off by default in current WP Security Ninja versions.

Filter Suspicious Queries blocks suspicious URI, query string, user agent, and referrer patterns by default. Hostname reverse-DNS matching (the blocked-hosts part of the 8G rules) is off by default because it can trigger DNS lookups and false positives on normal browser visits.

Use this filter only when you understand the tradeoff and need hostname-based matching again.

User-facing context: Filter Suspicious Queries.

Enable hostname checks

add_filter( 'secnin_cf_check_blocked_hosts', '__return_true' );

With the filter returning true, blocked-hostname matching runs again. Customize the hostname list with blocked_hosts_items.

Disable explicitly (default behavior)

The default is false. You normally do not need a filter unless another snippet already forces hostname checks on:

add_filter( 'secnin_cf_check_blocked_hosts', '__return_false' );

Not sure how to add this code? See Add custom code to your website.

Still stuck? Get help or contact us.

Larger screenshot

Enlarged image