/openthread-latest/third_party/mbedtls/repo/tests/suites/ |
D | test_suite_ctr_drbg.function | 2 #include "mbedtls/entropy.h" 33 int entropy_len_arg, data_t *entropy, 46 test_max_idx = entropy->len; 48 /* CTR_DRBG_Instantiate(entropy[:entropy->len], nonce, perso, <ignored>) 54 mbedtls_test_entropy_func, entropy->x, 63 /* CTR_DRBG_Reseed(entropy[idx:idx+entropy->len], 79 /* CTR_DRBG_Reseed(entropy[idx:idx+entropy->len], 153 void ctr_drbg_validate_no_reseed(data_t *add_init, data_t *entropy, 160 entropy->len, entropy, 169 void ctr_drbg_validate_pr(data_t *add_init, data_t *entropy, [all …]
|
D | test_suite_random.function | 8 #include "mbedtls/entropy.h" 24 mbedtls_entropy_context entropy; 37 mbedtls_entropy_init(&entropy); 40 mbedtls_entropy_func, &entropy, 45 mbedtls_entropy_free(&entropy); 48 mbedtls_entropy_init(&entropy); 51 mbedtls_entropy_func, &entropy, 56 mbedtls_entropy_free(&entropy); 63 mbedtls_entropy_free(&entropy); 75 mbedtls_entropy_context entropy; [all …]
|
D | test_suite_psa_crypto_init.data | 28 Custom entropy sources: all standard 31 # MBEDTLS_PSA_INJECT_ENTROPY means that a source of entropy (the seed file) 33 Custom entropy sources: none 37 Fake entropy: never returns anything 40 Fake entropy: less than the block size 43 Fake entropy: not enough for a nonce 47 Fake entropy: one block eventually 51 Fake entropy: one block in two steps 55 Fake entropy: more than one block in two steps 59 Fake entropy: two blocks eventually
|
D | test_suite_hmac_drbg.function | 39 entropy_ctx entropy; 50 entropy.len = sizeof(buf); 51 entropy.p = buf; 66 /* Init must use entropy */ 67 TEST_ASSERT(mbedtls_hmac_drbg_seed(&ctx, md_info, mbedtls_test_entropy_func, &entropy, 69 /* default_entropy_len of entropy, plus half as much for the nonce */ 71 TEST_EQUAL(sizeof(buf) - entropy.len, expected_consumed_entropy); 74 * 2 * reps so the next few calls should not use entropy */ 80 TEST_EQUAL(sizeof(buf) - entropy.len, expected_consumed_entropy); 91 TEST_EQUAL(sizeof(buf) - entropy.len, expected_consumed_entropy); [all …]
|
D | test_suite_hmac_drbg.misc.data | 1 HMAC_DRBG entropy usage SHA-1 5 HMAC_DRBG entropy usage SHA-224 9 HMAC_DRBG entropy usage SHA-256 13 HMAC_DRBG entropy usage SHA-384 17 HMAC_DRBG entropy usage SHA-512 21 HMAC_DRBG entropy usage SHA3-224 25 HMAC_DRBG entropy usage SHA3-256 29 HMAC_DRBG entropy usage SHA3-384 33 HMAC_DRBG entropy usage SHA3-512
|
D | test_suite_psa_crypto_entropy.data | 28 PSA validate entropy injection: good, minimum size 31 PSA validate entropy injection: good, max size 34 PSA validate entropy injection: bad, too big 37 PSA validate entropy injection: bad, too small using MBEDTLS_ENTROPY_MIN_PLATFORM 40 PSA validate entropy injection: bad, too small using MBEDTLS_ENTROPY_BLOCK_SIZE 43 PSA validate entropy injection: before and after crypto_init
|
D | test_suite_entropy.function | 2 #include "mbedtls/entropy.h" 20 * Dummy entropy source 47 * Ability to clear entropy sources to allow testing with just predefined 48 * entropy sources. This function or tests depending on it might break if there 49 * are internal changes to how entropy sources are registered. 346 /* If the NV seed functionality is enabled, there are two entropy 394 /* If the NV seed functionality is enabled, there are two entropy 460 #error "Unsupported entropy accumulator" 470 unsigned char entropy[MBEDTLS_ENTROPY_BLOCK_SIZE]; 476 memset(entropy, 0, MBEDTLS_ENTROPY_BLOCK_SIZE); [all …]
|
D | test_suite_psa_crypto_init.function | 5 /* Some tests in this module configure entropy sources. */ 8 #include "mbedtls/entropy.h" 16 /* PSA crypto uses the HMAC_DRBG module. It reads from the entropy source twice: 17 * once for the initial entropy and once for a nonce. The nonce length is 18 * half the entropy length. For SHA-256, SHA-384 or SHA-512, the 19 * entropy length is 256 per the documentation of mbedtls_hmac_drbg_seed(), 24 * to read from the entropy source twice: once for the initial entropy 66 /* This is a modified version of mbedtls_entropy_init() from entropy.c 67 * which chooses entropy sources dynamically. */ 151 /* Bad state due to entropy sources already being setup in
|
/openthread-latest/third_party/mbedtls/repo/programs/random/ |
D | gen_entropy.c | 32 mbedtls_entropy_context entropy; in main() local 45 mbedtls_entropy_init(&entropy); in main() 48 ret = mbedtls_entropy_func(&entropy, buf, sizeof(buf)); in main() 71 mbedtls_entropy_free(&entropy); in main()
|
D | gen_random_ctr_drbg.c | 36 mbedtls_entropy_context entropy; in main() local 51 mbedtls_entropy_init(&entropy); in main() 54 &entropy, in main() 103 mbedtls_entropy_free(&entropy); in main()
|
/openthread-latest/third_party/mbedtls/repo/library/ |
D | psa_crypto_random_impl.h | 80 mbedtls_entropy_context entropy; member 122 mbedtls_entropy_context *entropy, in mbedtls_psa_drbg_seed() argument 126 return mbedtls_ctr_drbg_seed(drbg_ctx, mbedtls_entropy_func, entropy, custom, len); in mbedtls_psa_drbg_seed() 129 return mbedtls_hmac_drbg_seed(drbg_ctx, md_info, mbedtls_entropy_func, entropy, custom, len); in mbedtls_psa_drbg_seed()
|
/openthread-latest/third_party/mbedtls/repo/programs/fuzz/ |
D | fuzz_dtlsclient.c | 39 mbedtls_entropy_context entropy; in LLVMFuzzerTestOneInput() local 60 mbedtls_entropy_init(&entropy); in LLVMFuzzerTestOneInput() 70 if (mbedtls_ctr_drbg_seed(&ctr_drbg, dummy_entropy, &entropy, in LLVMFuzzerTestOneInput() 123 mbedtls_entropy_free(&entropy); in LLVMFuzzerTestOneInput()
|
D | fuzz_privkey.c | 22 mbedtls_entropy_context entropy; in LLVMFuzzerTestOneInput() local 30 mbedtls_entropy_init(&entropy); in LLVMFuzzerTestOneInput() 40 if (mbedtls_ctr_drbg_seed(&ctr_drbg, dummy_entropy, &entropy, in LLVMFuzzerTestOneInput() 92 mbedtls_entropy_free(&entropy); in LLVMFuzzerTestOneInput()
|
D | fuzz_client.c | 43 mbedtls_entropy_context entropy; in LLVMFuzzerTestOneInput() local 77 mbedtls_entropy_init(&entropy); in LLVMFuzzerTestOneInput() 86 if (mbedtls_ctr_drbg_seed(&ctr_drbg, dummy_entropy, &entropy, in LLVMFuzzerTestOneInput() 179 mbedtls_entropy_free(&entropy); in LLVMFuzzerTestOneInput()
|
D | fuzz_dtlsserver.c | 43 mbedtls_entropy_context entropy; in LLVMFuzzerTestOneInput() local 50 mbedtls_entropy_init(&entropy); in LLVMFuzzerTestOneInput() 66 if (mbedtls_ctr_drbg_seed(&ctr_drbg, dummy_entropy, &entropy, in LLVMFuzzerTestOneInput() 164 mbedtls_entropy_free(&entropy); in LLVMFuzzerTestOneInput()
|
/openthread-latest/third_party/mbedtls/repo/programs/pkey/ |
D | pk_decrypt.c | 45 mbedtls_entropy_context entropy; in main() local 53 mbedtls_entropy_init(&entropy); in main() 81 &entropy, (const unsigned char *) pers, in main() 137 mbedtls_entropy_free(&entropy); in main()
|
D | pk_encrypt.c | 44 mbedtls_entropy_context entropy; in main() local 51 mbedtls_entropy_init(&entropy); in main() 77 &entropy, (const unsigned char *) pers, in main() 138 mbedtls_entropy_free(&entropy); in main()
|
D | pk_sign.c | 42 mbedtls_entropy_context entropy; in main() local 50 mbedtls_entropy_init(&entropy); in main() 76 if ((ret = mbedtls_ctr_drbg_seed(&ctr_drbg, mbedtls_entropy_func, &entropy, in main() 139 mbedtls_entropy_free(&entropy); in main()
|
D | rsa_sign_pss.c | 43 mbedtls_entropy_context entropy; in main() local 51 mbedtls_entropy_init(&entropy); in main() 77 if ((ret = mbedtls_ctr_drbg_seed(&ctr_drbg, mbedtls_entropy_func, &entropy, in main() 152 mbedtls_entropy_free(&entropy); in main()
|
D | rsa_encrypt.c | 42 mbedtls_entropy_context entropy; in main() local 65 mbedtls_entropy_init(&entropy); in main() 68 &entropy, (const unsigned char *) pers, in main() 143 mbedtls_entropy_free(&entropy); in main()
|
D | dh_genprime.c | 50 mbedtls_entropy_context entropy; in main() local 60 mbedtls_entropy_init(&entropy); in main() 95 if ((ret = mbedtls_ctr_drbg_seed(&ctr_drbg, mbedtls_entropy_func, &entropy, in main() 156 mbedtls_entropy_free(&entropy); in main()
|
D | ecdh_curve25519.c | 37 mbedtls_entropy_context entropy; in main() local 61 mbedtls_entropy_init(&entropy); in main() 63 &entropy, in main() 184 mbedtls_entropy_free(&entropy); in main()
|
D | rsa_genkey.c | 45 mbedtls_entropy_context entropy; in main() local 61 mbedtls_entropy_init(&entropy); in main() 62 if ((ret = mbedtls_ctr_drbg_seed(&ctr_drbg, mbedtls_entropy_func, &entropy, in main() 136 mbedtls_entropy_free(&entropy); in main()
|
D | rsa_decrypt.c | 45 mbedtls_entropy_context entropy; in main() local 69 mbedtls_entropy_init(&entropy); in main() 75 &entropy, (const unsigned char *) pers, in main() 164 mbedtls_entropy_free(&entropy); in main()
|
/openthread-latest/third_party/mbedtls/repo/programs/ssl/ |
D | mini_client.c | 151 mbedtls_entropy_context entropy; in main() local 166 mbedtls_entropy_init(&entropy); in main() 176 if (mbedtls_ctr_drbg_seed(&ctr_drbg, mbedtls_entropy_func, &entropy, in main() 264 mbedtls_entropy_free(&entropy); in main()
|