Blame SOURCES/Bug-1001841-disable-sslv2-tests.patch

74fc46
diff -up nss/tests/ssl/ssl.sh.disableSSL2tests nss/tests/ssl/ssl.sh
294c78
--- nss/tests/ssl/ssl.sh.disableSSL2tests	2018-03-05 16:58:32.000000000 +0100
294c78
+++ nss/tests/ssl/ssl.sh	2018-03-09 17:24:07.047568191 +0100
294c78
@@ -68,9 +68,14 @@ ssl_init()
294c78
   NSS_SSL_RUN=${NSS_SSL_RUN:-$nss_ssl_run}
294c78
   
74fc46
   # Test case files
294c78
-  SSLCOV=${QADIR}/ssl/sslcov.txt
74fc46
+  if [ "${NSS_NO_SSL2}" = "1" ]; then
74fc46
+    SSLCOV=${QADIR}/ssl/sslcov.noSSL2orExport.txt
74fc46
+    SSLSTRESS=${QADIR}/ssl/sslstress.noSSL2orExport.txt
74fc46
+  else
74fc46
+    SSLCOV=${QADIR}/ssl/sslcov.txt
74fc46
+    SSLSTRESS=${QADIR}/ssl/sslstress.txt
74fc46
+  fi
74fc46
   SSLAUTH=${QADIR}/ssl/sslauth.txt
74fc46
-  SSLSTRESS=${QADIR}/ssl/sslstress.txt
74fc46
   SSLPOLICY=${QADIR}/ssl/sslpolicy.txt
74fc46
   REQUEST_FILE=${QADIR}/ssl/sslreq.dat
74fc46
 
294c78
@@ -128,7 +133,11 @@ is_selfserv_alive()
74fc46
   fi
74fc46
 
74fc46
   echo "kill -0 ${PID} >/dev/null 2>/dev/null"
74fc46
+  if [ "${NSS_NO_SSL2}" = "1" ] && [[ ${EXP} -eq 0 || ${SSL2} -eq 0 ]]; then
74fc46
+  echo "No server to kill"
74fc46
+  else
74fc46
   kill -0 ${PID} >/dev/null 2>/dev/null || Exit 10 "Fatal - selfserv process not detectable"
74fc46
+  fi
74fc46
 
74fc46
   echo "selfserv with PID ${PID} found at `date`"
74fc46
 }
294c78
@@ -152,7 +161,11 @@ wait_for_selfserv()
74fc46
       ${BINDIR}/tstclnt -4 -p ${PORT} -h ${HOSTADDR} ${CLIENT_OPTIONS} -q \
74fc46
               -d ${P_R_CLIENTDIR} $verbose < ${REQUEST_FILE}
74fc46
       if [ $? -ne 0 ]; then
74fc46
+          if [ "${NSS_NO_SSL2}" = "1" ] && [[ ${EXP} -eq 0 || ${SSL2} -eq 0 ]]; then
74fc46
+              html_passed "Server never started"
74fc46
+          else
74fc46
           html_failed "Waiting for Server"
74fc46
+          fi
74fc46
       fi
74fc46
   fi
74fc46
   is_selfserv_alive
294c78
@@ -275,7 +288,7 @@ ssl_cov()
74fc46
   start_selfserv # Launch the server
74fc46
 
74fc46
   VMIN="ssl3"
74fc46
-  VMAX="tls1.1"
74fc46
+  VMAX="tls1.2"
74fc46
 
74fc46
   ignore_blank_lines ${SSLCOV} | \
74fc46
   while read ectype testmax param testname
294c78
@@ -283,6 +296,12 @@ ssl_cov()
74fc46
       echo "${testname}" | grep "EXPORT" > /dev/null
74fc46
       EXP=$?
74fc46
 
74fc46
+      #  skip export tests
74fc46
+      if [ ${EXP} -eq 0 ]; then
74fc46
+         echo "export test skipped"
74fc46
+         continue
74fc46
+      fi
74fc46
+
74fc46
       if [ "$ectype" = "ECC" ] ; then
74fc46
           echo "$SCRIPTNAME: skipping  $testname (ECC only)"
74fc46
       else