diff --git a/test/oqs_test_groups.c b/test/oqs_test_groups.c index ba7fd4d8..09ca5ff0 100644 --- a/test/oqs_test_groups.c +++ b/test/oqs_test_groups.c @@ -42,7 +42,8 @@ static int test_oqs_groups(const char *group_name, int dtls_flag) { printf("Not testing disabled algorithm %s.\n", group_name); return 1; } - testresult = create_tls1_3_ctx_pair(libctx, &sctx, &cctx, cert, privkey, dtls_flag); + testresult = + create_tls1_3_ctx_pair(libctx, &sctx, &cctx, cert, privkey, dtls_flag); if (!testresult) { ret = -1; goto err; diff --git a/test/oqs_test_tlssig.c b/test/oqs_test_tlssig.c index 7dc4fd38..237ea429 100644 --- a/test/oqs_test_tlssig.c +++ b/test/oqs_test_tlssig.c @@ -53,8 +53,8 @@ static int test_oqs_tlssig(const char *sig_name, int dtls_flag) { goto err; } - testresult = - create_tls1_3_ctx_pair(libctx, &sctx, &cctx, certpath, privkeypath, dtls_flag); + testresult = create_tls1_3_ctx_pair(libctx, &sctx, &cctx, certpath, + privkeypath, dtls_flag); if (!testresult) { ret = -1; diff --git a/test/tlstest_helpers.c b/test/tlstest_helpers.c index 50d28877..0e9176a8 100644 --- a/test/tlstest_helpers.c +++ b/test/tlstest_helpers.c @@ -52,8 +52,7 @@ int create_tls1_3_ctx_pair(OSSL_LIB_CTX *libctx, SSL_CTX **sctx, SSL_CTX **cctx, if (dtls_flag) { serverctx = SSL_CTX_new_ex(libctx, NULL, DTLS_server_method()); clientctx = SSL_CTX_new_ex(libctx, NULL, DTLS_client_method()); - } - else { + } else { serverctx = SSL_CTX_new_ex(libctx, NULL, TLS_server_method()); clientctx = SSL_CTX_new_ex(libctx, NULL, TLS_client_method()); } @@ -63,17 +62,16 @@ int create_tls1_3_ctx_pair(OSSL_LIB_CTX *libctx, SSL_CTX **sctx, SSL_CTX **cctx, SSL_CTX_set_options(serverctx, SSL_OP_ALLOW_CLIENT_RENEGOTIATION); if (dtls_flag) { - if (!SSL_CTX_set_min_proto_version(serverctx, DTLS1_3_VERSION) - || !SSL_CTX_set_max_proto_version(serverctx, DTLS1_3_VERSION) - || !SSL_CTX_set_min_proto_version(clientctx, DTLS1_3_VERSION) - || !SSL_CTX_set_max_proto_version(clientctx, DTLS1_3_VERSION)) + if (!SSL_CTX_set_min_proto_version(serverctx, DTLS1_3_VERSION) || + !SSL_CTX_set_max_proto_version(serverctx, DTLS1_3_VERSION) || + !SSL_CTX_set_min_proto_version(clientctx, DTLS1_3_VERSION) || + !SSL_CTX_set_max_proto_version(clientctx, DTLS1_3_VERSION)) goto err; - } - else { - if (!SSL_CTX_set_min_proto_version(serverctx, TLS1_3_VERSION) - || !SSL_CTX_set_max_proto_version(serverctx, TLS1_3_VERSION) - || !SSL_CTX_set_min_proto_version(clientctx, TLS1_3_VERSION) - || !SSL_CTX_set_max_proto_version(clientctx, TLS1_3_VERSION)) + } else { + if (!SSL_CTX_set_min_proto_version(serverctx, TLS1_3_VERSION) || + !SSL_CTX_set_max_proto_version(serverctx, TLS1_3_VERSION) || + !SSL_CTX_set_min_proto_version(clientctx, TLS1_3_VERSION) || + !SSL_CTX_set_max_proto_version(clientctx, TLS1_3_VERSION)) goto err; }