/netbsd-src/crypto/external/bsd/openssl.old/dist/test/ |
H A D | sslapitest.c | 305 SSL *clientssl = NULL, *serverssl = NULL; in test_keylog() local 344 &clientssl, NULL, NULL)) in test_keylog() 345 || !TEST_true(create_ssl_connection(serverssl, clientssl, in test_keylog() 360 if (!TEST_true(test_keylog_output(client_log_buffer, clientssl, in test_keylog() 361 SSL_get_session(clientssl), &expected))) in test_keylog() 373 SSL_free(clientssl); in test_keylog() 385 SSL *clientssl = NULL, *serverssl = NULL; in test_keylog_no_master_key() local 422 &clientssl, NULL, NULL)) in test_keylog_no_master_key() 423 || !TEST_true(create_ssl_connection(serverssl, clientssl, in test_keylog_no_master_key() 438 if (!TEST_true(test_keylog_output(client_log_buffer, clientssl, in test_keylog_no_master_key() [all …]
|
H A D | dtlstest.c | 152 SSL *serverssl = NULL, *clientssl = NULL; in test_dtls_drop_records() local 167 if (!TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in test_dtls_drop_records() 169 || !TEST_true(create_ssl_connection(serverssl, clientssl, in test_dtls_drop_records() 171 || !TEST_ptr(sess = SSL_get1_session(clientssl))) in test_dtls_drop_records() 174 SSL_shutdown(clientssl); in test_dtls_drop_records() 177 SSL_free(clientssl); in test_dtls_drop_records() 178 serverssl = clientssl = NULL; in test_dtls_drop_records() 195 if (!TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in test_dtls_drop_records() 200 if (!TEST_true(SSL_set_session(clientssl, sess))) in test_dtls_drop_records() 204 DTLS_set_timer_cb(clientssl, timer_cb); in test_dtls_drop_records() [all …]
|
H A D | sslbuffertest.c | 49 SSL *serverssl = NULL, *clientssl = NULL; in test_func() local 55 if (!TEST_true(create_ssl_objects(serverctx, clientctx, &serverssl, &clientssl, in test_func() 61 if (!TEST_true(create_ssl_connection(serverssl, clientssl, SSL_ERROR_NONE))) { in test_func() 81 if (test >= 1 && !TEST_true(SSL_free_buffers(clientssl))) in test_func() 83 if (test >= 2 && !TEST_true(SSL_alloc_buffers(clientssl))) in test_func() 86 if (test >= 3 && !TEST_true(SSL_alloc_buffers(clientssl))) in test_func() 88 if (test >= 4 && !TEST_true(SSL_free_buffers(clientssl))) in test_func() 91 ret = SSL_write(clientssl, testdata + len, in test_func() 96 int ssl_error = SSL_get_error(clientssl, ret); in test_func() 147 SSL_free(clientssl); in test_func()
|
H A D | gosttest.c | 38 SSL *clientssl = NULL, *serverssl = NULL; in test_tls13() local 54 || !TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in test_tls13() 59 if (!TEST_false(create_ssl_connection(serverssl, clientssl, in test_tls13() 63 if (!TEST_true(create_ssl_connection(serverssl, clientssl, in test_tls13() 65 || !TEST_int_eq(SSL_version(clientssl), in test_tls13() 74 SSL_free(clientssl); in test_tls13()
|
H A D | ssltestlib.c | 805 SSL *serverssl = NULL, *clientssl = NULL; in create_ssl_objects() local 813 clientssl = *cssl; in create_ssl_objects() 814 else if (!TEST_ptr(clientssl = SSL_new(clientctx))) in create_ssl_objects() 817 if (SSL_is_dtls(clientssl)) { in create_ssl_objects() 842 SSL_set_bio(clientssl, s_to_c_bio, c_to_s_bio); in create_ssl_objects() 844 *cssl = clientssl; in create_ssl_objects() 849 SSL_free(clientssl); in create_ssl_objects() 865 int create_bare_ssl_connection(SSL *serverssl, SSL *clientssl, int want, in create_bare_ssl_connection() argument 875 retc = SSL_connect(clientssl); in create_bare_ssl_connection() 877 err = SSL_get_error(clientssl, retc); in create_bare_ssl_connection() [all …]
|
H A D | asynciotest.c | 292 SSL *serverssl = NULL, *clientssl = NULL; in test_asyncio() local 325 &clientssl, s_to_c_fbio, c_to_s_fbio)) in test_asyncio() 326 || !TEST_true(create_ssl_connection(serverssl, clientssl, in test_asyncio() 343 ret = SSL_write(clientssl, testdata + len, in test_asyncio() 348 int ssl_error = SSL_get_error(clientssl, ret); in test_asyncio() 381 SSL_free(clientssl); in test_asyncio() 383 clientssl = serverssl = NULL; in test_asyncio() 388 SSL_free(clientssl); in test_asyncio()
|
H A D | ssltestlib.h | 21 int create_bare_ssl_connection(SSL *serverssl, SSL *clientssl, int want, 23 int create_ssl_connection(SSL *serverssl, SSL *clientssl, int want); 24 void shutdown_ssl_connection(SSL *serverssl, SSL *clientssl);
|
H A D | recordlentest.c | 83 SSL *clientssl = NULL, *serverssl = NULL; in test_record_overflow() local 122 if (!TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in test_record_overflow() 149 if (!TEST_true(create_ssl_connection(serverssl, clientssl, in test_record_overflow() 178 SSL_free(clientssl); in test_record_overflow()
|
H A D | servername_test.c | 184 SSL *clientssl = NULL, *serverssl = NULL; in server_setup_sni() local 191 || !TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in server_setup_sni() 198 if (!TEST_true(create_ssl_connection(serverssl, clientssl, SSL_ERROR_NONE))) in server_setup_sni() 210 SSL_free(clientssl); in server_setup_sni()
|
/netbsd-src/crypto/external/bsd/openssl/dist/test/ |
H A D | dtlstest.c | 194 SSL *serverssl = NULL, *clientssl = NULL; in test_dtls_drop_records() local 225 if (!TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in test_dtls_drop_records() 227 || !TEST_true(create_ssl_connection(serverssl, clientssl, in test_dtls_drop_records() 229 || !TEST_ptr(sess = SSL_get1_session(clientssl))) in test_dtls_drop_records() 232 SSL_shutdown(clientssl); in test_dtls_drop_records() 235 SSL_free(clientssl); in test_dtls_drop_records() 236 serverssl = clientssl = NULL; in test_dtls_drop_records() 255 if (!TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in test_dtls_drop_records() 260 if (!TEST_true(SSL_set_session(clientssl, sess))) in test_dtls_drop_records() 264 DTLS_set_timer_cb(clientssl, timer_cb); in test_dtls_drop_records() [all …]
|
H A D | sslbuffertest.c | 58 SSL *serverssl = NULL, *clientssl = NULL; in test_func() local 64 if (!TEST_true(create_ssl_objects(serverctx, clientctx, &serverssl, &clientssl, in test_func() 70 if (!TEST_true(create_ssl_connection(serverssl, clientssl, SSL_ERROR_NONE))) { in test_func() 90 if (test >= 1 && !TEST_true(SSL_free_buffers(clientssl))) in test_func() 92 if (test >= 2 && !TEST_true(SSL_alloc_buffers(clientssl))) in test_func() 95 if (test >= 3 && !TEST_true(SSL_alloc_buffers(clientssl))) in test_func() 97 if (test >= 4 && !TEST_true(SSL_free_buffers(clientssl))) in test_func() 100 ret = SSL_write(clientssl, testdata + len, in test_func() 105 int ssl_error = SSL_get_error(clientssl, ret); in test_func() 156 SSL_free(clientssl); in test_func() [all …]
|
H A D | asynciotest.c | 292 SSL *serverssl = NULL, *clientssl = NULL; in test_asyncio() local 326 &clientssl, s_to_c_fbio, c_to_s_fbio)) in test_asyncio() 327 || !TEST_true(create_ssl_connection(serverssl, clientssl, in test_asyncio() 344 ret = SSL_write(clientssl, testdata + len, in test_asyncio() 349 int ssl_error = SSL_get_error(clientssl, ret); in test_asyncio() 382 SSL_free(clientssl); in test_asyncio() 384 clientssl = serverssl = NULL; in test_asyncio() 389 SSL_free(clientssl); in test_asyncio()
|
H A D | recordlentest.c | 83 SSL *clientssl = NULL, *serverssl = NULL; in test_record_overflow() local 122 if (!TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in test_record_overflow() 149 if (!TEST_true(create_ssl_connection(serverssl, clientssl, in test_record_overflow() 178 SSL_free(clientssl); in test_record_overflow()
|
H A D | servername_test.c | 205 SSL *clientssl = NULL, *serverssl = NULL; in server_setup_sni() local 212 || !TEST_true(create_ssl_objects(sctx, cctx, &serverssl, &clientssl, in server_setup_sni() 219 if (!TEST_true(create_ssl_connection(serverssl, clientssl, SSL_ERROR_NONE))) in server_setup_sni() 231 SSL_free(clientssl); in server_setup_sni()
|
/netbsd-src/crypto/external/bsd/openssl/dist/test/helpers/ |
H A D | ssltestlib.c | 977 SSL *serverssl = NULL, *clientssl = NULL; in create_ssl_objects2() local 985 clientssl = *cssl; in create_ssl_objects2() 986 else if (!TEST_ptr(clientssl = SSL_new(clientctx))) in create_ssl_objects2() 993 SSL_set_bio(clientssl, c_to_s_bio, c_to_s_bio); in create_ssl_objects2() 996 *cssl = clientssl; in create_ssl_objects2() 1001 SSL_free(clientssl); in create_ssl_objects2() 1014 SSL *serverssl = NULL, *clientssl = NULL; in create_ssl_objects() local 1022 clientssl = *cssl; in create_ssl_objects() 1023 else if (!TEST_ptr(clientssl = SSL_new(clientctx))) in create_ssl_objects() 1026 if (SSL_is_dtls(clientssl)) { in create_ssl_objects() [all …]
|
H A D | ssltestlib.h | 21 int create_bare_ssl_connection(SSL *serverssl, SSL *clientssl, int want, 26 int create_ssl_connection(SSL *serverssl, SSL *clientssl, int want); 27 void shutdown_ssl_connection(SSL *serverssl, SSL *clientssl);
|