1#!/bin/sh 2 3. hitch_test.sh 4 5BACKENDPORT=$(expr $LISTENPORT + 1600) 6 7parse_proxy_v2 $BACKENDPORT >proxy.dump & 8 9cat >hitch.cfg <<EOF 10backend = "[127.0.0.1]:$BACKENDPORT" 11frontend = "[*]:$LISTENPORT" 12pem-file = "${CERTSDIR}/default.example.com" 13tls-protos = TLSv1.2 14ciphers = "ECDHE-RSA-AES256-GCM-SHA384" 15write-proxy = on 16EOF 17 18start_hitch --config=hitch.cfg 19 20sleep 0.1 21 22s_client -tls1_2 -cipher ECDHE-RSA-AES256-GCM-SHA384 >s_client.dump 23 24! grep ERROR proxy.dump 25cat proxy.dump 26run_cmd grep -q ECDHE-RSA-AES256-GCM-SHA384 proxy.dump 27run_cmd grep -q TLSv1.2 proxy.dump 28