Home
last modified time | relevance | path

Searched refs:mbedtls_pk_context (Results 1 – 25 of 55) sorted by relevance

123

/mbedtls-latest/include/mbedtls/
Dpk.h220 typedef struct mbedtls_pk_context { struct
265 } mbedtls_pk_context; typedef
310 void mbedtls_pk_init(mbedtls_pk_context *ctx);
323 void mbedtls_pk_free(mbedtls_pk_context *ctx);
358 int mbedtls_pk_setup(mbedtls_pk_context *ctx, const mbedtls_pk_info_t *info);
397 int mbedtls_pk_setup_opaque(mbedtls_pk_context *ctx,
417 int mbedtls_pk_setup_rsa_alt(mbedtls_pk_context *ctx, void *key,
430 size_t mbedtls_pk_get_bitlen(const mbedtls_pk_context *ctx);
439 static inline size_t mbedtls_pk_get_len(const mbedtls_pk_context *ctx) in mbedtls_pk_get_len()
456 int mbedtls_pk_can_do(const mbedtls_pk_context *ctx, mbedtls_pk_type_t type);
[all …]
Dx509_crt.h61 mbedtls_pk_context pk; /**< Container for the public key context. */
221 mbedtls_pk_context *MBEDTLS_PRIVATE(subject_key);
222 mbedtls_pk_context *MBEDTLS_PRIVATE(issuer_key);
1042 void mbedtls_x509write_crt_set_subject_key(mbedtls_x509write_cert *ctx, mbedtls_pk_context *key);
1050 void mbedtls_x509write_crt_set_issuer_key(mbedtls_x509write_cert *ctx, mbedtls_pk_context *key);
Dx509_csr.h47 mbedtls_pk_context pk; /**< Container for the public key context. */
67 mbedtls_pk_context *MBEDTLS_PRIVATE(key);
252 void mbedtls_x509write_csr_set_key(mbedtls_x509write_csr *ctx, mbedtls_pk_context *key);
/mbedtls-latest/library/
Dpk_wrap.c58 static size_t rsa_get_bitlen(mbedtls_pk_context *pk) in rsa_get_bitlen()
65 static int rsa_verify_wrap(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg, in rsa_verify_wrap()
130 static int rsa_verify_wrap(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg, in rsa_verify_wrap()
230 static int rsa_sign_wrap(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg, in rsa_sign_wrap()
254 static int rsa_sign_wrap(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg, in rsa_sign_wrap()
279 static int rsa_decrypt_wrap(mbedtls_pk_context *pk, in rsa_decrypt_wrap()
345 static int rsa_decrypt_wrap(mbedtls_pk_context *pk, in rsa_decrypt_wrap()
362 static int rsa_encrypt_wrap(mbedtls_pk_context *pk, in rsa_encrypt_wrap()
427 static int rsa_encrypt_wrap(mbedtls_pk_context *pk, in rsa_encrypt_wrap()
444 static int rsa_check_pair_wrap(mbedtls_pk_context *pub, mbedtls_pk_context *prv, in rsa_check_pair_wrap()
[all …]
Dpk_wrap.h30 size_t (*get_bitlen)(mbedtls_pk_context *pk);
36 int (*verify_func)(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg,
41 int (*sign_func)(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg,
49 int (*verify_rs_func)(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg,
55 int (*sign_rs_func)(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg,
63 int (*decrypt_func)(mbedtls_pk_context *pk, const unsigned char *input, size_t ilen,
69 int (*encrypt_func)(mbedtls_pk_context *pk, const unsigned char *input, size_t ilen,
75 int (*check_pair_func)(mbedtls_pk_context *pub, mbedtls_pk_context *prv,
94 void (*debug_func)(mbedtls_pk_context *pk, mbedtls_pk_debug_item *items);
Dpk.c41 void mbedtls_pk_init(mbedtls_pk_context *ctx) in mbedtls_pk_init()
59 void mbedtls_pk_free(mbedtls_pk_context *ctx) in mbedtls_pk_free()
77 mbedtls_platform_zeroize(ctx, sizeof(mbedtls_pk_context)); in mbedtls_pk_free()
136 int mbedtls_pk_setup(mbedtls_pk_context *ctx, const mbedtls_pk_info_t *info) in mbedtls_pk_setup()
156 int mbedtls_pk_setup_opaque(mbedtls_pk_context *ctx, in mbedtls_pk_setup_opaque()
195 int mbedtls_pk_setup_rsa_alt(mbedtls_pk_context *ctx, void *key, in mbedtls_pk_setup_rsa_alt()
227 int mbedtls_pk_can_do(const mbedtls_pk_context *ctx, mbedtls_pk_type_t type) in mbedtls_pk_can_do()
243 int mbedtls_pk_can_do_ext(const mbedtls_pk_context *ctx, psa_algorithm_t alg, in mbedtls_pk_can_do_ext()
400 int mbedtls_pk_get_psa_attributes(const mbedtls_pk_context *pk, in mbedtls_pk_get_psa_attributes()
641 static int import_pair_into_psa(const mbedtls_pk_context *pk, in import_pair_into_psa()
[all …]
Dpk_internal.h60 static inline const mbedtls_ecp_keypair *mbedtls_pk_ec_ro(const mbedtls_pk_context pk) in mbedtls_pk_ec_ro()
72 static inline mbedtls_ecp_keypair *mbedtls_pk_ec_rw(const mbedtls_pk_context pk) in mbedtls_pk_ec_rw()
86 static inline mbedtls_ecp_group_id mbedtls_pk_get_ec_group_id(const mbedtls_pk_context *pk) in mbedtls_pk_get_ec_group_id()
124 static inline int mbedtls_pk_is_rfc8410(const mbedtls_pk_context *pk) in mbedtls_pk_is_rfc8410()
138 int mbedtls_pk_ecc_set_group(mbedtls_pk_context *pk, mbedtls_ecp_group_id grp_id);
147 int mbedtls_pk_ecc_set_key(mbedtls_pk_context *pk, unsigned char *key, size_t key_len);
162 int mbedtls_pk_ecc_set_pubkey(mbedtls_pk_context *pk, const unsigned char *pub, size_t pub_len);
183 int mbedtls_pk_ecc_set_pubkey_from_prv(mbedtls_pk_context *pk,
197 mbedtls_pk_context *pk,
Dpkwrite.c63 const mbedtls_pk_context *pk) in pk_write_rsa_der()
95 const mbedtls_pk_context *pk) in pk_write_ec_pubkey()
120 const mbedtls_pk_context *pk) in pk_write_ec_pubkey()
165 const mbedtls_pk_context *pk) in pk_write_ec_private()
193 const mbedtls_pk_context *pk) in pk_write_ec_private()
264 const mbedtls_pk_context *pk) in pk_write_ec_rfc8410_der()
307 const mbedtls_pk_context *pk) in pk_write_ec_der()
361 const mbedtls_pk_context *pk) in pk_write_opaque_pubkey()
389 static mbedtls_pk_type_t pk_get_type_ext(const mbedtls_pk_context *pk) in pk_get_type_ext()
420 const mbedtls_pk_context *key) in mbedtls_pk_write_pubkey()
[all …]
Dpk_ecc.c17 int mbedtls_pk_ecc_set_group(mbedtls_pk_context *pk, mbedtls_ecp_group_id grp_id) in mbedtls_pk_ecc_set_group()
48 int mbedtls_pk_ecc_set_key(mbedtls_pk_context *pk, unsigned char *key, size_t key_len) in mbedtls_pk_ecc_set_key()
84 int mbedtls_pk_ecc_set_pubkey_from_prv(mbedtls_pk_context *pk, in mbedtls_pk_ecc_set_pubkey_from_prv()
166 static int pk_ecc_set_pubkey_psa_ecp_fallback(mbedtls_pk_context *pk, in pk_ecc_set_pubkey_psa_ecp_fallback()
204 int mbedtls_pk_ecc_set_pubkey(mbedtls_pk_context *pk, const unsigned char *pub, size_t pub_len) in mbedtls_pk_ecc_set_pubkey()
Dpkparse.c389 static int pk_use_ecparams(const mbedtls_asn1_buf *params, mbedtls_pk_context *pk) in pk_use_ecparams()
415 mbedtls_pk_context *pk) in pk_use_ecparams_rfc8410()
429 static int pk_parse_key_rfc8410_der(mbedtls_pk_context *pk, in pk_parse_key_rfc8410_der()
518 mbedtls_pk_context *pk) in mbedtls_pk_parse_subpubkey()
604 static int pk_parse_key_sec1_der(mbedtls_pk_context *pk, in pk_parse_key_sec1_der()
743 mbedtls_pk_context *pk, in pk_parse_key_pkcs8_unencrypted_der()
866 mbedtls_pk_context *pk, in mbedtls_pk_parse_key_pkcs8_encrypted_der()
973 int mbedtls_pk_parse_key(mbedtls_pk_context *pk, in mbedtls_pk_parse_key()
1180 int mbedtls_pk_parse_public_key(mbedtls_pk_context *ctx, in mbedtls_pk_parse_public_key()
1347 int mbedtls_pk_parse_keyfile(mbedtls_pk_context *ctx, in mbedtls_pk_parse_keyfile()
[all …]
Dssl_misc.h837 mbedtls_pk_context peer_pubkey; /*!< The public key from the peer. */
1249 mbedtls_pk_context *key; /*!< private key */
1564 unsigned char mbedtls_ssl_sig_from_pk(mbedtls_pk_context *pk);
1650 static inline mbedtls_pk_context *mbedtls_ssl_own_key(mbedtls_ssl_context *ssl) in mbedtls_ssl_own_key()
2509 mbedtls_pk_context *key);
Ddebug.c235 const char *text, const mbedtls_pk_context *pk) in mbedtls_debug_print_psa_ec()
318 const char *text, const mbedtls_pk_context *pk) in debug_print_pk()
/mbedtls-latest/tests/suites/
Dtest_suite_pkparse.function18 static int test_psa_bridge(const mbedtls_pk_context *ctx,
87 static int pk_can_ecdsa(const mbedtls_pk_context *ctx)
116 mbedtls_pk_context ctx;
163 mbedtls_pk_context ctx;
200 mbedtls_pk_context ctx;
240 mbedtls_pk_context ctx;
281 mbedtls_pk_context pk;
298 mbedtls_pk_context pk;
321 mbedtls_pk_context pk;
Dtest_suite_pk.function257 static int pk_setup(mbedtls_pk_context *pk, mbedtls_pk_type_t pk_type, int curve_or_keybits)
396 static int pk_public_same(const mbedtls_pk_context *pk1,
397 const mbedtls_pk_context *pk2)
504 mbedtls_pk_context *pk, psa_key_type_t *psa_type)
650 mbedtls_pk_context pk, pk2;
758 mbedtls_pk_context pk;
793 mbedtls_pk_context ctx;
852 mbedtls_pk_context pk;
940 mbedtls_pk_context pk;
973 mbedtls_pk_context pk;
[all …]
Dtest_suite_pkwrite.function32 static int pk_write_any_key(mbedtls_pk_context *pk, unsigned char **p,
71 mbedtls_pk_context key;
191 mbedtls_pk_context priv_key;
/mbedtls-latest/programs/pkey/
Dkey_app_writer.c92 static int write_public_key(mbedtls_pk_context *key, const char *output_file) in write_public_key()
134 static int write_private_key(mbedtls_pk_context *key, const char *output_file) in write_private_key()
255 mbedtls_pk_context key; in main()
Dgen_key.c122 static int write_private_key(mbedtls_pk_context *key, const char *output_file) in write_private_key()
229 mbedtls_pk_context key; in main()
Dpk_verify.c39 mbedtls_pk_context pk; in main()
Drsa_verify_pss.c42 mbedtls_pk_context pk; in main()
Dpk_decrypt.c44 mbedtls_pk_context pk; in main()
Dpk_encrypt.c43 mbedtls_pk_context pk; in main()
Dpk_sign.c41 mbedtls_pk_context pk; in main()
/mbedtls-latest/docs/architecture/psa-migration/
Dpsa-legacy-bridges.md147 …enarios where an application has a legacy key pair or public key (`mbedtls_pk_context`) and needs …
160 Gap: a way to create a PSA key object from an `mbedtls_pk_context`. This partially exists in the fo…
164mbedtls_pk_context` object. Typically, there is an existing key in the PSA key store (possibly in …
251 Given an `mbedtls_pk_context`, we want a function that creates a PSA key with the same key material…
255 …f the key material is in a structured format, which is the case with an `mbedtls_pk_context` input.
256 …orithm, which as discussed above cannot be fully deduced from the `mbedtls_pk_context` object. Jus…
257 …cation. This is completely orthogonal to the information from the `mbedtls_pk_context` object. It …
266 int mbedtls_pk_get_psa_attributes(const mbedtls_pk_context *pk,
269 int mbedtls_pk_import_into_psa(const mbedtls_pk_context *pk,
290 …ype field in the attributes is consistent with the content of the `mbedtls_pk_context` object (RSA…
[all …]
/mbedtls-latest/programs/fuzz/
Dfuzz_pubkey.c10 mbedtls_pk_context pk; in LLVMFuzzerTestOneInput()
/mbedtls-latest/tests/include/test/
Dpsa_exercise_key.h283 const mbedtls_pk_context *pk);

123