From 532ff712aaceaae29a02f82e05529f0dd29c9f6b Mon Sep 17 00:00:00 2001 From: Steven Noonan Date: Sun, 1 Jan 2017 14:06:43 -0800 Subject: [PATCH] cipherscan: always define a curves_ordering column value Signed-off-by: Steven Noonan --- cipherscan | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/cipherscan b/cipherscan index 5f79abd..853db26 100755 --- a/cipherscan +++ b/cipherscan @@ -659,6 +659,7 @@ test_cipher_on_target() { else # resolve the openssl curve to the proper IANA name current_curves="$(get_curve_name "$(echo $pfs|cut -d ',' -f2)")" + curves_ordering="unknown" fi fi result="$cipher $protocols $pubkey $sigalg $trusted $tickethint $ocspstaple $npn $pfs $current_curves $curves_ordering" @@ -783,6 +784,8 @@ display_results_in_terminal() { npn="${cipher_data[7]}" if [[ $TEST_CURVES == "True" && -n ${cipher_data[10]} ]]; then curvesordering="${cipher_data[10]}" + else + curvesordering="unknown" fi else if [[ "$pubkey" != "${cipher_data[2]}" ]]; then @@ -803,11 +806,7 @@ display_results_in_terminal() { if [[ "$npn" != "${cipher_data[7]}" ]]; then different=True fi - if [[ -z $curvesordering && -n "${cipher_data[10]}" ]]; then - curvesordering="${cipher_data[10]}" - fi - if [[ -n $curvesordering && "$curvesordering" != "${cipher_data[10]}" ]]; then - echo "CURVESORDERING" + if [[ "$TEST_CURVES" == "True" && "$curvesordering" != "${cipher_data[10]}" ]]; then different=True fi fi