diff --git a/testssl.sh b/testssl.sh index e682815..7f1fe77 100755 --- a/testssl.sh +++ b/testssl.sh @@ -4083,14 +4083,16 @@ ciphers_by_strength() { fi else # no SSLv2 nr_ossl_ciphers=0 - for (( i=0; i < nr_ciphers; i++ )); do - if "${ossl_supported[i]}"; then - ciphers_found2[nr_ossl_ciphers]=false - ciph2[nr_ossl_ciphers]="${ciph[i]}" - index[nr_ossl_ciphers]=$i - nr_ossl_ciphers+=1 - fi - done + if ( "$HAS_SSL3" || [[ $proto != -ssl3 ]] ) && ( "$HAS_TLS13" || [[ $proto != -tls1_3 ]] ); then + for (( i=0; i < nr_ciphers; i++ )); do + if "${ossl_supported[i]}"; then + ciphers_found2[nr_ossl_ciphers]=false + ciph2[nr_ossl_ciphers]="${ciph[i]}" + index[nr_ossl_ciphers]=$i + nr_ossl_ciphers+=1 + fi + done + fi if [[ $nr_ossl_ciphers -eq 0 ]]; then num_bundles=0 else @@ -14785,6 +14787,7 @@ run_tls_fallback_scsv() { high_proto="$p" break fi + [[ "$p" == ssl3 ]] && ! "$HAS_SSL3" && continue $OPENSSL s_client $(s_client_options "-$p $STARTTLS $BUGS -connect $NODEIP:$PORT $PROXY $SNI") >$TMPFILE 2>$ERRFILE $TMPFILE 2>$ERRFILE