From 68580264123aaae8f212c996e65a78abf6343317 Mon Sep 17 00:00:00 2001 From: John Carver Date: Thu, 18 Feb 2016 11:15:31 -0600 Subject: [PATCH 1/3] uppercase INFO when outputting status_code --- testssl.sh | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/testssl.sh b/testssl.sh index 74de473..6e4f4ba 100755 --- a/testssl.sh +++ b/testssl.sh @@ -724,44 +724,44 @@ run_http_header() { pr_litered " -- Redirect to insecure URL (NOT ok)" fileout "status_code" "NOT OK" \, "Redirect to insecure URL (NOT ok). Url: \"$redirect\"" fi - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter, redirecting to \"$redirect\"" ;; 200) - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter" ;; 206) out " -- WTF?" - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter -- WTF?" ;; 400) pr_litemagenta " (Hint: better try another URL)" - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter (Hint: better try another URL)" ;; 401) grep -aq "^WWW-Authenticate" $HEADERFILE && out " "; strip_lf "$(grep -a "^WWW-Authenticate" $HEADERFILE)" - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter $(grep -a "^WWW-Authenticate" $HEADERFILE)" ;; 403) - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter" ;; 404) out " (Hint: supply a path which doesn't give a \"$status_code$msg_thereafter\")" - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter (Hint: supply a path which doesn't give a \"$status_code$msg_thereafter\")" ;; 405) - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter" ;; *) pr_litemagenta ". Oh, didn't expect a $status_code$msg_thereafter" - fileout "status_code" "info" \ + fileout "status_code" "INFO" \ "Testing HTTP header response @ \"$URL_PATH\", $status_code$msg_thereafter. Oh, didn't expect a $status_code$msg_thereafter" ;; esac From 291edce0c3f8d12650a4ae85a253dac19c14e25d Mon Sep 17 00:00:00 2001 From: John Carver Date: Thu, 18 Feb 2016 11:41:17 -0600 Subject: [PATCH 2/3] uppercase server sets a cipher order (OK) --- testssl.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testssl.sh b/testssl.sh index 6e4f4ba..cb0d44e 100755 --- a/testssl.sh +++ b/testssl.sh @@ -2406,7 +2406,7 @@ run_server_preference() { else pr_green "yes (OK)" remark4default_cipher="" - fileout "order" "OK" "Server sets a cipher order (ok)" + fileout "order" "OK" "Server sets a cipher order (OK)" fi [[ $DEBUG -ge 2 ]] && out " $cipher1 | $cipher2" outln From 4be1539a4d8d0cb245f72079aff5163fde5b3bd4 Mon Sep 17 00:00:00 2001 From: John Carver Date: Thu, 18 Feb 2016 11:49:47 -0600 Subject: [PATCH 3/3] lowercase ok when used with NOT in (NOT ok) --- testssl.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/testssl.sh b/testssl.sh index cb0d44e..97e4366 100755 --- a/testssl.sh +++ b/testssl.sh @@ -1356,13 +1356,13 @@ std_cipherlists() { fileout "std_$4" "OK" "$2 offered (OK)" else pr_brownln "not offered (NOT ok)" - fileout "std_$4" "NOT OK" "$2 not offered (NOT OK)" + fileout "std_$4" "NOT OK" "$2 not offered (NOT ok)" fi ;; 1) # the ugly ones if [[ $sclient_success -eq 0 ]]; then pr_redln "offered (NOT ok)" - fileout "std_$4" "NOT OK" "$2 offered (NOT OK) - ugly" + fileout "std_$4" "NOT OK" "$2 offered (NOT ok) - ugly" else pr_greenln "not offered (OK)" fileout "std_$4" "OK" "$2 not offered (OK)" @@ -1371,7 +1371,7 @@ std_cipherlists() { 2) # bad but not worst if [[ $sclient_success -eq 0 ]]; then pr_literedln "offered (NOT ok)" - fileout "std_$4" "NOT OK" "$2 offered (NOT OK) - bad" + fileout "std_$4" "NOT OK" "$2 offered (NOT ok) - bad" else pr_litegreenln "not offered (OK)" fileout "std_$4" "OK" "$2 not offered (OK)" @@ -1380,7 +1380,7 @@ std_cipherlists() { 3) # not totally bad if [[ $sclient_success -eq 0 ]]; then pr_brownln "offered (NOT ok)" - fileout "std_$4" "NOT OK" "$2 offered (NOT OK) - not too bad" + fileout "std_$4" "NOT OK" "$2 offered (NOT ok) - not too bad" else outln "not offered (OK)" fileout "std_$4" "OK" "$2 not offered (OK)"