Linux 软件免费装
Banner图

ScrapeLock – Content & AI Bot Protection

开发者 codebunnyhube
更新时间 2026年11月3日 03:31
PHP版本: 7.4 及以上
WordPress版本: 7.2
版权: GPLv2 or later
版权网址: 版权信息

标签

content protection bot protection rate limit anti-scraping ai bots

下载

3.3.1 3.4.2

详情介绍:

Most content protection plugins disable right click in the browser. Scrapers and AI crawlers never use a browser, so they are not affected. ScrapeLock works on the server, where automated copying actually happens, and keeps real visitors, customers and search engines unaffected. What makes ScrapeLock different Nothing can stop a determined human: whatever a visitor sees has already reached their device. ScrapeLock closes the automated routes and leaves traces: a block log, watermarks, a source link on copied text and a machine-readable rights reservation (TDM). Bots and limits Feeds, API and server rules Site Health, WP-CLI and AI agents On the page and images Lockdown

安装:

  1. Upload the scrapelock folder to /wp-content/plugins/, or install the plugin from the Plugins screen.
  2. Activate it.
  3. Go to Settings → ScrapeLock and choose a preset, or adjust each tab.
  4. If your site is behind Cloudflare or another proxy, set "Real visitor IP" first.
Upgrading from "Content Protect" (folder content-protect), the former name of this plugin: deactivate the old plugin, activate ScrapeLock. Your settings, tokens and log are kept. If you pasted the old Apache rules, replace the "# BEGIN Content Protect" block with the new "# BEGIN ScrapeLock" block.

屏幕截图:

  • Bots and limits: AI training crawlers, AI search assistants, fake search engine detection and the bot trap.
  • Feeds and API: token-protected XML feeds with per-feed statistics, and text hidden from REST, GraphQL and RSS.
  • Server rules: ready-made Cloudflare, Nginx and Apache rules generated for your own site.
  • Presets, Emergency Mode and the on-page protection settings.
  • Dashboard widget with the protection status and the last 24 hours.

常见问题:

Will it block Google or Bing?

No. Verified search engines are never limited or blocked. Only fake ones that pretend to be Googlebot or Bingbot are blocked.

Does it work with page cache?

ScrapeLock tells WP Rocket not to serve cached pages to the bots in its list, so they are always checked. Other pages served from page cache never reach the plugin: a bot that looks like a browser could read them without a limit. Turn on "Pre-cache check" in "Bots and limits" to apply the page limit and the blocks to those pages too, or use the rules in the "Server rules" tab for Nginx, Apache or Cloudflare.

What does the pre-cache check change on my server?

It adds two comment lines and one include line right after <?php at the top of wp-config.php. The line loads the check from the plugin's own folder; its settings, counters and events are plain data files (no PHP) in a protected folder with a random name inside the uploads directory, uploads/scrapelock/ (counters go to APCu instead, if your server has it). The check runs before the page cache and WordPress, without a database, and stops only always-blocked IPs, temporarily blocked IPs and visitors over the "Pages per minute" limit. Search engines, logged-in users, forms, wp-admin and the REST API are left to the normal check. If wp-config.php is not writable, the setting shows the lines to add yourself. Everything is removed when you turn the setting off or deactivate the plugin. Not available on multisite.

My site is behind Bunny CDN. What should I set?

If your server already replaces the IP (for example Nginx with real_ip_header X-Real-IP and the Bunny addresses in set_real_ip_from), keep "REMOTE_ADDR": ScrapeLock tells you it is correct. Otherwise set "Real visitor IP" to X-Real-IP and turn on "Trust Bunny CDN addresses"; ScrapeLock downloads the official list of Bunny edge servers and trusts the header only from them. When every visitor appears with a Bunny address, it shows a button that does this for you.

Can I allow ChatGPT or Perplexity search but block training?

Yes. Enable "Allow AI search engines and assistants" in the "Bots and limits" tab. Training crawlers stay blocked. With "Verify AI search bots" on, only requests from the official OpenAI and Perplexity addresses count as their bots; scanners that only copy the name get a 403.

My site is behind Cloudflare. What should I set?

In "Bots and limits", set "Real visitor IP" to CF-Connecting-IP and keep "Trust Cloudflare addresses" on. If ScrapeLock sees that every visitor arrives from a Cloudflare address, it shows a button that does this for you. With Nginx, also set real_ip_header CF-Connecting-IP; and the Cloudflare ranges with set_real_ip_from, so the server rules see the real visitor IP.

Can ScrapeLock block scrapers at Cloudflare or Bunny CDN?

Yes, since 3.1. In "Bots and limits" → "Blocking at the CDN", choose Cloudflare or Bunny CDN and enter the zone ID and a token. For Cloudflare, create an API token with the single permission Zone → Firewall Services → Edit, for this zone only; for Bunny CDN, use your account's API key. You can put the token in wp-config.php instead (define( 'SCRAPELOCK_EDGE_TOKEN', '…' );), so it is not stored in the database. From then on, every IP ScrapeLock blocks temporarily is also blocked at the CDN within a minute or two, and the block is removed there when it ends. The site must be served through that CDN (for Cloudflare: proxied, orange cloud). Rules you made yourself are never changed. Administrators' IPs from the last 30 days, search engines, AI search services and the CDN's own addresses are never blocked there. Bunny CDN blocks single addresses only, so a blocked IPv6 network stays blocked by ScrapeLock itself. Turning the setting off or deactivating the plugin removes the blocks ScrapeLock made.

Can someone go around my CDN?

If they find your server's own address, yes: then nothing the CDN blocks applies. Since 3.2, "Only through the CDN" (Bots and limits → Real visitor IP) refuses every request that does not bring a secret your CDN adds as the header X-ScrapeLock-CDN (Bunny CDN: an Edge Rule "Set Request Header"; Cloudflare: a Transform Rule "Modify Request Header"). It can only be turned on from a request that brings the secret, so a missing rule cannot lock you out. If the CDN ever stops sending it, add define( 'SCRAPELOCK_CDN_ONLY', false ); to wp-config.php.

What is the early check?

An optional setting in "Bots and limits". ScrapeLock writes the small file wp-content/mu-plugins/scrapelock-early.php, which runs before the theme and the other plugins and stops blocked IPs and referrers, temporarily blocked IPs and User-Agents from the bot list, with less server load. Search engines, logged-in users, forms and private feeds are left to the normal check. The file is removed when you turn the setting off, deactivate or delete the plugin. If the server does not allow direct file writes, the setting shows a notice and everything else works as before.

Does it guarantee legal protection of my content?

No. The TDM declaration is a machine-readable reservation of rights; it does not guarantee legal compliance or stop anyone who ignores it.

What personal data does it store?

When a request is blocked, the IP address, User-Agent, page and time are logged. The log is deleted automatically after 1, 7 or 30 days. With the human check on, visitors who interact with the page get a security cookie, pncp_hv, for 7 days. It contains only an expiry time and a signature tied to their IP network and browser; it is not used for tracking or statistics. The country database is a local file: no visitor data is sent to DB-IP.

Can blocked bots still read robots.txt and llms.txt?

Yes. robots.txt, llms.txt and llms-full.txt are never blocked, for any bot, so every bot can read the rules it is asked to follow. The server rules in the "Server rules" tab keep them open too.

What does Lockdown freeze, and what keeps working?

While locked, users with a frozen role keep only "read": they can log in and open the dashboard, but cannot change anything. Roles that can change plugins, themes, users or settings are always frozen; editors, authors, contributors and shop managers are frozen by default, and you choose the rest on the Lockdown tab. Customers, subscribers and members (for example accounts that post listings through another plugin) are not affected, and neither are visitors, orders, payments, webhooks, cron jobs and comments. Shop staff cannot process orders in wp-admin while the site is locked: unlock it for a while to do so.

I lost my phone. How do I unlock the site?

Type one of your recovery codes in the unlock field instead of an app code. If you have none left, add define( 'SCRAPELOCK_UNLOCK', true ); to wp-config.php (FTP or your hosting panel), go to the Lockdown page, remove the app and connect a new one, then remove that line. The same works if you forget an administrator password while the site is locked, because password resets for staff are frozen too.

Can someone with access to my server bypass Lockdown?

Yes. Lockdown protects the site against changes through WordPress (wp-admin, the REST API, XML-RPC and code running inside WordPress). Someone who can only write to the database (for example through SQL injection in another plugin) cannot unlock it: the lock is signed with the keys in wp-config.php and copied into a must-use plugin file, changed protected settings are put back, and new administrators cannot sign in. Whoever can edit files on your server controls the site anyway, which is also why the server line is the last-resort unlock. The file integrity check is there for that case: a file written behind WordPress' back is found within the hour and emailed to you. Code that already runs on the server could also stop ScrapeLock itself, so "No PHP in the uploads folder" (a server rule) is what stops most backdoors from running in the first place.

Can I unlock Lockdown from WP-CLI or with an AI agent?

No, on purpose. Lockdown opens only with a code from your authenticator app, a recovery code, or the SCRAPELOCK_UNLOCK line in wp-config.php. The WP-CLI commands and the abilities can block IPs and start Emergency Mode; while the site is locked the abilities can only read the summary.

Does the human check show a captcha?

No. A small script waits for the first real interaction (scroll, tap, key or mouse movement), solves a light challenge in the background and receives the cookie. Visitors without it are not blocked: they get the stricter page limit you set (20 pages per minute by default). A determined scraper can repeat these steps, but every IP it uses has to do the work, and plain scripts never do.

更新日志:

3.4.2 3.4.1 Older versions The changes of 3.4.0 and earlier are in changelog.txt in the plugin folder.