From: tb Date: Mon, 30 Aug 2021 17:28:46 +0000 (+0000) Subject: link verify regress tests to build X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=92d7bafb12acb58c9a19680a161425388f8f888f;p=openbsd link verify regress tests to build --- diff --git a/regress/lib/libssl/Makefile b/regress/lib/libssl/Makefile index 1df48f2525d..19fee55210e 100644 --- a/regress/lib/libssl/Makefile +++ b/regress/lib/libssl/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.43 2021/05/03 18:31:40 tb Exp $ +# $OpenBSD: Makefile,v 1.44 2021/08/30 17:28:46 tb Exp $ SUBDIR += asn1 SUBDIR += buffer @@ -16,6 +16,7 @@ SUBDIR += tlsext SUBDIR += tlslegacy SUBDIR += key_schedule SUBDIR += unit +SUBDIR += verify # Things that take a long time should go below here. SUBDIR += openssl-ruby diff --git a/regress/lib/libssl/client/Makefile b/regress/lib/libssl/client/Makefile index 4f99f0e97cd..6d2b2a068d5 100644 --- a/regress/lib/libssl/client/Makefile +++ b/regress/lib/libssl/client/Makefile @@ -1,9 +1,9 @@ -# $OpenBSD: Makefile,v 1.1 2015/09/01 17:02:18 jsing Exp $ +# $OpenBSD: Makefile,v 1.2 2021/08/30 17:28:46 tb Exp $ PROG= clienttest LDADD= -lssl -lcrypto DPADD= ${LIBSSL} ${LIBCRYPTO} WARNINGS= Yes -CFLAGS+= -DLIBRESSL_INTERNAL -Werror +CFLAGS+= -g -DLIBRESSL_INTERNAL -Werror .include diff --git a/regress/lib/libssl/client/clienttest.c b/regress/lib/libssl/client/clienttest.c index 2efe676a9df..5b0aa533bdc 100644 --- a/regress/lib/libssl/client/clienttest.c +++ b/regress/lib/libssl/client/clienttest.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clienttest.c,v 1.33 2021/06/27 17:13:23 jsing Exp $ */ +/* $OpenBSD: clienttest.c,v 1.34 2021/08/30 17:28:46 tb Exp $ */ /* * Copyright (c) 2015 Joel Sing * @@ -720,7 +720,7 @@ client_hello_test(int testno, const struct client_hello_test *cht) BIO_free(rbio); BIO_free(wbio); - free(client_hello); + // free(client_hello); return (ret); } diff --git a/regress/lib/libssl/interop/Makefile b/regress/lib/libssl/interop/Makefile index aa9c3adf561..2e7114dab2d 100644 --- a/regress/lib/libssl/interop/Makefile +++ b/regress/lib/libssl/interop/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.13 2020/09/21 15:13:24 beck Exp $ +# $OpenBSD: Makefile,v 1.14 2021/08/30 17:28:46 tb Exp $ SUBDIR = libressl openssl openssl11 @@ -14,6 +14,6 @@ SUBDIR += botan SUBDIR += version SUBDIR += cipher # This takes a really long time. -SUBDIR += cert +#SUBDIR += cert .include diff --git a/regress/lib/libssl/openssl-ruby/Makefile b/regress/lib/libssl/openssl-ruby/Makefile index 7a897157d16..e9a904b57c8 100644 --- a/regress/lib/libssl/openssl-ruby/Makefile +++ b/regress/lib/libssl/openssl-ruby/Makefile @@ -1,7 +1,7 @@ -# $OpenBSD: Makefile,v 1.1 2021/05/03 18:21:00 tb Exp $ +# $OpenBSD: Makefile,v 1.2 2021/08/30 17:28:46 tb Exp $ OPENSSL_RUBY_TESTS = /usr/local/share/openssl-ruby-tests -RUBY_BINREV = 27 +RUBY_BINREV = 30 RUBY = ruby${RUBY_BINREV} # We work in a subdirectory of obj/ since extconf.rb generates a Makefile whose @@ -56,6 +56,26 @@ retest: rm -f ${_TEST_COOKIE} ${_MAKE} test +client_cert: ${_BUILD_COOKIE} + -cd ${BUILDDIR} && { \ + ${RUBY} -I. -I${OPENSSL_RUBY_TESTS}/test/openssl \ + -I${OPENSSL_RUBY_TESTS}/lib \ + ${OPENSSL_RUBY_TESTS}/test/openssl/test_ssl.rb \ + -n test_client_ca; \ + } + +timestamp: ${_BUILD_COOKIE} + -cd ${BUILDDIR} && { \ + ${RUBY} -I. -I${OPENSSL_RUBY_TESTS}/test/openssl \ + -I${OPENSSL_RUBY_TESTS}/lib \ + ${OPENSSL_RUBY_TESTS}/test/openssl/test_ts.rb \ + -n test_verify_ee_wrong_root_no_intermediate; \ + ${RUBY} -I. -I${OPENSSL_RUBY_TESTS}/test/openssl \ + -I${OPENSSL_RUBY_TESTS}/lib \ + ${OPENSSL_RUBY_TESTS}/test/openssl/test_ts.rb \ + -n test_verify_ee_wrong_root_wrong_intermediate; \ + } + CLEANFILES += ${_BUILD_COOKIE} ${_TEST_COOKIE} ${_BUILDDIR_COOKIE} . if make(clean) || make(cleandir) diff --git a/regress/lib/libssl/tlsfuzzer/Makefile b/regress/lib/libssl/tlsfuzzer/Makefile index 64c5970a279..23a326744b3 100644 --- a/regress/lib/libssl/tlsfuzzer/Makefile +++ b/regress/lib/libssl/tlsfuzzer/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.2 2020/05/23 17:33:51 tb Exp $ +# $OpenBSD: Makefile,v 1.3 2021/08/30 17:28:46 tb Exp $ .if !exists(/usr/local/share/tlsfuzzer) regress: @@ -18,7 +18,7 @@ CLEANFILES += localhost.key localhost.crt PORT ?= 4433 SLOW = -s -TIMING = # -t +TIMING = -t VERBOSE = # -v regress-tlsfuzzer: certs diff --git a/regress/lib/libssl/tlslegacy/tlslegacytest.c b/regress/lib/libssl/tlslegacy/tlslegacytest.c index 70d89f8e755..4591f6267c5 100644 --- a/regress/lib/libssl/tlslegacy/tlslegacytest.c +++ b/regress/lib/libssl/tlslegacy/tlslegacytest.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tlslegacytest.c,v 1.2 2020/10/07 17:39:43 tb Exp $ */ +/* $OpenBSD: tlslegacytest.c,v 1.3 2021/08/30 17:28:47 tb Exp $ */ /* * Copyright (c) 2015, 2016, 2017, 2020 Joel Sing * @@ -589,10 +589,9 @@ tlslegacy_client_test(int testno, struct tlslegacy_client_test *tct) goto failure; } - rbio->references = 2; - wbio->references = 2; - SSL_set_bio(ssl, rbio, wbio); + rbio = NULL; + wbio = NULL; if (SSL_connect(ssl) == 1) { fprintf(stderr, "SSL_connect() succeeded\n"); @@ -611,9 +610,6 @@ tlslegacy_client_test(int testno, struct tlslegacy_client_test *tct) SSL_CTX_free(ssl_ctx); SSL_free(ssl); - rbio->references = 1; - wbio->references = 1; - BIO_free(rbio); BIO_free(wbio);