Home
last modified time | relevance | path

Searched refs:algctx (Results 1 – 25 of 38) sorted by relevance

12

/third_party/node/deps/openssl/openssl/crypto/evp/
Dkdf_lib.c32 || (ctx->algctx = kdf->newctx(ossl_provider_ctx(kdf->prov))) == NULL in EVP_KDF_CTX_new()
36 kdf->freectx(ctx->algctx); in EVP_KDF_CTX_new()
49 ctx->meth->freectx(ctx->algctx); in EVP_KDF_CTX_free()
50 ctx->algctx = NULL; in EVP_KDF_CTX_free()
59 if (src == NULL || src->algctx == NULL || src->meth->dupctx == NULL) in EVP_KDF_CTX_dup()
75 dst->algctx = src->meth->dupctx(src->algctx); in EVP_KDF_CTX_dup()
76 if (dst->algctx == NULL) { in EVP_KDF_CTX_dup()
119 ctx->meth->reset(ctx->algctx); in EVP_KDF_CTX_reset()
132 && ctx->meth->get_ctx_params(ctx->algctx, params)) in EVP_KDF_CTX_get_kdf_size()
146 return ctx->meth->derive(ctx->algctx, key, keylen, params); in EVP_KDF_derive()
[all …]
Dmac_lib.c27 || (ctx->algctx = mac->newctx(ossl_provider_ctx(mac->prov))) == NULL in EVP_MAC_CTX_new()
31 mac->freectx(ctx->algctx); in EVP_MAC_CTX_new()
44 ctx->meth->freectx(ctx->algctx); in EVP_MAC_CTX_free()
45 ctx->algctx = NULL; in EVP_MAC_CTX_free()
55 if (src->algctx == NULL) in EVP_MAC_CTX_dup()
71 dst->algctx = src->meth->dupctx(src->algctx); in EVP_MAC_CTX_dup()
72 if (dst->algctx == NULL) { in EVP_MAC_CTX_dup()
89 if (ctx->algctx != NULL) { in get_size_t_ctx_param()
94 if (ctx->meth->get_ctx_params(ctx->algctx, params)) in get_size_t_ctx_param()
121 return ctx->meth->init(ctx->algctx, key, keylen, params); in EVP_MAC_init()
[all …]
Ddigest.c45 if (ctx->algctx != NULL) { in evp_md_ctx_clear_digest()
47 ctx->digest->freectx(ctx->algctx); in evp_md_ctx_clear_digest()
48 ctx->algctx = NULL; in evp_md_ctx_clear_digest()
154 && ctx->pctx->op.sig.algctx != NULL) { in evp_md_init_internal()
172 if (ctx->algctx != NULL) { in evp_md_init_internal()
178 ctx->digest->freectx(ctx->algctx); in evp_md_init_internal()
179 ctx->algctx = NULL; in evp_md_init_internal()
263 if (ctx->algctx != NULL && ctx->digest != NULL && ctx->digest != type) { in evp_md_init_internal()
265 ctx->digest->freectx(ctx->algctx); in evp_md_init_internal()
266 ctx->algctx = NULL; in evp_md_init_internal()
[all …]
Dpmeth_lib.c166 && ctx->op.kex.algctx != NULL) in evp_pkey_ctx_state()
168 && ctx->op.sig.algctx != NULL) in evp_pkey_ctx_state()
170 && ctx->op.ciph.algctx != NULL) in evp_pkey_ctx_state()
174 && ctx->op.encap.algctx != NULL)) in evp_pkey_ctx_state()
380 if (ctx->op.sig.algctx != NULL && ctx->op.sig.signature != NULL) in evp_pkey_ctx_free_old_ops()
381 ctx->op.sig.signature->freectx(ctx->op.sig.algctx); in evp_pkey_ctx_free_old_ops()
383 ctx->op.sig.algctx = NULL; in evp_pkey_ctx_free_old_ops()
386 if (ctx->op.kex.algctx != NULL && ctx->op.kex.exchange != NULL) in evp_pkey_ctx_free_old_ops()
387 ctx->op.kex.exchange->freectx(ctx->op.kex.algctx); in evp_pkey_ctx_free_old_ops()
389 ctx->op.kex.algctx = NULL; in evp_pkey_ctx_free_old_ops()
[all …]
Dm_sigver.c54 if (ctx->algctx != NULL) { in do_sigver_init()
60 ctx->digest->freectx(ctx->algctx); in do_sigver_init()
61 ctx->algctx = NULL; in do_sigver_init()
86 || locpctx->op.sig.algctx == NULL)) in do_sigver_init()
205 locpctx->op.sig.algctx in do_sigver_init()
207 if (locpctx->op.sig.algctx == NULL) { in do_sigver_init()
266 ret = signature->digest_verify_init(locpctx->op.sig.algctx, in do_sigver_init()
273 ret = signature->digest_sign_init(locpctx->op.sig.algctx, in do_sigver_init()
413 || pctx->op.sig.algctx == NULL in EVP_DigestSignUpdate()
422 return pctx->op.sig.signature->digest_sign_update(pctx->op.sig.algctx, in EVP_DigestSignUpdate()
[all …]
Devp_rand.c95 return rand->meth->enable_locking(rand->algctx); in EVP_RAND_enable_locking()
104 return rand->meth->lock(rand->algctx); in evp_rand_lock()
112 rand->meth->unlock(rand->algctx); in evp_rand_unlock()
354 parent_ctx = parent->algctx; in EVP_RAND_CTX_new()
357 if ((ctx->algctx = rand->newctx(ossl_provider_ctx(rand->prov), parent_ctx, in EVP_RAND_CTX_new()
361 rand->freectx(ctx->algctx); in EVP_RAND_CTX_new()
385 ctx->meth->freectx(ctx->algctx); in EVP_RAND_CTX_free()
386 ctx->algctx = NULL; in EVP_RAND_CTX_free()
401 return ctx->meth->get_ctx_params(ctx->algctx, params); in evp_rand_get_ctx_params_locked()
419 return ctx->meth->set_ctx_params(ctx->algctx, params); in evp_rand_set_ctx_params_locked()
[all …]
Devp_enc.c38 if (ctx->algctx != NULL) { in EVP_CIPHER_CTX_reset()
40 ctx->cipher->freectx(ctx->algctx); in EVP_CIPHER_CTX_reset()
41 ctx->algctx = NULL; in EVP_CIPHER_CTX_reset()
204 if (ctx->algctx == NULL) { in evp_cipher_init_internal()
205 ctx->algctx = ctx->cipher->newctx(ossl_provider_ctx(cipher->prov)); in evp_cipher_init_internal()
206 if (ctx->algctx == NULL) { in evp_cipher_init_internal()
227 return ctx->cipher->einit(ctx->algctx, in evp_cipher_init_internal()
242 return ctx->cipher->dinit(ctx->algctx, in evp_cipher_init_internal()
643 ret = ctx->cipher->cupdate(ctx->algctx, out, &soutl, in EVP_EncryptUpdate()
704 ret = ctx->cipher->cfinal(ctx->algctx, out, &soutl, in EVP_EncryptFinal_ex()
[all …]
Dsignature.c519 ctx->op.sig.algctx = in evp_pkey_signature_init()
521 if (ctx->op.sig.algctx == NULL) { in evp_pkey_signature_init()
534 ret = signature->sign_init(ctx->op.sig.algctx, provkey, params); in evp_pkey_signature_init()
542 ret = signature->verify_init(ctx->op.sig.algctx, provkey, params); in evp_pkey_signature_init()
550 ret = signature->verify_recover_init(ctx->op.sig.algctx, provkey, in evp_pkey_signature_init()
559 signature->freectx(ctx->op.sig.algctx); in evp_pkey_signature_init()
560 ctx->op.sig.algctx = NULL; in evp_pkey_signature_init()
646 if (ctx->op.sig.algctx == NULL) in EVP_PKEY_sign()
649 ret = ctx->op.sig.signature->sign(ctx->op.sig.algctx, sig, siglen, in EVP_PKEY_sign()
690 if (ctx->op.sig.algctx == NULL) in EVP_PKEY_verify()
[all …]
Dkem.c138 ctx->op.encap.algctx = kem->newctx(ossl_provider_ctx(kem->prov)); in evp_kem_init()
139 if (ctx->op.encap.algctx == NULL) { in evp_kem_init()
152 ret = kem->encapsulate_init(ctx->op.encap.algctx, provkey, params); in evp_kem_init()
160 ret = kem->decapsulate_init(ctx->op.encap.algctx, provkey, params); in evp_kem_init()
198 if (ctx->op.encap.algctx == NULL) { in EVP_PKEY_encapsulate()
206 return ctx->op.encap.kem->encapsulate(ctx->op.encap.algctx, in EVP_PKEY_encapsulate()
229 if (ctx->op.encap.algctx == NULL) { in EVP_PKEY_decapsulate()
233 return ctx->op.encap.kem->decapsulate(ctx->op.encap.algctx, in EVP_PKEY_decapsulate()
Dasymcipher.c145 ctx->op.ciph.algctx = cipher->newctx(ossl_provider_ctx(cipher->prov)); in evp_pkey_asym_cipher_init()
146 if (ctx->op.ciph.algctx == NULL) { in evp_pkey_asym_cipher_init()
159 ret = cipher->encrypt_init(ctx->op.ciph.algctx, provkey, params); in evp_pkey_asym_cipher_init()
167 ret = cipher->decrypt_init(ctx->op.ciph.algctx, provkey, params); in evp_pkey_asym_cipher_init()
243 if (ctx->op.ciph.algctx == NULL) in EVP_PKEY_encrypt()
246 ret = ctx->op.ciph.cipher->encrypt(ctx->op.ciph.algctx, out, outlen, in EVP_PKEY_encrypt()
285 if (ctx->op.ciph.algctx == NULL) in EVP_PKEY_decrypt()
288 ret = ctx->op.ciph.cipher->decrypt(ctx->op.ciph.algctx, out, outlen, in EVP_PKEY_decrypt()
Devp_lib.c419 ret = ctx->cipher->ccipher(ctx->algctx, out, &outl, in EVP_Cipher()
424 ret = ctx->cipher->cupdate(ctx->algctx, out, &outl, in EVP_Cipher()
428 ret = ctx->cipher->cfinal(ctx->algctx, out, &outl, in EVP_Cipher()
515 rv = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_get_iv_length()
548 ret = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_get_tag_length()
562 ok = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_original_iv()
579 ok = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_iv()
593 ok = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_iv_noconst()
605 return evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params) > 0; in EVP_CIPHER_CTX_get_updated_iv()
614 return evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params) > 0; in EVP_CIPHER_CTX_get_original_iv()
[all …]
Dexchange.c336 ctx->op.kex.algctx = exchange->newctx(ossl_provider_ctx(exchange->prov)); in EVP_PKEY_derive_init_ex()
337 if (ctx->op.kex.algctx == NULL) { in EVP_PKEY_derive_init_ex()
342 ret = exchange->init(ctx->op.kex.algctx, provkey, params); in EVP_PKEY_derive_init_ex()
390 if (!EVP_PKEY_CTX_IS_DERIVE_OP(ctx) || ctx->op.kex.algctx == NULL) in EVP_PKEY_derive_set_peer_ex()
433 return ctx->op.kex.exchange->set_peer(ctx->op.kex.algctx, provkey); in EVP_PKEY_derive_set_peer_ex()
519 if (ctx->op.kex.algctx == NULL) in EVP_PKEY_derive()
522 ret = ctx->op.kex.exchange->derive(ctx->op.kex.algctx, key, pkeylen, in EVP_PKEY_derive()
Devp_local.h32 void *algctx; member
60 void *algctx; member
70 void *algctx; member
79 void *algctx; member
88 void *algctx; member
/third_party/openssl/crypto/evp/
Dkdf_lib.c32 || (ctx->algctx = kdf->newctx(ossl_provider_ctx(kdf->prov))) == NULL in EVP_KDF_CTX_new()
36 kdf->freectx(ctx->algctx); in EVP_KDF_CTX_new()
49 ctx->meth->freectx(ctx->algctx); in EVP_KDF_CTX_free()
50 ctx->algctx = NULL; in EVP_KDF_CTX_free()
59 if (src == NULL || src->algctx == NULL || src->meth->dupctx == NULL) in EVP_KDF_CTX_dup()
75 dst->algctx = src->meth->dupctx(src->algctx); in EVP_KDF_CTX_dup()
76 if (dst->algctx == NULL) { in EVP_KDF_CTX_dup()
119 ctx->meth->reset(ctx->algctx); in EVP_KDF_CTX_reset()
132 && ctx->meth->get_ctx_params(ctx->algctx, params)) in EVP_KDF_CTX_get_kdf_size()
146 return ctx->meth->derive(ctx->algctx, key, keylen, params); in EVP_KDF_derive()
[all …]
Dmac_lib.c27 || (ctx->algctx = mac->newctx(ossl_provider_ctx(mac->prov))) == NULL in EVP_MAC_CTX_new()
31 mac->freectx(ctx->algctx); in EVP_MAC_CTX_new()
44 ctx->meth->freectx(ctx->algctx); in EVP_MAC_CTX_free()
45 ctx->algctx = NULL; in EVP_MAC_CTX_free()
55 if (src->algctx == NULL) in EVP_MAC_CTX_dup()
71 dst->algctx = src->meth->dupctx(src->algctx); in EVP_MAC_CTX_dup()
72 if (dst->algctx == NULL) { in EVP_MAC_CTX_dup()
89 if (ctx->algctx != NULL) { in get_size_t_ctx_param()
94 if (ctx->meth->get_ctx_params(ctx->algctx, params)) in get_size_t_ctx_param()
121 return ctx->meth->init(ctx->algctx, key, keylen, params); in EVP_MAC_init()
[all …]
Ddigest.c45 if (ctx->algctx != NULL) { in evp_md_ctx_clear_digest()
47 ctx->digest->freectx(ctx->algctx); in evp_md_ctx_clear_digest()
48 ctx->algctx = NULL; in evp_md_ctx_clear_digest()
154 && ctx->pctx->op.sig.algctx != NULL) { in evp_md_init_internal()
172 if (ctx->algctx != NULL) { in evp_md_init_internal()
178 ctx->digest->freectx(ctx->algctx); in evp_md_init_internal()
179 ctx->algctx = NULL; in evp_md_init_internal()
263 if (ctx->algctx != NULL && ctx->digest != NULL && ctx->digest != type) { in evp_md_init_internal()
265 ctx->digest->freectx(ctx->algctx); in evp_md_init_internal()
266 ctx->algctx = NULL; in evp_md_init_internal()
[all …]
Dpmeth_lib.c166 && ctx->op.kex.algctx != NULL) in evp_pkey_ctx_state()
168 && ctx->op.sig.algctx != NULL) in evp_pkey_ctx_state()
170 && ctx->op.ciph.algctx != NULL) in evp_pkey_ctx_state()
174 && ctx->op.encap.algctx != NULL)) in evp_pkey_ctx_state()
380 if (ctx->op.sig.algctx != NULL && ctx->op.sig.signature != NULL) in evp_pkey_ctx_free_old_ops()
381 ctx->op.sig.signature->freectx(ctx->op.sig.algctx); in evp_pkey_ctx_free_old_ops()
383 ctx->op.sig.algctx = NULL; in evp_pkey_ctx_free_old_ops()
386 if (ctx->op.kex.algctx != NULL && ctx->op.kex.exchange != NULL) in evp_pkey_ctx_free_old_ops()
387 ctx->op.kex.exchange->freectx(ctx->op.kex.algctx); in evp_pkey_ctx_free_old_ops()
389 ctx->op.kex.algctx = NULL; in evp_pkey_ctx_free_old_ops()
[all …]
Dm_sigver.c54 if (ctx->algctx != NULL) { in do_sigver_init()
60 ctx->digest->freectx(ctx->algctx); in do_sigver_init()
61 ctx->algctx = NULL; in do_sigver_init()
86 || locpctx->op.sig.algctx == NULL)) in do_sigver_init()
205 locpctx->op.sig.algctx in do_sigver_init()
207 if (locpctx->op.sig.algctx == NULL) { in do_sigver_init()
266 ret = signature->digest_verify_init(locpctx->op.sig.algctx, in do_sigver_init()
273 ret = signature->digest_sign_init(locpctx->op.sig.algctx, in do_sigver_init()
413 || pctx->op.sig.algctx == NULL in EVP_DigestSignUpdate()
422 return pctx->op.sig.signature->digest_sign_update(pctx->op.sig.algctx, in EVP_DigestSignUpdate()
[all …]
Devp_rand.c95 return rand->meth->enable_locking(rand->algctx); in EVP_RAND_enable_locking()
104 return rand->meth->lock(rand->algctx); in evp_rand_lock()
112 rand->meth->unlock(rand->algctx); in evp_rand_unlock()
354 parent_ctx = parent->algctx; in EVP_RAND_CTX_new()
357 if ((ctx->algctx = rand->newctx(ossl_provider_ctx(rand->prov), parent_ctx, in EVP_RAND_CTX_new()
361 rand->freectx(ctx->algctx); in EVP_RAND_CTX_new()
385 ctx->meth->freectx(ctx->algctx); in EVP_RAND_CTX_free()
386 ctx->algctx = NULL; in EVP_RAND_CTX_free()
401 return ctx->meth->get_ctx_params(ctx->algctx, params); in evp_rand_get_ctx_params_locked()
419 return ctx->meth->set_ctx_params(ctx->algctx, params); in evp_rand_set_ctx_params_locked()
[all …]
Devp_enc.c38 if (ctx->algctx != NULL) { in EVP_CIPHER_CTX_reset()
40 ctx->cipher->freectx(ctx->algctx); in EVP_CIPHER_CTX_reset()
41 ctx->algctx = NULL; in EVP_CIPHER_CTX_reset()
204 if (ctx->algctx == NULL) { in evp_cipher_init_internal()
205 ctx->algctx = ctx->cipher->newctx(ossl_provider_ctx(cipher->prov)); in evp_cipher_init_internal()
206 if (ctx->algctx == NULL) { in evp_cipher_init_internal()
263 return ctx->cipher->einit(ctx->algctx, in evp_cipher_init_internal()
278 return ctx->cipher->dinit(ctx->algctx, in evp_cipher_init_internal()
679 ret = ctx->cipher->cupdate(ctx->algctx, out, &soutl, in EVP_EncryptUpdate()
740 ret = ctx->cipher->cfinal(ctx->algctx, out, &soutl, in EVP_EncryptFinal_ex()
[all …]
Dsignature.c519 ctx->op.sig.algctx = in evp_pkey_signature_init()
521 if (ctx->op.sig.algctx == NULL) { in evp_pkey_signature_init()
534 ret = signature->sign_init(ctx->op.sig.algctx, provkey, params); in evp_pkey_signature_init()
542 ret = signature->verify_init(ctx->op.sig.algctx, provkey, params); in evp_pkey_signature_init()
550 ret = signature->verify_recover_init(ctx->op.sig.algctx, provkey, in evp_pkey_signature_init()
559 signature->freectx(ctx->op.sig.algctx); in evp_pkey_signature_init()
560 ctx->op.sig.algctx = NULL; in evp_pkey_signature_init()
646 if (ctx->op.sig.algctx == NULL) in EVP_PKEY_sign()
649 ret = ctx->op.sig.signature->sign(ctx->op.sig.algctx, sig, siglen, in EVP_PKEY_sign()
690 if (ctx->op.sig.algctx == NULL) in EVP_PKEY_verify()
[all …]
Dkem.c138 ctx->op.encap.algctx = kem->newctx(ossl_provider_ctx(kem->prov)); in evp_kem_init()
139 if (ctx->op.encap.algctx == NULL) { in evp_kem_init()
152 ret = kem->encapsulate_init(ctx->op.encap.algctx, provkey, params); in evp_kem_init()
160 ret = kem->decapsulate_init(ctx->op.encap.algctx, provkey, params); in evp_kem_init()
198 if (ctx->op.encap.algctx == NULL) { in EVP_PKEY_encapsulate()
206 return ctx->op.encap.kem->encapsulate(ctx->op.encap.algctx, in EVP_PKEY_encapsulate()
229 if (ctx->op.encap.algctx == NULL) { in EVP_PKEY_decapsulate()
233 return ctx->op.encap.kem->decapsulate(ctx->op.encap.algctx, in EVP_PKEY_decapsulate()
Dasymcipher.c145 ctx->op.ciph.algctx = cipher->newctx(ossl_provider_ctx(cipher->prov)); in evp_pkey_asym_cipher_init()
146 if (ctx->op.ciph.algctx == NULL) { in evp_pkey_asym_cipher_init()
159 ret = cipher->encrypt_init(ctx->op.ciph.algctx, provkey, params); in evp_pkey_asym_cipher_init()
167 ret = cipher->decrypt_init(ctx->op.ciph.algctx, provkey, params); in evp_pkey_asym_cipher_init()
243 if (ctx->op.ciph.algctx == NULL) in EVP_PKEY_encrypt()
246 ret = ctx->op.ciph.cipher->encrypt(ctx->op.ciph.algctx, out, outlen, in EVP_PKEY_encrypt()
285 if (ctx->op.ciph.algctx == NULL) in EVP_PKEY_decrypt()
288 ret = ctx->op.ciph.cipher->decrypt(ctx->op.ciph.algctx, out, outlen, in EVP_PKEY_decrypt()
Devp_lib.c419 ret = ctx->cipher->ccipher(ctx->algctx, out, &outl, in EVP_Cipher()
424 ret = ctx->cipher->cupdate(ctx->algctx, out, &outl, in EVP_Cipher()
428 ret = ctx->cipher->cfinal(ctx->algctx, out, &outl, in EVP_Cipher()
515 rv = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_get_iv_length()
548 ret = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_get_tag_length()
562 ok = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_original_iv()
579 ok = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_iv()
593 ok = evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params); in EVP_CIPHER_CTX_iv_noconst()
605 return evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params) > 0; in EVP_CIPHER_CTX_get_updated_iv()
614 return evp_do_ciph_ctx_getparams(ctx->cipher, ctx->algctx, params) > 0; in EVP_CIPHER_CTX_get_original_iv()
[all …]
Dexchange.c336 ctx->op.kex.algctx = exchange->newctx(ossl_provider_ctx(exchange->prov)); in EVP_PKEY_derive_init_ex()
337 if (ctx->op.kex.algctx == NULL) { in EVP_PKEY_derive_init_ex()
342 ret = exchange->init(ctx->op.kex.algctx, provkey, params); in EVP_PKEY_derive_init_ex()
390 if (!EVP_PKEY_CTX_IS_DERIVE_OP(ctx) || ctx->op.kex.algctx == NULL) in EVP_PKEY_derive_set_peer_ex()
433 return ctx->op.kex.exchange->set_peer(ctx->op.kex.algctx, provkey); in EVP_PKEY_derive_set_peer_ex()
519 if (ctx->op.kex.algctx == NULL) in EVP_PKEY_derive()
522 ret = ctx->op.kex.exchange->derive(ctx->op.kex.algctx, key, pkeylen, in EVP_PKEY_derive()

12