From d90be7f2fe5fa503a44da7bafba5ee955e87ffe8 Mon Sep 17 00:00:00 2001 From: Mitchell Krog Date: Mon, 24 Jun 2019 16:54:54 +0200 Subject: [PATCH] Debug testing of whitelist-domains.conf --- .dev-tools/test-blocker-whitelist-domains.sh | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.dev-tools/test-blocker-whitelist-domains.sh b/.dev-tools/test-blocker-whitelist-domains.sh index 06acb20fc..f50b76dd7 100755 --- a/.dev-tools/test-blocker-whitelist-domains.sh +++ b/.dev-tools/test-blocker-whitelist-domains.sh @@ -58,24 +58,26 @@ sleep 30s # ************************************************* run_curltest1 () { -if curl -I http://localhost:9000 -e http://www.myowndomain.com 2>&1 | grep -i 'Welcome'; then +if curl -I http://localhost:9000 -e http://myowndomain.com 2>&1 | grep -i 'Welcome'; then echo "${bold}${green}PASSED - User whitelist-domains.conf working" else echo "${bold}${red}FAILED - User whitelist-domains.conf NOT working" + curl -I http://localhost:9000 -e http://myowndomain.com 2>&1 #exit 1 fi } run_curltest1 -# ************************************************************** -# Function Curl Test 2 - Check for Whitelisted Referrer "zx6.ru" -# ************************************************************** +# ************************************************* +# Function Curl Test 2 - Test User Domain Whitelist +# ************************************************* run_curltest2 () { if curl -I http://localhost:9000 -e http://www.myotherdomain.com 2>&1 | grep -i 'Welcome'; then echo "${bold}${green}PASSED - User whitelist-domains.conf working" else echo "${bold}${red}FAILED - User whitelist-domains.conf NOT working" + curl -I http://localhost:9000 -e http://www.myotherdomain.com 2>&1 #exit 1 fi }