"Fossies" - the Fresh Open Source Software Archive

Member "hitch-1.5.2/src/tests/test30-tls-protos-tls1_3.sh" (27 Aug 2019, 439 Bytes) of package /linux/www/hitch-1.5.2.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Bash source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 #!/bin/sh
    2 # Test TLS 1.3 availability.
    3 
    4 . hitch_test.sh
    5 
    6 if ! openssl s_client -help 2>&1 | grep -q -e "-tls1_3";
    7 then
    8     skip "Missing TLSv1.3 support"
    9 fi
   10 
   11 # only TLSv1.3
   12 cat >hitch.cfg <<EOF
   13 backend = "[hitch-tls.org]:80"
   14 frontend = "[*]:$LISTENPORT"
   15 pem-file = "${CERTSDIR}/default.example.com"
   16 tls-protos = TLSv1.3
   17 EOF
   18 
   19 start_hitch --config=hitch.cfg
   20 
   21 # this will fail on platforms that have OpenSSL without TLS 1.3.
   22 s_client -tls1_3