Lines Matching refs:testctx

45 static OSSL_LIB_CTX *testctx = NULL;  variable
795 testctx, testpropq); in load_example_key()
858 pkey = EVP_PKEY_new_raw_private_key_ex(testctx, "HMAC", in load_example_hmac_key()
943 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, keytype, testpropq))) in make_key_fromdata()
976 testctx, NULL); in test_selection()
1398 if (!TEST_true(EVP_DigestSignInit_ex(ctx, NULL, NULL, testctx, in test_EC_priv_only_legacy()
1532 ctx = EVP_PKEY_CTX_new_from_pkey(testctx, pkey, NULL); in test_EVP_PKEY_sign()
1607 ctx = EVP_PKEY_CTX_new_from_pkey(testctx, pkey, NULL); in test_EVP_PKEY_sign_with_app_method()
1662 else if (!TEST_ptr(type = EVP_CIPHER_fetch(testctx, "AES-256-CBC", in test_EVP_Enveloped()
1978 if (!TEST_ptr(sha256 = EVP_MD_fetch(testctx, "sha256", testpropq)) in test_EVP_Digest()
1979 || !TEST_ptr(shake256 = EVP_MD_fetch(testctx, "shake256", testpropq))) in test_EVP_Digest()
2164 if (testctx != NULL) in test_EVP_PKCS82PKEY_wrong_tag()
2266 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, "EC", NULL)) in test_EC_keygen_with_enc()
2275 if (!TEST_ptr(kctx = EVP_PKEY_CTX_new_from_pkey(testctx, params, NULL)) in test_EC_keygen_with_enc()
2331 pkey = PEM_read_bio_PUBKEY_ex(bio, NULL, NULL, NULL, testctx, testpropq); in test_EVP_SM2_verify()
2341 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_pkey(testctx, pkey, testpropq))) in test_EVP_SM2_verify()
2346 if (!TEST_ptr(sm3 = EVP_MD_fetch(testctx, "sm3", testpropq))) in test_EVP_SM2_verify()
2399 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, in test_EVP_SM2()
2412 if (!TEST_ptr(kctx = EVP_PKEY_CTX_new_from_pkey(testctx, in test_EVP_SM2()
2428 if (!TEST_ptr(sctx = EVP_PKEY_CTX_new_from_pkey(testctx, pkey, testpropq))) in test_EVP_SM2()
2434 if (!TEST_ptr(check_md = EVP_MD_fetch(testctx, "sm3", testpropq))) in test_EVP_SM2()
2510 if (!TEST_ptr(cctx = EVP_PKEY_CTX_new_from_pkey(testctx, in test_EVP_SM2()
2543 if (!TEST_ptr(check_md = EVP_MD_fetch(testctx, mdname, testpropq))) in test_EVP_SM2()
2632 testctx, in test_set_get_raw_keys_int()
2651 testctx, OBJ_nid2sn(keys[tst].type), in test_set_get_raw_keys_int()
2741 if (!TEST_ptr(ctx = EVP_PKEY_CTX_new_from_pkey(testctx, pkey, testpropq))) in test_EVP_PKEY_check()
2789 || !TEST_true(EVP_DigestSignInit_ex(mdctx, NULL, NULL, testctx, in get_cmac_val()
2875 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, "HKDF", testpropq))) in test_HKDF()
2919 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, "HKDF", testpropq))) in test_emptyikm_HKDF()
2960 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, "HKDF", testpropq))) in test_empty_salt_info_HKDF()
2990 X509_PUBKEY *xp = X509_PUBKEY_new_ex(testctx, testpropq); in test_X509_PUBKEY_inplace()
3025 xp = X509_PUBKEY_new_ex(testctx, testpropq); in test_X509_PUBKEY_dup()
3073 ctx = EVP_PKEY_CTX_new_from_pkey(testctx, pkey, testpropq); in test_EVP_PKEY_CTX_get_set_params()
3129 || !TEST_true(EVP_DigestSignInit_ex(mdctx, NULL, "SHA1", testctx, testpropq, in test_EVP_PKEY_CTX_get_set_params()
3176 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, "DSA", NULL)) in test_DSA_get_set_params()
3243 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, "RSA", NULL)) in test_RSA_get_set_params()
3341 || !TEST_ptr(key_ctx = EVP_PKEY_CTX_new_from_pkey(testctx, key, NULL)) in test_RSA_OAEP_set_null_label()
3448 if (!TEST_ptr(cipher = EVP_CIPHER_fetch(testctx, "ChaCha20-Poly1305", testpropq)) in test_decrypt_null_chunks()
3700 || !TEST_ptr(rand = EVP_RAND_fetch(testctx, "TEST-RAND", testpropq))) in test_rand_agglomeration()
3780 EVP_CIPHER_fetch(testctx, "aes-128-cbc", testpropq); in test_evp_iv_aes()
3790 EVP_CIPHER_fetch(testctx, "aes-128-ofb", testpropq); in test_evp_iv_aes()
3800 EVP_CIPHER_fetch(testctx, "aes-128-cfb", testpropq); in test_evp_iv_aes()
3810 EVP_CIPHER_fetch(testctx, "aes-128-gcm", testpropq); in test_evp_iv_aes()
3819 EVP_CIPHER_fetch(testctx, "aes-128-ccm", testpropq); in test_evp_iv_aes()
3833 EVP_CIPHER_fetch(testctx, "aes-128-ocb", testpropq); in test_evp_iv_aes()
3926 type = EVP_CIPHER_fetch(testctx, "des-cbc", testpropq); in test_evp_iv_des()
3931 type = EVP_CIPHER_fetch(testctx, "des-ofb", testpropq); in test_evp_iv_des()
3936 type = EVP_CIPHER_fetch(testctx, "des-cfb", testpropq); in test_evp_iv_des()
3941 type = EVP_CIPHER_fetch(testctx, "des-ede3-cbc", testpropq); in test_evp_iv_des()
3946 type = EVP_CIPHER_fetch(testctx, "des-ede3-ofb", testpropq); in test_evp_iv_des()
3951 type = EVP_CIPHER_fetch(testctx, "des-ede3-cfb", testpropq); in test_evp_iv_des()
4004 if (!TEST_ptr(cipher = EVP_CIPHER_fetch(testctx, algos[idx], testpropq)) in test_evp_bf_default_keylen()
4099 md = EVP_MD_fetch(testctx, "sha256", testpropq); in test_EVP_rsa_pss_with_keygen_bits()
4101 && TEST_ptr((ctx = EVP_PKEY_CTX_new_from_name(testctx, "RSA-PSS", testpropq))) in test_EVP_rsa_pss_with_keygen_bits()
4124 && TEST_ptr(sha256 = EVP_MD_fetch(testctx, "sha256", NULL)) in test_EVP_rsa_pss_set_saltlen()
4324 if (!TEST_ptr(type = EVP_CIPHER_fetch(testctx, t->cipher, testpropq))) { in test_evp_init_seq()
4406 || !TEST_ptr(type = EVP_CIPHER_fetch(testctx, t->cipher, testpropq)) in test_evp_reinit_seq()
4466 if (!TEST_ptr(type = EVP_CIPHER_fetch(testctx, "aes-128-cfb", testpropq))) { in test_evp_reset()
4579 if ((type = EVP_CIPHER_fetch(testctx, t->cipher, testpropq)) == NULL) { in test_evp_updated_iv()
4665 if (!TEST_ptr(type = EVP_CIPHER_fetch(testctx, "aes-256-gcm", testpropq))) { in test_gcm_reinit()
4776 if (!TEST_ptr(ciph = EVP_CIPHER_fetch(testctx, ivlen_change_ciphers[idx], in test_ivlen_change()
4847 if (!TEST_ptr(ciph = EVP_CIPHER_fetch(testctx, keylen_change_ciphers[idx], in test_keylen_change()
4971 if (testctx != NULL) in test_custom_pmeth()
5194 if (testctx != NULL) in test_custom_md_meth()
5289 if (testctx != NULL) in test_custom_ciph_meth()
5491 pkey = EVP_PKEY_new_raw_private_key_ex(testctx, OBJ_nid2sn(ecxnids[tst]), in test_ecx_short_keys()
5549 pkey = EVP_PKEY_new_raw_public_key_ex(testctx, OBJ_nid2sn(keys[tst].type), in test_ecx_not_private_key()
5605 if (!TEST_ptr(fake_rsa = fake_rsa_start(testctx))) in test_sign_continuation()
5609 if (!TEST_ptr(pctx = EVP_PKEY_CTX_new_from_name(testctx, "RSA", in test_sign_continuation()
5618 || !TEST_true(EVP_DigestSignInit_ex(mctx, NULL, NULL, testctx, in test_sign_continuation()
5630 || !TEST_true(EVP_DigestSignInit_ex(mctx, NULL, NULL, testctx, in test_sign_continuation()
5666 || !TEST_ptr(cipher = EVP_CIPHER_fetch(testctx, "AES-256-GCM", ""))) in aes_gcm_encrypt()
5716 if ((cipher = EVP_CIPHER_fetch(testctx, "AES-256-GCM", "")) == NULL) in aes_gcm_decrypt()
5803 || !TEST_ptr(cipher = EVP_CIPHER_fetch(testctx, "RC4", ""))) in rc4_encrypt()
5842 if ((cipher = EVP_CIPHER_fetch(testctx, "RC4", "")) == NULL) in rc4_decrypt()
5923 testctx = OSSL_LIB_CTX_new(); in setup_tests()
5924 if (!TEST_ptr(testctx)) in setup_tests()
5932 if (!OSSL_PROVIDER_add_builtin(testctx, "legacy", ossl_legacy_provider_init)) in setup_tests()
5937 deflprov = OSSL_PROVIDER_load(testctx, "default"); in setup_tests()
5939 lgcyprov = OSSL_PROVIDER_load(testctx, "legacy"); in setup_tests()
5944 if (!test_get_libctx(&testctx, &nullprov, config_file, NULL, NULL)) in setup_tests()
6073 if (testctx == NULL) { in setup_tests()
6109 OSSL_LIB_CTX_free(testctx); in cleanup_tests()