From 76dd8caeb0045d466bdfcdbf30513ab1ec636c24 Mon Sep 17 00:00:00 2001 From: Mitchell Krog Date: Tue, 8 Oct 2019 14:28:14 +0200 Subject: [PATCH] Update README / Cloudflare - Closes: #318 --- README.md | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 129831d1f..5f06c367a 100755 --- a/README.md +++ b/README.md @@ -372,22 +372,27 @@ The Nginx Ultimate Bot Blocker is now WORKING and PROTECTING your web sites !!! ### NOTE to Cloudflare Users !!! -If you are a Cloudflare user who is using the Cloudflare CDN / Cacheing System you will see the following behavior when testing. +If you are a Cloudflare user who is using the Cloudflare CDN / Caching System you should always disable the Cloudflare CDN (set gray Cloud) -The First test of a Bad User Agent will give you: +While testing you will get the correct response codes results as below: +- curl: (52) Empty reply from server - curl: (56) TCP connection reset by peer - -The Second test will give you: -- curl: 520 Origin Error +- curl: (92) HTTP/2 stream 0 was not closed cleanly: PROTOCOL_ERROR (err 1) This is by design. The CDN is doing its work, meaning, the first response from your server said to the bot, "go away" by issuing it `444` or `443` responses. -Cloudflare cache's that response and hence the second test gets served a `520 Origin Error` origin error message. +Cloudflare cache's that response and hence the second time you test you will get served a `520 Origin Error` origin error message. While testing the blocker, disable the CDN / cacheing system and once you are happy with your tests, re-enable the CDN/Cache on your live environment as you do want the bots to get that response from Cloudflare. Most other CDN systems will probably show the same behavior so always disable a CDN during testing to rule out anything that will interfere with your testing. Always make sure to re-enable the CDN when done testing !! +Once you Enable Cloudflare CDN, test again. + +While testing, you get +- curl: 520 Origin Error +Means the CDN is working and gives Error. + ************************************************