summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDmitry Eremin-Solenikov <dbaryshkov@gmail.com>2018-07-19 15:40:46 +0300
committerDmitry Eremin-Solenikov <dbaryshkov@gmail.com>2019-12-20 01:46:00 +0300
commit2a6e87081ab811812f51ead52c4eef29baa6ba43 (patch)
treec114e9cf2f194e4c2af68f71ac9bd674c382d1d0 /tests
parent8d81203c987e717031a6ecfa0a25983f4471d3fc (diff)
downloadgnutls-2a6e87081ab811812f51ead52c4eef29baa6ba43.tar.gz
gnutls-cli-debug: add GOST_CNT-related KX/cipher/MAC tests
Add test for VKO-GOST-12, GOST28147-TC26Z-CNT and GOST28147-TC26Z-IMIT support by the server. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Diffstat (limited to 'tests')
-rwxr-xr-xtests/gnutls-cli-debug.sh26
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/gnutls-cli-debug.sh b/tests/gnutls-cli-debug.sh
index 1f047e870c..51f77bb565 100755
--- a/tests/gnutls-cli-debug.sh
+++ b/tests/gnutls-cli-debug.sh
@@ -56,6 +56,8 @@ KEY2=${srcdir}/../doc/credentials/x509/key-ecc.pem
CERT2=${srcdir}/../doc/credentials/x509/cert-ecc.pem
KEY3=${srcdir}/../doc/credentials/x509/key-rsa-pss.pem
CERT3=${srcdir}/../doc/credentials/x509/cert-rsa-pss.pem
+KEY4=${srcdir}/../doc/credentials/x509/key-gost12.pem
+CERT4=${srcdir}/../doc/credentials/x509/cert-gost12.pem
CAFILE=${srcdir}/../doc/credentials/x509/ca.pem
TMPFILE=outcert.$$.tmp
@@ -169,4 +171,28 @@ check_text "for RSA key exchange support... no"
rm -f ${OUTFILE}
+if test "${ENABLE_GOST}" = "1" && test "${GNUTLS_FORCE_FIPS_MODE}" != 1 ; then
+ # GOST_CNT test
+ echo ""
+ echo "Checking output of gnutls-cli-debug for GOST-enabled server"
+
+ eval "${GETPORT}"
+ launch_server $$ --echo --priority "NORMAL" --x509keyfile ${KEY4} --x509certfile ${CERT4} >/dev/null 2>&1
+ PID=$!
+ wait_server ${PID}
+
+ timeout 1800 datefudge "2017-08-9" \
+ "${DCLI}" -p "${PORT}" localhost >$OUTFILE 2>&1 || fail ${PID} "gnutls-cli-debug run should have succeeded!"
+
+ kill ${PID}
+ wait
+
+ check_text "for VKO GOST-2012 (draft-smyshlyaev-tls12-gost-suites) support... yes"
+ check_text "for GOST28147-CNT cipher (draft-smyshlyaev-tls12-gost-suites) support... yes"
+ check_text "for GOST28147-IMIT MAC (draft-smyshlyaev-tls12-gost-suites) support... yes"
+
+ rm -f ${OUTFILE}
+
+fi
+
exit 0