Home
last modified time | relevance | path

Searched refs:evp_type (Results 1 – 20 of 20) sorted by relevance

/freebsd/crypto/openssl/providers/implementations/encode_decode/
H A Dml_dsa_codecs.c354 static const ML_COMMON_CODEC *ml_dsa_get_codec(int evp_type) in ml_dsa_get_codec() argument
356 switch (evp_type) { in ml_dsa_get_codec()
368 ossl_ml_dsa_d2i_PUBKEY(const uint8_t *pk, int pk_len, int evp_type, in ossl_ml_dsa_d2i_PUBKEY() argument
376 if ((params = ossl_ml_dsa_params_get(evp_type)) == NULL in ossl_ml_dsa_d2i_PUBKEY()
377 || (codec = ml_dsa_get_codec(evp_type)) == NULL) in ossl_ml_dsa_d2i_PUBKEY()
385 if ((ret = ossl_ml_dsa_key_new(libctx, propq, evp_type)) == NULL) in ossl_ml_dsa_d2i_PUBKEY()
401 int evp_type, PROV_CTX *provctx, in ossl_ml_dsa_d2i_PKCS8() argument
420 if ((v = ossl_ml_dsa_params_get(evp_type)) == NULL in ossl_ml_dsa_d2i_PKCS8()
421 || (codec = ml_dsa_get_codec(evp_type)) == NULL) in ossl_ml_dsa_d2i_PKCS8()
431 if (OBJ_obj2nid(alg->algorithm) != evp_type) in ossl_ml_dsa_d2i_PKCS8()
[all …]
H A Dml_kem_codecs.c221 static const ML_COMMON_CODEC *ml_kem_get_codec(int evp_type) in ml_kem_get_codec() argument
223 switch (evp_type) { in ml_kem_get_codec()
235 ossl_ml_kem_d2i_PUBKEY(const uint8_t *pubenc, int publen, int evp_type, in ossl_ml_kem_d2i_PUBKEY() argument
244 if ((v = ossl_ml_kem_get_vinfo(evp_type)) == NULL in ossl_ml_kem_d2i_PUBKEY()
245 || (codec = ml_kem_get_codec(evp_type)) == NULL) in ossl_ml_kem_d2i_PUBKEY()
254 if ((ret = ossl_ml_kem_key_new(libctx, propq, evp_type)) == NULL) in ossl_ml_kem_d2i_PUBKEY()
270 int evp_type, PROV_CTX *provctx, in ossl_ml_kem_d2i_PKCS8() argument
287 if ((v = ossl_ml_kem_get_vinfo(evp_type)) == NULL in ossl_ml_kem_d2i_PKCS8()
288 || (codec = ml_kem_get_codec(evp_type)) == NULL) in ossl_ml_kem_d2i_PKCS8()
298 if (OBJ_obj2nid(alg->algorithm) != evp_type) in ossl_ml_kem_d2i_PKCS8()
[all …]
H A Dml_dsa_codecs.h21 int evp_type, PROV_CTX *provctx,
24 int evp_type, PROV_CTX *provctx,
H A Dml_kem_codecs.h21 int evp_type, PROV_CTX *provctx,
24 int evp_type, PROV_CTX *provctx,
H A Ddecode_der2key.c89 int evp_type; member
142 && (OBJ_obj2nid(alg->algorithm) == ctx->desc->evp_type in der2key_decode_p8()
145 && ctx->desc->evp_type == NID_sm2))) in der2key_decode_p8()
487 ret = ctx->desc->evp_type == EVP_PKEY_SM2 in D2I_PUBKEY_NOCTX()
488 || ctx->desc->evp_type == NID_X9_62_id_ecPublicKey; in D2I_PUBKEY_NOCTX()
490 ret = ctx->desc->evp_type != EVP_PKEY_SM2; in D2I_PUBKEY_NOCTX()
588 key = ossl_ml_kem_d2i_PKCS8(*der, der_len, ctx->desc->evp_type, in ml_kem_d2i_PKCS8()
601 key = ossl_ml_kem_d2i_PUBKEY(*der, der_len, ctx->desc->evp_type, in ml_kem_d2i_PUBKEY()
662 if (OBJ_obj2nid(alg->algorithm) != ctx->desc->evp_type) in slh_dsa_d2i_PKCS8()
736 if (OBJ_cmp(OBJ_nid2obj(ctx->desc->evp_type), spki->algor.oid) != 0) { in slh_dsa_d2i_PUBKEY()
[all …]
/freebsd/crypto/openssl/test/
H A Dendecoder_legacy_test.c75 int evp_type; member
221 int evp_type; member
300 static int test_protected_PEM(const char *keytype, int evp_type, in test_protected_PEM() argument
342 || !TEST_true(EVP_PKEY_assign(decoded_legacy_pkey, evp_type, in test_protected_PEM()
366 static int test_unprotected_PEM(const char *keytype, int evp_type, in test_unprotected_PEM() argument
407 || !TEST_true(EVP_PKEY_assign(decoded_legacy_pkey, evp_type, in test_unprotected_PEM()
431 static int test_DER(const char *keytype, int evp_type, in test_DER() argument
477 || !TEST_true(EVP_PKEY_assign(decoded_legacy_pkey, evp_type, in test_DER()
519 || !TEST_int_eq(EVP_PKEY_get_id(downgraded_pkey), key->evp_type) in test_key()
534 if (!test_protected_PEM(key->keytype, key->evp_type, legacy_obj, in test_key()
[all …]
H A Dfake_rsaprov.c729 int evp_type; member
832 && OBJ_obj2nid(alg->algorithm) == ctx->desc->evp_type) in fake_rsa_der2key_decode_p8()
879 if (desc->evp_type == 0) in der2key_newctx()
880 ctx->desc->evp_type = OBJ_sn2nid(tls_name); in der2key_newctx()
H A Dtls-provider.c2116 int evp_type; member
2219 && OBJ_obj2nid(alg->algorithm) == ctx->desc->evp_type) in xor_der2key_decode_p8()
2263 if (desc->evp_type == 0) { in der2key_newctx()
2264 ctx->desc->evp_type = OBJ_sn2nid(tls_name); in der2key_newctx()
/freebsd/crypto/openssl/crypto/ml_dsa/
H A Dml_dsa_params.c96 const ML_DSA_PARAMS *ossl_ml_dsa_params_get(int evp_type) in ossl_ml_dsa_params_get() argument
101 if (p->evp_type == evp_type) in ossl_ml_dsa_params_get()
H A Dml_dsa_key.c79 int evp_type) in ossl_ml_dsa_key_new() argument
82 const ML_DSA_PARAMS *params = ossl_ml_dsa_params_get(evp_type); in ossl_ml_dsa_key_new()
507 int ossl_ml_dsa_key_matches(const ML_DSA_KEY *key, int evp_type) in ossl_ml_dsa_key_matches() argument
509 return (key->params->evp_type == evp_type); in ossl_ml_dsa_key_matches()
/freebsd/crypto/openssl/include/crypto/
H A Dml_dsa.h57 int evp_type; member
75 const ML_DSA_PARAMS *ossl_ml_dsa_params_get(int evp_type);
78 int evp_type);
101 __owur int ossl_ml_dsa_key_matches(const ML_DSA_KEY *key, int evp_type);
H A Dml_kem.h145 int evp_type; member
154 const ML_KEM_VINFO *ossl_ml_kem_get_vinfo(int evp_type);
215 int evp_type);
/freebsd/crypto/openssl/providers/implementations/signature/
H A Dml_dsa_sig.c52 int evp_type; member
67 static void *ml_dsa_newctx(void *provctx, int evp_type, const char *propq) in ml_dsa_newctx() argument
80 ctx->evp_type = evp_type; in ml_dsa_newctx()
142 if (!ossl_ml_dsa_key_matches(ctx->key, ctx->evp_type)) in ml_dsa_signverify_msg_init()
/freebsd/crypto/openssl/providers/implementations/keymgmt/
H A Dml_kem_kmgmt.c61 int evp_type; member
153 ML_KEM_KEY *ossl_prov_ml_kem_new(PROV_CTX *ctx, const char *propq, int evp_type) in ossl_prov_ml_kem_new() argument
165 if ((key = ossl_ml_kem_key_new(PROV_LIBCTX_OF(ctx), propq, evp_type)) != NULL) { in ossl_prov_ml_kem_new()
718 const OSSL_PARAM params[], int evp_type) in ml_kem_gen_init() argument
732 gctx->evp_type = evp_type; in ml_kem_gen_init()
763 key = ossl_prov_ml_kem_new(gctx->provctx, gctx->propq, gctx->evp_type); in ml_kem_gen()
H A Dml_dsa_kmgmt.c103 ML_DSA_KEY *ossl_prov_ml_dsa_new(PROV_CTX *ctx, const char *propq, int evp_type) in ossl_prov_ml_dsa_new() argument
110 key = ossl_ml_dsa_key_new(PROV_LIBCTX_OF(ctx), propq, evp_type); in ossl_prov_ml_dsa_new()
467 static void *ml_dsa_gen(void *genctx, int evp_type) in ml_dsa_gen() argument
474 key = ossl_prov_ml_dsa_new(gctx->provctx, gctx->propq, evp_type); in ml_dsa_gen()
H A Dmlx_kmgmt.c59 unsigned int evp_type; member
648 static void *mlx_kem_gen_init(int evp_type, OSSL_LIB_CTX *libctx, in mlx_kem_gen_init() argument
662 gctx->evp_type = evp_type; in mlx_kem_gen_init()
696 if ((key = mlx_kem_key_new(gctx->evp_type, gctx->libctx, propq)) == NULL) in mlx_kem_gen()
/freebsd/crypto/openssl/providers/implementations/include/prov/
H A Dml_dsa.h14 ossl_prov_ml_dsa_new(PROV_CTX *provctx, const char *propq, int evp_type);
H A Dml_kem.h14 ossl_prov_ml_kem_new(PROV_CTX *provctx, const char *propq, int evp_type);
/freebsd/crypto/openssl/crypto/ml_kem/
H A Dml_kem.c1460 #define CBD1(evp_type) ((evp_type) == EVP_PKEY_ML_KEM_512 ? cbd_3 : cbd_2) argument
1484 CBD_FUNC cbd_1 = CBD1(vinfo->evp_type); in encrypt_cpa()
1688 CBD_FUNC cbd_1 = CBD1(vinfo->evp_type); in genkey()
1909 const ML_KEM_VINFO *ossl_ml_kem_get_vinfo(int evp_type) in ossl_ml_kem_get_vinfo() argument
1911 switch (evp_type) { in ossl_ml_kem_get_vinfo()
1923 int evp_type) in ossl_ml_kem_key_new() argument
1925 const ML_KEM_VINFO *vinfo = ossl_ml_kem_get_vinfo(evp_type); in ossl_ml_kem_key_new()
1930 "unsupported ML-KEM key type: %d", evp_type); in ossl_ml_kem_key_new()
2250 switch (vinfo->evp_type) { in ossl_ml_kem_encap_seed()
2331 switch (vinfo->evp_type) { in ossl_ml_kem_decap()
/freebsd/crypto/openssl/crypto/pem/
H A Dpvkfmt.c73 static EVP_PKEY *evp_pkey_new0_key(void *key, int evp_type) in evp_pkey_new0_key() argument
84 if (!ossl_assert(evp_type == EVP_PKEY_RSA || evp_type == EVP_PKEY_DSA)) { in evp_pkey_new0_key()
90 switch (evp_type) { in evp_pkey_new0_key()
112 switch (evp_type) { in evp_pkey_new0_key()