From 6e6f2cededf79e299b1c92558906118687455664 Mon Sep 17 00:00:00 2001 From: Mitchell Krog Date: Fri, 26 Jul 2019 09:06:40 +0200 Subject: [PATCH] [BETA] Adjust Rate Limiting Values and Test --- .dev-tools/beta-test-blocker-rate-limiting.sh | 65 +++++++++++++++++++ .dev-tools/globalblacklist-testing.template | 4 +- 2 files changed, 68 insertions(+), 1 deletion(-) diff --git a/.dev-tools/beta-test-blocker-rate-limiting.sh b/.dev-tools/beta-test-blocker-rate-limiting.sh index 9c171b83c..6117bdeb5 100755 --- a/.dev-tools/beta-test-blocker-rate-limiting.sh +++ b/.dev-tools/beta-test-blocker-rate-limiting.sh @@ -100,6 +100,71 @@ curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & +curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} & curl -A "GoogleBot" http://localhost:9000 2>&1 >> ${ratelimittestfile} if grep -i 'Unavailable' < ${ratelimittestfile}; then diff --git a/.dev-tools/globalblacklist-testing.template b/.dev-tools/globalblacklist-testing.template index dce816a14..89021082c 100644 --- a/.dev-tools/globalblacklist-testing.template +++ b/.dev-tools/globalblacklist-testing.template @@ -17993,8 +17993,10 @@ geo $ratelimited { # BAD BOT RATE LIMITING ZONE # Rate limiting will only take effect if on any User-Agents with a value of 2 + #limit_conn_zone $bot_iplimit zone=bot2_connlimit:16m; + #limit_req_zone $bot_iplimit zone=bot2_reqlimitip:16m rate=30r/m; limit_conn_zone $bot_iplimit zone=bot2_connlimit:16m; - limit_req_zone $bot_iplimit zone=bot2_reqlimitip:16m rate=30r/m; + limit_req_zone $bot_iplimit zone=bot2_reqlimitip:16m rate=2r/s; # ========================================== # END SECTION 4 - ACTIVATE BLOCKER FUNCTIONS