@@ -122,11 +122,11 @@ start_test "Start with minimal settings" "${STD_CMD} \
122122 -e \" PROXY_SERVICE_PORT=443\" "
123123
124124echo " Test it's up and working..."
125- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /
125+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /
126126echo " Test limited protcol and SSL cipher... "
127- docker run --link ${INSTANCE} :${INSTANCE} --rm --entrypoint bash ngx -c " echo GET / | /usr/bin/openssl s_client -cipher 'AES256+EECDH' -tls1_2 -connect ${INSTANCE} :10443" & > /dev/null;
127+ docker run --link ${INSTANCE} :${INSTANCE} --rm --entrypoint bash ngx -c " echo GET / | /usr/bin/openssl s_client -cipher 'AES256+EECDH' -tls1_2 -connect ${INSTANCE} :10443" & > /dev/null;
128128echo " Test sslv2 not accepted...."
129- if docker run --link ${INSTANCE} :${INSTANCE} --rm --entrypoint bash ngx -c " echo GET / | /usr/bin/openssl s_client -ssl2 -connect ${INSTANCE} :10443" & > /dev/null; then
129+ if docker run --link ${INSTANCE} :${INSTANCE} --rm --entrypoint bash ngx -c " echo GET / | /usr/bin/openssl s_client -ssl2 -connect ${INSTANCE} :10443" & > /dev/null; then
130130 echo " FAIL SSL defaults settings allow ssl2 ......"
131131 exit 2
132132fi
@@ -151,7 +151,7 @@ start_test "Test GEODB settings can reject..." "${STD_CMD} \
151151 -e \" ADD_NGINX_LOCATION_CFG=error_page 403 /nginx-proxy/50x.shtml;\" \
152152 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
153153echo " Test GeoIP config IS rejected..."
154- if ! curl -v -k -H " X-Forwarded-For: 1.1.1.1 " https://${DOCKER_HOST_NAME} :${PORT} / 2>&1 \/ | grep ' 403 Forbidden' ; then
154+ if ! curl -v -k -H " X-Forwarded-For: 8.8.8.8 " https://${DOCKER_HOST_NAME} :${PORT} / 2>&1 \/ | grep ' 403 Forbidden' ; then
155155 echo " We were expecting to be rejected with 403 error here - we are not in the Congo!"
156156 exit 2
157157else
@@ -224,8 +224,7 @@ start_test "Start we auto add a protocol " "${STD_CMD} \
224224 -e \" PROXY_SERVICE_PORT=80\" "
225225
226226echo " Test it works if we do not define the protocol.."
227- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /
228-
227+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /
229228
230229start_test " Start with multi locations settings" " ${STD_CMD} \
231230 -e \" LOCATIONS_CSV=/,/wiki/Wikipedia:About\" \
@@ -236,9 +235,9 @@ start_test "Start with multi locations settings" "${STD_CMD} \
236235
237236
238237echo " Test for location 1 @ /..."
239- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /
238+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /
240239echo " Test for wikipedia about page..."
241- wget -O /dev/null --quiet --no-check-certificate --header= " Host: en.wikipedia.org" https://${DOCKER_HOST_NAME} :${PORT} /wiki/Wikipedia:About
240+ curl -sk -o /dev/null -H " Host: en.wikipedia.org" https://${DOCKER_HOST_NAME} :${PORT} /wiki/Wikipedia:About
242241
243242start_test " Start with Multiple locations, single proxy and NAXSI download." " ${STD_CMD} \
244243 -e \" PROXY_SERVICE_HOST=https://en.wikipedia.org\" \
@@ -248,7 +247,7 @@ start_test "Start with Multiple locations, single proxy and NAXSI download." "${
248247 -e \" NAXSI_RULES_MD5_CSV_1=3b3c24ed61683ab33d8441857c315432\" "
249248
250249echo " Test for all OK..."
251- wget -O /dev/null --quiet --no-check-certificate --header= " Host: en.wikipedia.org" https://${DOCKER_HOST_NAME} :${PORT} /
250+ curl -sk -o /dev/null -H " Host: en.wikipedia.org" https://${DOCKER_HOST_NAME} :${PORT} /
252251
253252echo " Test client certs..."
254253cd ./client_certs/
@@ -265,19 +264,20 @@ start_test "Start with Client CA, and single proxy. Block unauth for /standards"
265264 -e \" CLIENT_CERT_REQUIRED_2=TRUE\" "
266265
267266echo " Test access OK for basic area..."
268- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /
267+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /
269268
270269echo " Test access denied for /standards/..."
271- if wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /standards/ ; then
270+ if curl -sk -o /dev/null --fail https://${DOCKER_HOST_NAME} :${PORT} /standards/ ; then
272271 echo " Error - expecting auth fail!"
273272 exit 1
274273else
275274 echo " Passed auth fail"
276275fi
277276echo " Test access OK for /standards/... with client cert..."
278- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /standards/ \
279- --certificate=./client_certs/client.crt \
280- --private-key=./client_certs/client.key
277+ curl -sk -o /dev/null \
278+ --cert ./client_certs/client.crt \
279+ --key ./client_certs/client.key \
280+ https://${DOCKER_HOST_NAME} :${PORT} /standards/
281281
282282echo " Test upstream client certs..."
283283docker build -t mutual-tls:latest ${WORKDIR} -f docker-config/Dockerfile.mutual-tls
@@ -301,7 +301,7 @@ start_test "Start with upstream client certs" \
301301 --link \" ${MUTUAL_TLS} :${MUTUAL_TLS} \" "
302302
303303echo " Test it's up and working..."
304- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /
304+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /
305305tear_down_container " ${MUTUAL_TLS} "
306306
307307echo " Test failure to verify upstream server cert..."
@@ -365,8 +365,8 @@ start_test "Start with Custom error pages redirect off" "${STD_CMD} \
365365 -e \" ENABLE_UUID_PARAM=FALSE\" \
366366 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
367367echo " Test All ok..."
368- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /
369- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /api/
368+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /
369+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /api/
370370if curl -v -k https://${DOCKER_HOST_NAME} :${PORT} /api/dead | grep " Oh dear" ; then
371371 echo " Passed return text on error with ERROR_REDIRECT_CODES"
372372else
@@ -431,7 +431,7 @@ start_test "Start with listen for port 80" "${STD_CMD} \
431431 -e \" HTTPS_REDIRECT_PORT=${PORT} \" \
432432 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
433433echo " Test Redirect ok..."
434- wget -O /dev/null --quiet --no-check-certificate http://${DOCKER_HOST_NAME} :8888/
434+ curl -s -o /dev/null http://${DOCKER_HOST_NAME} :8888/
435435
436436
437437start_test " Test text logging format..." " ${STD_CMD} \
@@ -442,7 +442,7 @@ start_test "Test text logging format..." "${STD_CMD} \
442442 -e \" ENABLE_UUID_PARAM=FALSE\" \
443443 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
444444echo " Test request (with logging as text)..."
445- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /
445+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /
446446echo " Testing text logs format..."
447447docker logs ${INSTANCE} | grep " \" GET / HTTP/1.1\" 200"
448448
@@ -453,7 +453,7 @@ start_test "Test json logging format..." "${STD_CMD} \
453453 -e \" LOG_FORMAT_NAME=json\" \
454454 -e \" ENABLE_UUID_PARAM=FALSE\" \
455455 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
456- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} ? animal=cow
456+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} ? animal=cow
457457echo " Testing json logs format..."
458458docker logs ${INSTANCE} | grep ' {"proxy_proto_address":'
459459docker logs ${INSTANCE} | grep ' animal=cow'
@@ -467,7 +467,7 @@ start_test "Test param logging off option works..." "${STD_CMD} \
467467 -e \" ENABLE_UUID_PARAM=FALSE\" \
468468 -e \" NO_LOGGING_URL_PARAMS=TRUE\" \
469469 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
470- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} ? animal=cow
470+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} ? animal=cow
471471echo " Testing no logging of url params option works..."
472472docker logs ${INSTANCE} 2> /dev/null | grep ' {"proxy_proto_address":'
473473docker logs ${INSTANCE} 2> /dev/null | grep ' animal=cow' | wc -l | grep 0
@@ -479,7 +479,7 @@ start_test "Test ENABLE_WEB_SOCKETS..." "${STD_CMD} \
479479 -e \" ENABLE_WEB_SOCKETS=TRUE\" \
480480 -e \" ENABLE_UUID_PARAM=FALSE\" \
481481 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
482- wget -O /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /
482+ curl -sk -o /dev/null https://${DOCKER_HOST_NAME} :${PORT} /
483483
484484start_test " Test ADD_NGINX_LOCATION_CFG param..." " ${STD_CMD} \
485485 -e \" PROXY_SERVICE_HOST=http://${MOCKSERVER} \" \
@@ -490,7 +490,7 @@ start_test "Test ADD_NGINX_LOCATION_CFG param..." "${STD_CMD} \
490490 -e \" ENABLE_UUID_PARAM=FALSE\" \
491491 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
492492echo " Test extra param works"
493- wget -O - -o /dev/null --quiet --no-check-certificate https://${DOCKER_HOST_NAME} :${PORT} /wow | grep " NICE"
493+ curl -sk https://${DOCKER_HOST_NAME} :${PORT} /wow | grep " NICE"
494494
495495
496496start_test " Test UUID GET param logging option works..." " ${STD_CMD} \
@@ -523,7 +523,7 @@ start_test "Test UUID header logging option works..." "${STD_CMD} \
523523 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
524524curl -sk https://${DOCKER_HOST_NAME} :${PORT}
525525echo " Testing no logging of url params option works..."
526- docker logs " ${MOCKSERVER} " | grep ' Nginxid: '
526+ docker logs " ${MOCKSERVER} " | grep ' nginxid-> '
527527docker logs ${INSTANCE} | grep ' "nginx_uuid": "'
528528
529529start_test " Test UUID header logging option passes through supplied value..." " ${STD_CMD} \
@@ -534,7 +534,7 @@ start_test "Test UUID header logging option passes through supplied value..." "$
534534 --link \" ${MOCKSERVER} :${MOCKSERVER} \" "
535535curl -sk -H " nginxId: 00000000-1111-2222-3333-444455556666" https://${DOCKER_HOST_NAME} :${PORT}
536536echo " Testing no logging of url params option works..."
537- docker logs " ${MOCKSERVER} " | grep ' Nginxid: 00000000-1111-2222-3333-444455556666'
537+ docker logs " ${MOCKSERVER} " | grep ' nginxid-> 00000000-1111-2222-3333-444455556666'
538538docker logs ${INSTANCE} | grep ' "nginx_uuid": "00000000-1111-2222-3333-444455556666"'
539539
540540start_test " Test VERBOSE_ERROR_PAGES=TRUE displays debug info" " ${STD_CMD} \
0 commit comments