Linux 软件免费装
Banner图

Grey Rock Block Synchroniser for Wordfence and Cloudflare

开发者 greyscalezone
更新时间 2026年7月19日 05:33
PHP版本: 8.1 及以上
WordPress版本: 7.0
版权: GPLv2 or later
版权网址: 版权信息

标签

security multisite firewall cloudflare wordfence

下载

1.3.0 1.3.1 1.1.11 1.1.12 1.2.0 1.2.1 1.2.2

详情介绍:

Grey Rock Block Synchroniser for Wordfence and Cloudflare sends qualifying Wordfence firewall blocks to Cloudflare so hostile traffic can be stopped at Cloudflare's network edge before it reaches the WordPress server. Why Grey Rock? The name Grey Rock is inspired by the grey rock method: becoming uninteresting and unrewarding to someone seeking attention or a reaction. Grey Rock applies that concept to hostile website traffic. Wordfence identifies qualifying blocked IP addresses, and Grey Rock synchronises them with Cloudflare. Cloudflare can then stop those addresses at the network edge before their requests reach WordPress. The objective is simple: make your website boring to repeat attackers. Instead of allowing the same hostile traffic to keep reaching the server, Grey Rock helps the site respond with less exposure, less interaction and fewer consumed server resources. Grey Rock does not replace Wordfence, Cloudflare or a layered security program. It connects them so qualifying Wordfence blocks can be enforced earlier, closer to the source of the traffic. The plugin supports two Cloudflare destinations. Zone Access Rules Creates Cloudflare IP block rules for one zone. Use this mode when Wordfence blocks should protect one Cloudflare zone. Account IP List Adds IP addresses to a reusable Cloudflare account-level IP list. Use this mode when several domains or Cloudflare zones should share the same list. An Account IP List does not block traffic by itself. You must create a Cloudflare Custom Rule with the Block action in every zone that should use the list. Example rule: ip.src in $wordfence_hot_blocklist The recommended list name is: wordfence_hot_blocklist Current and historical Wordfence blocks The plugin can synchronise: Historical synchronisation is configurable: Repeated events from the same address are deduplicated before synchronisation. Invalid, private and reserved IP addresses are rejected during historical-event processing. DDNS-resolved administrator allow list The optional administrator allow list is intended for administrators whose public address changes and is already maintained by a DDNS provider. Enter a hostname only, for example: admin.example.com Do not enter a URL, path or port. Grey Rock does not create or update DNS records. It also does not provide a DDNS service or require DNS editing permission. If Cloudflare hosts the DDNS record, configure the dedicated hostname as DNS only. A proxied hostname returns Cloudflare proxy addresses instead of the administrator's actual public address. Grey Rock resolves public A and AAAA records. Private, loopback, link-local, reserved and invalid addresses are rejected. Multiple valid public results are displayed and handled separately. Configuration procedure:
  1. Confirm that the DDNS hostname returns the administrator's current public address.
  2. Enter the hostname in DDNS domain.
  3. Select Save settings and resolve now.
  4. Confirm the read-only Resolved addresses values.
  5. Select Administrator allow list.
  6. Save the settings.
  7. Run synchronisation or wait for the next scheduled run.
When enabled, the resolved addresses are excluded from current and historical Wordfence candidates. During synchronisation, Grey Rock removes those addresses from the configured Cloudflare Account IP List or Zone Access Rules destination. Related local synchronisation records are cleared only after Cloudflare confirms the required final state. A failed Cloudflare removal causes the synchronisation to fail so a later run can retry. Grey Rock refreshes the lookup when settings are saved and before synchronisation when the previous attempt is at least five minutes old. A temporary DNS failure retains the last successful addresses for up to 24 hours. After that period, no stored address remains effective until resolution succeeds. A successful lookup replaces the old address set. Previous addresses are no longer trusted after DNS returns a different set. IPv4 and IPv6 addresses remain exact individual addresses. Grey Rock does not expand IPv6 addresses to /64 and does not create inferred CIDR allow-list entries. In multisite, Network Admin may provide one shared DDNS hostname for all inheriting sites. Site-specific configurations may use a separate hostname. A DNS-only DDNS hostname exposes its current public address through DNS. Use a dedicated non-web hostname and consider that disclosure before enabling the feature. Scheduling Grey Rock supports three scheduling methods: Available intervals are every minute, every 5 minutes, every 15 minutes and hourly. WP-Cron is request-driven. Selecting every minute makes synchronization eligible every minute but does not guarantee execution at an exact minute boundary. External scheduling does not require Docker. An ordinary WordPress installation can use: wp --path=/var/www/html grey-rock-block-synchroniser-for-wordfence-and-cloudflare sync-site --due A multisite network can use: wp --path=/var/www/html grey-rock-block-synchroniser-for-wordfence-and-cloudflare sync-network --due sync-network processes only sites inheriting Network Admin settings. A selected multisite site can use sync-site with WP-CLI's --url parameter. An external scheduler may check every minute. The --due command reads the GUI interval and exits successfully without synchronizing when the interval has not elapsed or External scheduler is not selected. The GUI buttons and --force commands run immediately regardless of scheduling method or interval. Every attempt, including a manual or failed attempt, resets the due interval. A site-level atomic lock prevents overlapping synchronization. An abandoned lock becomes stale after 15 minutes. Selecting External scheduler or Manual synchronization only removes only Grey Rock's synchronization event. It does not disable WordPress cron globally. Cleanup is separate maintenance and remains scheduled hourly in all three modes. Complete systemd, traditional cron, hosting control-panel and optional Docker Compose examples are provided in the GitHub README. Multisite support When network activated: Manual management and diagnostics The plugin provides: Wordfence compatibility Wordfence does not provide a stable public API for every block source used by this plugin. Grey Rock checks whether the installed Wordfence active-block interface is available before using it. When that interface is unavailable, historical WAF synchronisation continues through the Wordfence event table. A future Wordfence release could change its internal class or database schema. Such a change may require a Grey Rock compatibility update. Independence and trademarks Grey Rock Block Synchroniser for Wordfence and Cloudflare is developed independently by Greyscale Zone. This plugin is not affiliated with, endorsed by or sponsored by Wordfence or Cloudflare. Wordfence and Cloudflare are trademarks of their respective owners.

安装:

  1. Install and activate Wordfence.
  2. Install and activate Grey Rock Block Synchroniser for Wordfence and Cloudflare.
  3. Open Grey Rock Block Synchroniser in WordPress Admin.
  4. For shared multisite settings, open the plugin in Network Admin.
Recommended Account IP List setup
  1. In Cloudflare, open Settings → Configurations → Lists.
  2. Select Create new list.
  3. Create an IP list named wordfence_hot_blocklist.
  4. Create a restricted Cloudflare custom API token.
  5. Add Account → Account Filter Lists → Edit.
  6. Restrict the token to the account that owns the list.
  7. Copy the API token.
  8. Copy the Account ID from the Cloudflare account or zone Overview page.
  9. In Grey Rock, select Account IP List.
  10. Enter the API token, Account ID and List Name.
  11. Enter the List Name without the dollar sign.
  12. Select the scheduling method, interval, historical lookback and event threshold.
  13. Optionally enter a DNS-only hostname in DDNS domain.
  14. Optionally select Administrator allow list.
  15. Save the settings and confirm the read-only resolved addresses.
  16. Select Validate Saved Cloudflare Configuration.
  17. Run a test block using a safe public IP address.
The token does not need DNS editing permission. Do not use a Global API Key. Create the Cloudflare blocking rule An Account IP List does not block traffic by itself. Repeat these steps in every protected Cloudflare zone:
  1. Open Security rules → Create rule → Custom rules.
  2. Enter a descriptive rule name.
  3. Enter ip.src in $wordfence_hot_blocklist.
  4. Select Block as the action.
  5. Deploy the rule.
In the older Cloudflare dashboard, use Security → WAF → Custom rules. Verify operation
  1. Select Sync Now or Synchronise Network Now.
  2. Confirm that qualifying addresses appear in the Cloudflare list.
  3. Open Synchronisation Log.
  4. Confirm that Site Admin shows only the current site's records.
  5. Confirm that Network Admin combines records from every site.
A site keeps its own Synchronisation Log when it uses Network Admin configuration. Configuration inheritance does not expose another site's records in Site Admin. Zone Access Rules alternative For one zone, select Zone Access Rules and create a token with: Enter the token and Zone ID in Grey Rock. This mode does not use an account list or a Custom Rule.

屏幕截图:

  • Validate the Cloudflare configuration, test blocking, manage list entries manually, and synchronise the multisite network.
  • Review recent site-specific synchronisation activity across the WordPress multisite network.
  • View the Cloudflare Account IP List created and maintained by Grey Rock Block Synchroniser.
  • Review synchronised and manually managed IP addresses stored in the configured Cloudflare list.
  • Configure a Cloudflare Custom Rule to block requests from addresses contained in the synchronised IP list.

升级注意事项:

1.3.1 Adds DDNS-resolved administrator allow-list protection, automatic removal of trusted addresses from Cloudflare block destinations, multisite cleanup and exact IPv4 and IPv6 handling. 1.2.2 Corrects Synchronisation Log rendering and naming, preserves multisite log scope and adds complete Cloudflare setup instructions. 1.2.1 Maintenance release correcting release automation, continuous integration, repository documentation and supported-version metadata. Runtime synchronisation behaviour is unchanged. 1.2.0 Security-focused release that hardens synchronization locking, public-IP and Cloudflare credential validation, API response handling, HTTP transport and stored reason text.

常见问题:

Does Grey Rock update my DDNS record?

No. The existing DDNS provider remains responsible for updating DNS. Grey Rock only reads the hostname's public A and AAAA results.

Why must a Cloudflare-hosted DDNS hostname be DNS only?

A proxied hostname returns Cloudflare proxy addresses. Grey Rock needs the administrator's actual public address, so the dedicated DDNS hostname must be DNS only.

When is a trusted address removed from Cloudflare?

Saving the settings performs the DNS lookup. Removal occurs during the next synchronisation. The address is also excluded from future current and historical Wordfence candidates.

What happens when DNS temporarily fails?

The last successful public addresses remain trusted for up to 24 hours. After that grace period, no stored address remains effective until a lookup succeeds.

What happens when the DDNS address changes?

A successful lookup replaces the previous address set. The new exact addresses become trusted and the old addresses are no longer included in the administrator allow list.

Does Grey Rock create an IPv6 /64 allow-list entry?

No. Each resolved IPv6 address remains an exact individual address.

Does the plugin require a Cloudflare Global API Key?

No. Use a restricted Cloudflare API token.

Does an Account IP List block traffic by itself?

No. Create a Cloudflare Custom Rule with the Block action in every zone that should use the list.

Can one Cloudflare list protect several domains?

Yes. Account IP List mode can maintain one reusable account-level list. Each Cloudflare zone must have a Custom Rule that references the list.

Does the plugin synchronise historical Wordfence firewall events?

Yes. It reads qualifying Wordfence WAF events recorded as blocked:waf within the configured lookback period.

What historical lookback periods are available?

1, 3, 6, 12 and 24 hours.

Can I require several Wordfence block events before an IP is sent to Cloudflare?

Yes. The historical block threshold accepts whole numbers from 1 through 100.

What happens if Wordfence does not expose its active-block interface?

The plugin continues using historical Wordfence WAF events instead of terminating synchronisation.

Does the plugin support WordPress multisite?

Yes. It supports shared Network Admin settings, optional site-specific overrides, network synchronisation for inheriting sites and a combined Network Admin synchronisation log.

Why are cleanup and reconciliation unavailable on some inheriting sites?

An inheriting site may share a Cloudflare destination with other sites. Its local log cannot determine whether another site still requires the same Cloudflare entry.

Does the every-minute interval run at an exact time?

Not necessarily when WordPress WP-Cron is selected. WP-Cron is request-driven and may run late. Use External scheduler with a reliable system scheduler when timing must not depend on WordPress traffic.

Is Docker required for external scheduling?

No. The plugin provides ordinary WP-CLI commands. Docker Compose is only an optional deployment-specific wrapper.

How does an external scheduler use the GUI interval?

The scheduler may invoke sync-site --due or sync-network --due every minute. Grey Rock reads the selected GUI interval and exits successfully without synchronizing until that interval has elapsed.

What is the difference between --due and --force?

--due works only with External scheduler and obeys the configured interval. --force runs immediately regardless of the scheduling method or interval.

What happens after a manual or failed synchronization attempt?

Grey Rock records the start of every attempt. The next --due invocation waits until the configured interval has elapsed, even when the previous attempt failed or was started manually.

How are overlapping runs prevented?

Each site acquires an atomic synchronization lock. An abandoned lock becomes stale after 15 minutes.

Does External scheduler disable all WordPress cron events?

No. It removes only Grey Rock's synchronization event. Hourly Grey Rock cleanup remains scheduled, and other WordPress cron events are unaffected.

How do I return to WordPress WP-Cron?

Disable the external system timer or cron job, select WordPress WP-Cron in Grey Rock settings, select the required interval and save the settings.

Does uninstalling the plugin remove Cloudflare entries?

No. Review and remove unwanted Cloudflare rules or list entries separately after uninstalling the plugin.

Is the plugin affiliated with Wordfence or Cloudflare?

No.

更新日志:

1.3.1 1.2.2 1.2.1 1.2.0 1.1.12 1.1.11 1.1.10 1.1.9 1.1.8 1.1.7 1.1.6 1.1.5 1.1.2