/third_party/openssl/test/ |
D | bntest.c | 119 if (!TEST_ptr(ret = getBN(s, attribute)) in getint() 156 if (!TEST_ptr(a = BN_new()) in test_swap() 157 || !TEST_ptr(b = BN_new()) in test_swap() 158 || !TEST_ptr(c = BN_new()) in test_swap() 159 || !TEST_ptr(d = BN_new())) in test_swap() 164 && TEST_ptr(BN_copy(c, a)) in test_swap() 165 && TEST_ptr(BN_copy(d, b)))) in test_swap() 229 if (!TEST_ptr(a = BN_new()) in test_sub() 230 || !TEST_ptr(b = BN_new()) in test_sub() 231 || !TEST_ptr(c = BN_new())) in test_sub() [all …]
|
D | ocspapitest.c | 31 if (!TEST_ptr(certbio = BIO_new_file(certstr, "r"))) in get_cert_and_key() 35 if (!TEST_ptr(keybio = BIO_new_file(privkeystr, "r"))) in get_cert_and_key() 39 if (!TEST_ptr(cert) || !TEST_ptr(key)) in get_cert_and_key() 55 if (!TEST_ptr(certbio = BIO_new_file(certstr, "r"))) in get_cert() 59 if (!TEST_ptr(cert)) in get_cert() 87 if (!TEST_ptr(bs) in make_dummy_resp() 88 || !TEST_ptr(thisupd) in make_dummy_resp() 89 || !TEST_ptr(nextupd) in make_dummy_resp() 90 || !TEST_ptr(cid) in make_dummy_resp() 122 if (!TEST_ptr(bs) in test_resp_signer() [all …]
|
D | ectest.c | 38 if (!TEST_ptr(n1 = BN_new()) in group_order_tests() 39 || !TEST_ptr(n2 = BN_new()) in group_order_tests() 40 || !TEST_ptr(order = BN_new()) in group_order_tests() 41 || !TEST_ptr(ctx = BN_CTX_new()) in group_order_tests() 42 || !TEST_ptr(G = EC_GROUP_get0_generator(group)) in group_order_tests() 43 || !TEST_ptr(P = EC_POINT_new(group)) in group_order_tests() 44 || !TEST_ptr(Q = EC_POINT_new(group)) in group_order_tests() 45 || !TEST_ptr(R = EC_POINT_new(group)) in group_order_tests() 46 || !TEST_ptr(S = EC_POINT_new(group))) in group_order_tests() 160 if (!TEST_ptr(ctx = BN_CTX_new()) in prime_field_tests() [all …]
|
D | ec_internal_test.c | 31 if (!TEST_ptr(c = BN_CTX_get(ctx)) in group_field_tests() 78 if (!TEST_ptr(ctx = BN_CTX_new())) in field_tests() 84 if (!TEST_ptr(b = BN_CTX_get(ctx)) in field_tests() 85 || !TEST_ptr(group = EC_GROUP_new(meth)) in field_tests() 172 if (!TEST_ptr(group = EC_GROUP_new_by_curve_name(nid)) in field_tests_default() 173 || !TEST_ptr(ctx = BN_CTX_new()) in field_tests_default() 203 if (!TEST_ptr(grp) in decoded_flag_test() 210 if (!TEST_ptr(grp) in decoded_flag_test() 215 if (!TEST_ptr(ecparams = EC_GROUP_get_ecparameters(grp, NULL)) in decoded_flag_test() 216 || !TEST_ptr(grp_copy = EC_GROUP_new_from_ecparameters(ecparams)) in decoded_flag_test() [all …]
|
D | dhtest.c | 48 if (!TEST_ptr(dh = DH_new()) in dh_test() 49 || !TEST_ptr(p = BN_new()) in dh_test() 50 || !TEST_ptr(q = BN_new()) in dh_test() 51 || !TEST_ptr(g = BN_new()) in dh_test() 52 || !TEST_ptr(priv_key = BN_new())) in dh_test() 114 if (!TEST_ptr(pub_key2) in dh_test() 131 if (!TEST_ptr(_cb = BN_GENCB_new())) in dh_test() 134 if (!TEST_ptr(a = DH_new()) in dh_test() 152 if (!TEST_ptr(b = DH_new())) in dh_test() 155 if (!TEST_ptr(bp = BN_dup(ap)) in dh_test() [all …]
|
D | verify_extra_test.c | 33 if (!TEST_ptr(bio = BIO_new(BIO_s_file()))) in load_cert_pem() 36 (void)TEST_ptr(cert = PEM_read_bio_X509(bio, NULL, NULL, NULL)); in load_cert_pem() 217 ret = TEST_ptr(cert) in test_self_signed() 249 if (!TEST_ptr(eecert) in do_test_purpose() 250 || !TEST_ptr(untrcert) in do_test_purpose() 251 || !TEST_ptr(trcert) in do_test_purpose() 252 || !TEST_ptr(trusted) in do_test_purpose() 253 || !TEST_ptr(untrusted) in do_test_purpose() 254 || !TEST_ptr(ctx)) in do_test_purpose() 309 if (!TEST_ptr(certs_dir = test_get_argument(0))) { in setup_tests() [all …]
|
D | evp_extra_test.c | 525 if (!TEST_ptr(type = EVP_get_cipherbyname(t->cipher))) { in test_evp_init_seq() 624 if (!TEST_ptr(ctx = EVP_CIPHER_CTX_new())) { in test_evp_reset() 628 if (!TEST_ptr(type = EVP_get_cipherbyname("aes-128-cfb"))) { in test_evp_reset() 714 if (!TEST_ptr(ctx = EVP_CIPHER_CTX_new())) { in test_gcm_reinit() 718 if (!TEST_ptr(type = EVP_get_cipherbyname("aes-256-gcm"))) { in test_gcm_reinit() 868 if (!TEST_ptr(ctx = EVP_CIPHER_CTX_new())) { in test_evp_updated_iv() 888 if (!TEST_ptr(updated_iv = EVP_CIPHER_CTX_iv(ctx))) { in test_evp_updated_iv() 943 if (!TEST_ptr(pkey = EVP_PKEY_new()) in load_example_rsa_key() 969 if (!TEST_ptr(keypair = load_example_rsa_key()) in test_EVP_Enveloped() 970 || !TEST_ptr(kek = OPENSSL_zalloc(EVP_PKEY_size(keypair))) in test_EVP_Enveloped() [all …]
|
D | cmsapitest.c | 23 if (!TEST_ptr(certstack) || !TEST_ptr(msgbio) || !TEST_ptr(outmsgbio)) in test_encrypt_decrypt() 30 if (!TEST_ptr(content)) in test_encrypt_decrypt() 57 if (!TEST_ptr(certin = test_get_argument(0)) in setup_tests() 58 || !TEST_ptr(privkeyin = test_get_argument(1))) in setup_tests() 62 if (!TEST_ptr(certbio)) in setup_tests() 71 if (!TEST_ptr(privkeybio)) { in setup_tests()
|
D | ecdsatest.c | 36 if (!TEST_ptr(old_rand = RAND_get_rand_method())) in change_rand() 66 if (!TEST_ptr(tmp = BN_new()) in fbytes() 121 if (!TEST_ptr(mctx = EVP_MD_CTX_new()) in x9_62_tests() 123 || !TEST_ptr(message = OPENSSL_hexstr2buf(tbs, &msg_len)) in x9_62_tests() 128 || !TEST_ptr(key = EC_KEY_new_by_curve_name(nid)) in x9_62_tests() 130 || !TEST_ptr(r = BN_new()) in x9_62_tests() 131 || !TEST_ptr(s = BN_new()) in x9_62_tests() 143 || !TEST_ptr(qbuf = OPENSSL_hexstr2buf(ecdsa_cavs_kats[n].Q, &q_len)) in x9_62_tests() 151 || !TEST_ptr(signature = ECDSA_do_sign_ex(digest, dgst_len, in x9_62_tests() 219 if (!TEST_ptr(mctx = EVP_MD_CTX_new()) in test_builtin() [all …]
|
D | exptest.c | 54 if (!TEST_ptr(m = BN_new()) in test_mod_exp_zero() 55 || !TEST_ptr(a = BN_new()) in test_mod_exp_zero() 56 || !TEST_ptr(p = BN_new()) in test_mod_exp_zero() 57 || !TEST_ptr(r = BN_new())) in test_mod_exp_zero() 135 if (!TEST_ptr(ctx = BN_CTX_new())) in test_mod_exp() 138 if (!TEST_ptr(r_mont = BN_new()) in test_mod_exp() 139 || !TEST_ptr(r_mont_const = BN_new()) in test_mod_exp() 140 || !TEST_ptr(r_recp = BN_new()) in test_mod_exp() 141 || !TEST_ptr(r_simple = BN_new()) in test_mod_exp() 142 || !TEST_ptr(a = BN_new()) in test_mod_exp() [all …]
|
D | cipherbytes_test.c | 54 || !TEST_ptr(sk) in test_unsupported() 56 || !TEST_ptr(scsv) in test_unsupported() 80 || !TEST_ptr(sk) in test_v2() 82 || !TEST_ptr(scsv) in test_v2() 109 || !TEST_ptr(sk) in test_v3() 111 || !TEST_ptr(scsv) in test_v3() 134 if (!TEST_ptr(ctx = SSL_CTX_new(TLS_server_method())) in setup_tests() 135 || !TEST_ptr(s = SSL_new(ctx))) in setup_tests()
|
D | x509_check_cert_pkey_test.c | 59 if (!TEST_ptr(bio = BIO_new_file(k, "r"))) in test_x509_check_cert_pkey() 62 if (!TEST_ptr(pkey = PEM_read_bio_PrivateKey(bio, NULL, NULL, NULL))) in test_x509_check_cert_pkey() 68 if (!TEST_ptr(bio = BIO_new_file(c, "r"))) in test_x509_check_cert_pkey() 111 if (!TEST_ptr(c = test_get_argument(0)) in setup_tests() 112 || !TEST_ptr(k = test_get_argument(1)) in setup_tests() 113 || !TEST_ptr(t = test_get_argument(2)) in setup_tests() 114 || !TEST_ptr(e = test_get_argument(3))) { in setup_tests()
|
D | crltest.c | 241 if (!TEST_ptr(ctx) in verify() 242 || !TEST_ptr(store) in verify() 243 || !TEST_ptr(param) in verify() 244 || !TEST_ptr(roots)) in verify() 299 r = TEST_ptr(basic_crl) in test_basic_crl() 300 && TEST_ptr(revoked_crl) in test_basic_crl() 324 r = TEST_ptr(bad_issuer_crl) in test_bad_issuer_crl() 338 r = TEST_ptr(known_critical_crl) in test_known_critical_crl() 351 r = TEST_ptr(unknown_critical_crl) in test_unknown_critical_crl() 376 if (!TEST_ptr(test_root = X509_from_strings(kCRLTestRoot)) in setup_tests() [all …]
|
D | sm2_internal_test.c | 53 if (!TEST_ptr(saved_rand = RAND_get_rand_method())) in start_fake_rand() 102 if (!TEST_ptr(group)) in create_EC_group() 106 if (!TEST_ptr(generator)) in create_EC_group() 156 if (!TEST_ptr(expected) in test_sm2_crypt() 161 if (!TEST_ptr(key) in test_sm2_crypt() 167 if (!TEST_ptr(pt) in test_sm2_crypt() 174 if (!TEST_ptr(ctext)) in test_sm2_crypt() 193 if (!TEST_ptr(recovered) in test_sm2_crypt() 224 if (!TEST_ptr(test_group)) in sm2_crypt_test() 266 if (!TEST_ptr(gm_group)) in sm2_crypt_test() [all …]
|
D | enginetest.c | 58 if (!TEST_ptr(new_h1 = ENGINE_new()) in test_engines() 61 || !TEST_ptr(new_h2 = ENGINE_new()) in test_engines() 64 || !TEST_ptr(new_h3 = ENGINE_new()) in test_engines() 67 || !TEST_ptr(new_h4 = ENGINE_new()) in test_engines() 148 if (!TEST_ptr(block[loop] = ENGINE_new()) in test_engines() 256 if (!TEST_ptr(pkey = get_test_pkey())) in test_redirect() 260 if (!TEST_ptr(tmp = OPENSSL_malloc(len))) in test_redirect() 263 if (!TEST_ptr(ctx = EVP_PKEY_CTX_new(pkey, NULL))) in test_redirect() 275 if (!TEST_ptr(e = ENGINE_new()) in test_redirect() 290 if (!TEST_ptr(test_rsa = EVP_PKEY_meth_new(EVP_PKEY_RSA, 0))) in test_redirect() [all …]
|
D | servername_test.c | 95 if (!TEST_ptr(ctx)) in client_setup_sni_before_state() 99 if (!TEST_ptr(con)) in client_setup_sni_before_state() 107 if (!TEST_ptr(rbio)|| !TEST_ptr(wbio)) { in client_setup_sni_before_state() 143 if (!TEST_ptr(ctx)) in client_setup_sni_after_state() 147 if (!TEST_ptr(con)) in client_setup_sni_after_state() 152 if (!TEST_ptr(rbio)|| !TEST_ptr(wbio)) { in client_setup_sni_after_state() 236 if (!TEST_ptr(cert = test_get_argument(0)) in setup_tests() 237 || !TEST_ptr(privkey = test_get_argument(1))) in setup_tests()
|
D | danetest.c | 64 if (!TEST_ptr(store_ctx = X509_STORE_CTX_new()) in verify_chain() 65 || !TEST_ptr(ssl_ctx = SSL_get_SSL_CTX(ssl)) in verify_chain() 66 || !TEST_ptr(store = SSL_CTX_get_cert_store(ssl_ctx)) in verify_chain() 67 || !TEST_ptr(cert = sk_X509_value(chain, 0)) in verify_chain() 105 if (!TEST_ptr(chain = sk_X509_new_null())) in STACK_OF() 120 if (!TEST_ptr(cert = d(0, &p, len)) in STACK_OF() 188 if (!TEST_ptr(ret = OPENSSL_malloc(strlen(in) / 2))) in hexdecode() 325 if (!TEST_ptr(ssl = SSL_new(ctx))) in test_tlsafile() 344 if (!TEST_ptr(chain = load_chain(f, ncert))) { in test_tlsafile() 393 if (!TEST_ptr(f = BIO_new_file(tlsafile, "r")) in run_tlsatest() [all …]
|
D | sslcorrupttest.c | 44 if (!TEST_ptr(copy = BUF_memdup(in, inl))) in tls_corrupt_write() 147 if (!TEST_ptr(ctx = SSL_CTX_new(TLS_server_method())) in setup_cipher_list() 148 || !TEST_ptr(ssl = SSL_new(ctx)) in setup_cipher_list() 149 || !TEST_ptr(sk_ciphers = SSL_get1_supported_ciphers(ssl))) in setup_cipher_list() 159 if (!TEST_ptr(cipher_list)) in setup_cipher_list() 203 || !TEST_ptr(ciphers = SSL_CTX_get_ciphers(cctx)) in test_ssl_corrupt() 205 || !TEST_ptr(currcipher = sk_SSL_CIPHER_value(ciphers, 0))) in test_ssl_corrupt() 215 if (!TEST_ptr(c_to_s_fbio = BIO_new(bio_f_tls_corrupt_filter()))) in test_ssl_corrupt() 251 if (!TEST_ptr(cert = test_get_argument(0)) in setup_tests() 252 || !TEST_ptr(privkey = test_get_argument(1))) { in setup_tests()
|
D | exdatatest.c | 44 || !TEST_ptr(from_d)) in exdup() 78 || !TEST_ptr(ex_data) in exnew2() 95 || !TEST_ptr(from_d) in exdup2() 96 || !TEST_ptr(*update_ex_data) in exdup2() 97 || !TEST_ptr(ex_data) in exdup2() 119 || !TEST_ptr(ex_data) in exfree2() 155 if (TEST_ptr(ex_data)) in MYOBJ_sethello2() 164 if (TEST_ptr(ex_data)) in MYOBJ_gethello2() 208 if (!TEST_ptr(CRYPTO_get_ex_data(&t1->ex_data, saved_idx2))) in test_exdata() 210 if (!TEST_ptr(CRYPTO_get_ex_data(&t2->ex_data, saved_idx2))) in test_exdata() [all …]
|
D | rsa_mp_test.c | 157 if (!TEST_ptr(pris) || !TEST_ptr(exps) || !TEST_ptr(coeffs)) in key2048p3() 163 if (!TEST_ptr(pris[0]) || !TEST_ptr(exps[0]) || !TEST_ptr(coeffs[0])) in key2048p3() 199 if (!TEST_ptr(key)) in test_rsa_mp()
|
D | bio_memleak_test.c | 27 if (!TEST_ptr(bio)) in test_bio_memleak() 52 if (!TEST_ptr(bio)) in test_bio_get_mem() 57 if (!TEST_ptr(bufmem)) in test_bio_get_mem() 81 if (!TEST_ptr(bio)) in test_bio_new_mem_buf() 116 if (!TEST_ptr(bio)) in test_bio_rdonly_mem_buf() 127 if (!TEST_ptr(bio2)) in test_bio_rdonly_mem_buf() 157 if (!TEST_ptr(bio)) in test_bio_rdwr_rdonly() 193 if (!TEST_ptr(bio)) in test_bio_nonclear_rst() 247 if (!TEST_ptr(bio = BIO_new(BIO_s_mem()))) in test_bio_i2d_ASN1_mime() 257 if (!TEST_ptr(out = BIO_new(BIO_s_mem()))) in test_bio_i2d_ASN1_mime() [all …]
|
D | secmemtest.c | 25 if (!TEST_ptr(s) in test_sec_mem() 30 if (!TEST_ptr(r) in test_sec_mem() 35 if (!TEST_ptr(p) in test_sec_mem() 42 if (!TEST_ptr(q)) in test_sec_mem() 49 if (!TEST_ptr(s) in test_sec_mem() 144 || !TEST_ptr(p = OPENSSL_secure_malloc(size))) in test_sec_mem_clear()
|
D | clienthellotest.c | 85 if (!TEST_ptr(ctx)) in test_client_hello() 144 if (!TEST_ptr(con)) in test_client_hello() 149 if (!TEST_ptr(sessbio)) { in test_client_hello() 154 if (!TEST_ptr(sess)) { in test_client_hello() 169 if (!TEST_ptr(rbio)|| !TEST_ptr(wbio)) { in test_client_hello() 252 if (!TEST_ptr(sessionfile = test_get_argument(0))) in setup_tests()
|
D | dsa_no_digest_size_test.c | 111 if (!TEST_ptr(dsakey = load_dsa_params())) in genkeys() 137 if (!TEST_ptr(dataToSign) || in sign_and_verify() 138 !TEST_ptr(paddedData) || in sign_and_verify() 148 if (!TEST_ptr(pkey = EVP_PKEY_new())) in sign_and_verify() 152 if (!TEST_ptr(ctx = EVP_PKEY_CTX_new(pkey, NULL))) in sign_and_verify() 162 if (!TEST_ptr(signature = OPENSSL_malloc(sigLength))) in sign_and_verify()
|
/third_party/openssl/test/testutil/ |
D | stanza.c | 24 if (!TEST_ptr(s->fp = BIO_new_file(testfile, "r"))) in test_start_file() 46 if (!TEST_ptr(s->key = BIO_new(BIO_s_mem()))) in read_key() 93 if (!TEST_ptr(p = strchr(s->buff, '\n'))) { in test_readstanza() 108 if (!TEST_ptr(equals = strchr(s->buff, '='))) { in test_readstanza() 113 if (!TEST_ptr(key = strip_spaces(s->buff))) { in test_readstanza() 138 || !TEST_ptr(pp->key = OPENSSL_strdup(key)) in test_readstanza() 139 || !TEST_ptr(pp->value = OPENSSL_strdup(value))) in test_readstanza()
|