Home
last modified time | relevance | path

Searched refs:md_ctx (Results 1 – 12 of 12) sorted by relevance

/openthread-3.7.0/third_party/mbedtls/repo/library/
Dmd.c267 if (ctx->md_ctx != NULL) { in mbedtls_md_free()
270 psa_hash_abort(ctx->md_ctx); in mbedtls_md_free()
276 mbedtls_md5_free(ctx->md_ctx); in mbedtls_md_free()
281 mbedtls_ripemd160_free(ctx->md_ctx); in mbedtls_md_free()
286 mbedtls_sha1_free(ctx->md_ctx); in mbedtls_md_free()
291 mbedtls_sha256_free(ctx->md_ctx); in mbedtls_md_free()
296 mbedtls_sha256_free(ctx->md_ctx); in mbedtls_md_free()
301 mbedtls_sha512_free(ctx->md_ctx); in mbedtls_md_free()
306 mbedtls_sha512_free(ctx->md_ctx); in mbedtls_md_free()
314 mbedtls_sha3_free(ctx->md_ctx); in mbedtls_md_free()
[all …]
Dhmac_drbg.c47 size_t md_len = mbedtls_md_get_size(ctx->md_ctx.md_info); in mbedtls_hmac_drbg_update()
55 if ((ret = mbedtls_md_hmac_reset(&ctx->md_ctx)) != 0) { in mbedtls_hmac_drbg_update()
58 if ((ret = mbedtls_md_hmac_update(&ctx->md_ctx, in mbedtls_hmac_drbg_update()
62 if ((ret = mbedtls_md_hmac_update(&ctx->md_ctx, in mbedtls_hmac_drbg_update()
67 if ((ret = mbedtls_md_hmac_update(&ctx->md_ctx, in mbedtls_hmac_drbg_update()
72 if ((ret = mbedtls_md_hmac_finish(&ctx->md_ctx, K)) != 0) { in mbedtls_hmac_drbg_update()
77 if ((ret = mbedtls_md_hmac_starts(&ctx->md_ctx, K, md_len)) != 0) { in mbedtls_hmac_drbg_update()
80 if ((ret = mbedtls_md_hmac_update(&ctx->md_ctx, in mbedtls_hmac_drbg_update()
84 if ((ret = mbedtls_md_hmac_finish(&ctx->md_ctx, ctx->V)) != 0) { in mbedtls_hmac_drbg_update()
103 if ((ret = mbedtls_md_setup(&ctx->md_ctx, md_info, 1)) != 0) { in mbedtls_hmac_drbg_seed_buf()
[all …]
Dpkcs12.c276 mbedtls_md_context_t md_ctx; in calculate_hashes() local
282 mbedtls_md_init(&md_ctx); in calculate_hashes()
284 if ((ret = mbedtls_md_setup(&md_ctx, md_info, 0)) != 0) { in calculate_hashes()
288 if ((ret = mbedtls_md_starts(&md_ctx)) != 0) { in calculate_hashes()
292 if ((ret = mbedtls_md_update(&md_ctx, diversifier, v)) != 0) { in calculate_hashes()
297 if ((ret = mbedtls_md_update(&md_ctx, salt_block, v)) != 0) { in calculate_hashes()
303 if ((ret = mbedtls_md_update(&md_ctx, pwd_block, v)) != 0) { in calculate_hashes()
308 if ((ret = mbedtls_md_finish(&md_ctx, hash_output)) != 0) { in calculate_hashes()
321 mbedtls_md_free(&md_ctx); in calculate_hashes()
Dpkcs5.c375 mbedtls_md_context_t md_ctx; in mbedtls_pkcs5_pbkdf2_hmac_ext() local
384 mbedtls_md_init(&md_ctx); in mbedtls_pkcs5_pbkdf2_hmac_ext()
386 if ((ret = mbedtls_md_setup(&md_ctx, md_info, 1)) != 0) { in mbedtls_pkcs5_pbkdf2_hmac_ext()
389 ret = pkcs5_pbkdf2_hmac(&md_ctx, password, plen, salt, slen, in mbedtls_pkcs5_pbkdf2_hmac_ext()
392 mbedtls_md_free(&md_ctx); in mbedtls_pkcs5_pbkdf2_hmac_ext()
Drsa.c1627 mbedtls_md_context_t md_ctx; in mgf_mask() local
1629 mbedtls_md_init(&md_ctx); in mgf_mask()
1635 mbedtls_md_init(&md_ctx); in mgf_mask()
1636 if ((ret = mbedtls_md_setup(&md_ctx, md_info, 0)) != 0) { in mgf_mask()
1654 if ((ret = mbedtls_md_starts(&md_ctx)) != 0) { in mgf_mask()
1657 if ((ret = mbedtls_md_update(&md_ctx, src, slen)) != 0) { in mgf_mask()
1660 if ((ret = mbedtls_md_update(&md_ctx, counter, 4)) != 0) { in mgf_mask()
1663 if ((ret = mbedtls_md_finish(&md_ctx, mask)) != 0) { in mgf_mask()
1678 mbedtls_md_free(&md_ctx); in mgf_mask()
1699 mbedtls_md_context_t md_ctx; in hash_mprime() local
[all …]
Dssl_tls.c6838 mbedtls_md_context_t md_ctx; in tls_prf_generic() local
6841 mbedtls_md_init(&md_ctx); in tls_prf_generic()
6864 if ((ret = mbedtls_md_setup(&md_ctx, md_info, 1)) != 0) { in tls_prf_generic()
6868 ret = mbedtls_md_hmac_starts(&md_ctx, secret, slen); in tls_prf_generic()
6872 ret = mbedtls_md_hmac_update(&md_ctx, tmp + md_len, nb); in tls_prf_generic()
6876 ret = mbedtls_md_hmac_finish(&md_ctx, tmp); in tls_prf_generic()
6882 ret = mbedtls_md_hmac_reset(&md_ctx); in tls_prf_generic()
6886 ret = mbedtls_md_hmac_update(&md_ctx, tmp, md_len + nb); in tls_prf_generic()
6890 ret = mbedtls_md_hmac_finish(&md_ctx, h_i); in tls_prf_generic()
6895 ret = mbedtls_md_hmac_reset(&md_ctx); in tls_prf_generic()
[all …]
/openthread-3.7.0/third_party/mbedtls/repo/programs/aes/
Dcrypt_and_hash.c78 mbedtls_md_context_t md_ctx; in main() local
92 mbedtls_md_init(&md_ctx); in main()
170 if (mbedtls_md_setup(&md_ctx, md_info, 1) != 0) { in main()
247 if (mbedtls_md_starts(&md_ctx) != 0) { in main()
251 if (mbedtls_md_update(&md_ctx, buffer, 8) != 0) { in main()
255 if (mbedtls_md_update(&md_ctx, (unsigned char *) p, strlen(p)) in main()
260 if (mbedtls_md_finish(&md_ctx, digest) != 0) { in main()
283 if (mbedtls_md_starts(&md_ctx) != 0) { in main()
288 if (mbedtls_md_update(&md_ctx, digest, 32) != 0) { in main()
293 if (mbedtls_md_update(&md_ctx, key, keylen) != 0) { in main()
[all …]
/openthread-3.7.0/third_party/mbedtls/repo/programs/hash/
Dgeneric_sum.c156 mbedtls_md_context_t md_ctx; in main() local
158 mbedtls_md_init(&md_ctx); in main()
185 if (mbedtls_md_setup(&md_ctx, md_info, 0)) { in main()
205 mbedtls_md_free(&md_ctx); in main()
/openthread-3.7.0/third_party/mbedtls/repo/include/mbedtls/
Dhmac_drbg.h77 mbedtls_md_context_t MBEDTLS_PRIVATE(md_ctx); /*!< HMAC context (inc. K) */
Dmd.h132 void *MBEDTLS_PRIVATE(md_ctx);
/openthread-3.7.0/third_party/mbedtls/repo/tests/suites/
Dtest_suite_md.function266 TEST_ASSERT(ctx.md_ctx != NULL);
313 TEST_ASSERT(ctx.md_ctx != NULL);
382 TEST_ASSERT(ctx.md_ctx != NULL);
/openthread-3.7.0/third_party/mbedtls/repo/docs/architecture/psa-migration/
Dmd-cipher-dispatch.md463 void *md_ctx; // mbedtls_xxx_context or psa_hash_operation