Description: Config is presumed to be in the same dir as the script, or in ./etc/
Author: Unit 193 <unit193@debian.org>
Origin: vendor
Forwarded: not-needed
Last-Update: 2019-10-01

---
 testssl.sh |   18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

--- a/testssl.sh	2020-11-22 19:45:43.298090552 -0500
+++ b/testssl.sh	2020-11-22 19:45:43.274090766 -0500
@@ -132,7 +132,7 @@
 declare -r SYSTEM="$(uname -s)"
 declare -r SYSTEMREV="$(uname -r)"
 SYSTEM2=""                                        # currently only being used for WSL = bash on windows
-TESTSSL_INSTALL_DIR="${TESTSSL_INSTALL_DIR:-""}"  # If you run testssl.sh and it doesn't find it necessary file automagically set TESTSSL_INSTALL_DIR
+TESTSSL_INSTALL_DIR="${TESTSSL_INSTALL_DIR:-"/etc/testssl"}"  # If you run testssl.sh and it doesn't find it necessary file automagically set TESTSSL_INSTALL_DIR
 CA_BUNDLES_PATH="${CA_BUNDLES_PATH:-""}"          # You can have your stores some place else
 ADDITIONAL_CA_FILES="${ADDITIONAL_CA_FILES:-""}"  # single file with a CA in PEM format or comma separated lists of them
 CIPHERS_BY_STRENGTH_FILE=""
@@ -2466,7 +2466,7 @@
      local -i i nrsaved
      local first_hpkp_header
      local spki
-     local ca_hashes="$TESTSSL_INSTALL_DIR/etc/ca_hashes.txt"
+     local ca_hashes="$TESTSSL_INSTALL_DIR/ca_hashes.txt"
 
      if [[ ! -s $HEADERFILE ]]; then
           run_http_header "$1" || return 1
@@ -4572,9 +4572,9 @@
      local client_service=""
 
      # source the external file
-     . "$TESTSSL_INSTALL_DIR/etc/client-simulation.txt" 2>/dev/null
+     . "$TESTSSL_INSTALL_DIR/client-simulation.txt" 2>/dev/null
      if [[ $? -ne 0 ]]; then
-          prln_local_problem "couldn't find client simulation data in $TESTSSL_INSTALL_DIR/etc/client-simulation.txt"
+          prln_local_problem "couldn't find client simulation data in $TESTSSL_INSTALL_DIR/client-simulation.txt"
           return 1
      fi
 
@@ -6956,7 +6956,7 @@
 
      # if you run testssl.sh from a different path /you can set either TESTSSL_INSTALL_DIR or CA_BUNDLES_PATH to find the CA BUNDLES
      if [[ -z "$CA_BUNDLES_PATH" ]]; then
-          ca_bundles="$TESTSSL_INSTALL_DIR/etc/*.pem"
+          ca_bundles="$TESTSSL_INSTALL_DIR/*.pem"
      else
           ca_bundles="$CA_BUNDLES_PATH/*.pem"
      fi
@@ -15171,7 +15171,7 @@
      local spaces="$3"
      local dh_p=""
      local -i subret=0
-     local common_primes_file="$TESTSSL_INSTALL_DIR/etc/common-primes.txt"
+     local common_primes_file="$TESTSSL_INSTALL_DIR/common-primes.txt"
      local -i lineno_matched=0
 
      "$HAS_PKEY" || return 2
@@ -16827,16 +16827,16 @@
           DISPLAY_CIPHERNAMES="openssl-only"
           debugme echo "$CIPHERS_BY_STRENGTH_FILE"
           prln_warning "\nATTENTION: No cipher mapping file found!"
-          outln "Please note from 2.9 on $PROG_NAME needs files in \"\$TESTSSL_INSTALL_DIR/etc/\" to function correctly."
+          outln "Please note from 2.9 on $PROG_NAME needs files in \"\$TESTSSL_INSTALL_DIR/\" to function correctly."
           outln
           ignore_no_or_lame "Type \"yes\" to ignore this warning and proceed at your own risk" "yes"
           [[ $? -ne 0 ]] && exit $ERR_RESOURCE
      fi
 
-     TLS_DATA_FILE="$TESTSSL_INSTALL_DIR/etc/tls_data.txt"
+     TLS_DATA_FILE="$TESTSSL_INSTALL_DIR/tls_data.txt"
      if [[ ! -r "$TLS_DATA_FILE" ]]; then
           prln_warning "\nATTENTION: No TLS data file found -- needed for socket-based handshakes"
-          outln "Please note from 2.9 on $PROG_NAME needs files in \"\$TESTSSL_INSTALL_DIR/etc/\" to function correctly."
+          outln "Please note from 2.9 on $PROG_NAME needs files in \"\$TESTSSL_INSTALL_DIR/\" to function correctly."
           outln
           ignore_no_or_lame "Type \"yes\" to ignore this warning and proceed at your own risk" "yes"
           [[ $? -ne 0 ]] && exit $ERR_RESOURCE
