Home
last modified time | relevance | path

Searched refs:entropy (Results 1 – 25 of 62) sorted by relevance

123

/mbedtls-development/tests/suites/
A Dtest_suite_ctr_drbg.function2 #include "mbedtls/entropy.h"
45 /* CTR_DRBG_Instantiate(entropy[:entropy->len], nonce, perso, <ignored>)
60 /* CTR_DRBG_Reseed(entropy[idx:idx+entropy->len],
77 /* CTR_DRBG_Reseed(entropy[idx:idx+entropy->len],
144 entropy->len, entropy,
158 entropy->len / 3, entropy,
171 entropy->len / 2, entropy,
184 entropy->len / 2, entropy,
204 memset( entropy, 0, sizeof( entropy ) );
236 memset( entropy, 0, sizeof( entropy ) );
[all …]
A Dtest_suite_random.function8 #include "mbedtls/entropy.h"
24 mbedtls_entropy_context entropy;
30 mbedtls_entropy_init( &entropy );
38 mbedtls_entropy_free( &entropy );
41 mbedtls_entropy_init( &entropy );
49 mbedtls_entropy_free( &entropy );
56 mbedtls_entropy_free( &entropy );
63 mbedtls_entropy_context entropy;
70 mbedtls_entropy_init( &entropy );
78 mbedtls_entropy_free( &entropy );
[all …]
A Dtest_suite_hmac_drbg.function39 entropy_ctx entropy;
48 entropy.len = sizeof( buf );
49 entropy.p = buf;
63 /* Init must use entropy */
190 p_entropy.p = entropy->x;
191 p_entropy.len = entropy->len;
197 memcpy( data, entropy->x, p_entropy.len );
237 p_entropy.p = entropy->x;
238 p_entropy.len = entropy->len;
269 p_entropy.p = entropy->x;
[all …]
A Dtest_suite_psa_crypto_init.data25 Custom entropy sources: all standard
28 Custom entropy sources: none
31 Fake entropy: never returns anything
34 Fake entropy: less than the block size
37 Fake entropy: not enough for a nonce
41 Fake entropy: one block eventually
45 Fake entropy: one block in two steps
49 Fake entropy: more than one block in two steps
53 Fake entropy: two blocks eventually
A Dtest_suite_psa_crypto_entropy.data28 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
A Dtest_suite_hmac_drbg.misc.data1 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
A Dtest_suite_psa_crypto_init.function4 /* Some tests in this module configure entropy sources. */
7 #include "mbedtls/entropy.h"
15 /* PSA crypto uses the HMAC_DRBG module. It reads from the entropy source twice:
16 * once for the initial entropy and once for a nonce. The nonce length is
17 * half the entropy length. For SHA-256, SHA-384 or SHA-512, the
18 * entropy length is 256 per the documentation of mbedtls_hmac_drbg_seed(),
23 * to read from the entropy source twice: once for the initial entropy
64 /* This is a modified version of mbedtls_entropy_init() from entropy.c
65 * which chooses entropy sources dynamically. */
A Dtest_suite_entropy.function2 #include "mbedtls/entropy.h"
22 * Dummy entropy source
50 * Ability to clear entropy sources to allow testing with just predefined
52 * are internal changes to how entropy sources are registered.
323 /* If the NV seed functionality is enabled, there are two entropy
371 /* If the NV seed functionality is enabled, there are two entropy
438 #error "Unsupported entropy accumulator"
448 unsigned char entropy[MBEDTLS_ENTROPY_BLOCK_SIZE];
454 memset( entropy, 0, MBEDTLS_ENTROPY_BLOCK_SIZE );
475 // Do an entropy run
[all …]
/mbedtls-development/programs/random/
A Dgen_entropy.c54 mbedtls_entropy_context entropy; in main() local
69 mbedtls_entropy_init( &entropy ); in main()
73 ret = mbedtls_entropy_func( &entropy, buf, sizeof( buf ) ); in main()
94 mbedtls_entropy_free( &entropy ); in main()
A Dgen_random_ctr_drbg.c58 mbedtls_entropy_context entropy; in main() local
75 mbedtls_entropy_init( &entropy ); in main()
76 …ret = mbedtls_ctr_drbg_seed( &ctr_drbg, mbedtls_entropy_func, &entropy, (const unsigned char *) "R… in main()
127 mbedtls_entropy_free( &entropy ); in main()
/mbedtls-development/library/
A Dpsa_crypto_random_impl.h123 mbedtls_entropy_context entropy; member
184 mbedtls_entropy_context *entropy, in mbedtls_psa_drbg_seed() argument
190 entropy, in mbedtls_psa_drbg_seed()
198 entropy, in mbedtls_psa_drbg_seed()
/mbedtls-development/programs/fuzz/
A Dfuzz_dtlsclient.c40 mbedtls_entropy_context entropy; in LLVMFuzzerTestOneInput() local
60 mbedtls_entropy_init( &entropy ); in LLVMFuzzerTestOneInput()
63 if( mbedtls_ctr_drbg_seed( &ctr_drbg, dummy_entropy, &entropy, in LLVMFuzzerTestOneInput()
114 mbedtls_entropy_free( &entropy ); in LLVMFuzzerTestOneInput()
A Dfuzz_client.c44 mbedtls_entropy_context entropy; in LLVMFuzzerTestOneInput() local
77 mbedtls_entropy_init( &entropy ); in LLVMFuzzerTestOneInput()
79 if( mbedtls_ctr_drbg_seed( &ctr_drbg, dummy_entropy, &entropy, in LLVMFuzzerTestOneInput()
162 mbedtls_entropy_free( &entropy ); in LLVMFuzzerTestOneInput()
A Dfuzz_dtlsserver.c41 mbedtls_entropy_context entropy; in LLVMFuzzerTestOneInput() local
69 mbedtls_entropy_init( &entropy ); in LLVMFuzzerTestOneInput()
72 if( mbedtls_ctr_drbg_seed( &ctr_drbg, dummy_entropy, &entropy, in LLVMFuzzerTestOneInput()
141 mbedtls_entropy_free( &entropy ); in LLVMFuzzerTestOneInput()
A Dfuzz_server.c44 mbedtls_entropy_context entropy; in LLVMFuzzerTestOneInput() local
60 mbedtls_entropy_init( &entropy ); in LLVMFuzzerTestOneInput()
62 if( mbedtls_ctr_drbg_seed( &ctr_drbg, dummy_entropy, &entropy, in LLVMFuzzerTestOneInput()
178 mbedtls_entropy_free( &entropy ); in LLVMFuzzerTestOneInput()
/mbedtls-development/programs/pkey/
A Dpk_decrypt.c66 mbedtls_entropy_context entropy; in main() local
74 mbedtls_entropy_init( &entropy ); in main()
94 &entropy, (const unsigned char *) pers, in main()
154 mbedtls_entropy_free( &entropy ); in main()
A Dpk_encrypt.c66 mbedtls_entropy_context entropy; in main() local
73 mbedtls_entropy_init( &entropy ); in main()
91 &entropy, (const unsigned char *) pers, in main()
157 mbedtls_entropy_free( &entropy ); in main()
A Dpk_sign.c63 mbedtls_entropy_context entropy; in main() local
71 mbedtls_entropy_init( &entropy ); in main()
89 if( ( ret = mbedtls_ctr_drbg_seed( &ctr_drbg, mbedtls_entropy_func, &entropy, in main()
157 mbedtls_entropy_free( &entropy ); in main()
A Drsa_sign_pss.c64 mbedtls_entropy_context entropy; in main() local
72 mbedtls_entropy_init( &entropy ); in main()
90 if( ( ret = mbedtls_ctr_drbg_seed( &ctr_drbg, mbedtls_entropy_func, &entropy, in main()
173 mbedtls_entropy_free( &entropy ); in main()
A Drsa_encrypt.c64 mbedtls_entropy_context entropy; in main() local
88 mbedtls_entropy_init( &entropy ); in main()
91 &entropy, (const unsigned char *) pers, in main()
172 mbedtls_entropy_free( &entropy ); in main()
A Ddh_genprime.c72 mbedtls_entropy_context entropy; in main() local
82 mbedtls_entropy_init( &entropy ); in main()
119 if( ( ret = mbedtls_ctr_drbg_seed( &ctr_drbg, mbedtls_entropy_func, &entropy, in main()
187 mbedtls_entropy_free( &entropy ); in main()
A Drsa_genkey.c66 mbedtls_entropy_context entropy; in main() local
82 mbedtls_entropy_init( &entropy ); in main()
83 if( ( ret = mbedtls_ctr_drbg_seed( &ctr_drbg, mbedtls_entropy_func, &entropy, in main()
162 mbedtls_entropy_free( &entropy ); in main()
A Decdsa.c103 mbedtls_entropy_context entropy; in main() local
136 mbedtls_entropy_init( &entropy ); in main()
137 if( ( ret = mbedtls_ctr_drbg_seed( &ctr_drbg, mbedtls_entropy_func, &entropy, in main()
243 mbedtls_entropy_free( &entropy ); in main()
A Drsa_decrypt.c66 mbedtls_entropy_context entropy; in main() local
91 mbedtls_entropy_init( &entropy ); in main()
97 &entropy, (const unsigned char *) pers, in main()
193 mbedtls_entropy_free( &entropy ); in main()
/mbedtls-development/programs/ssl/
A Dmini_client.c173 mbedtls_entropy_context entropy; in main() local
189 mbedtls_entropy_init( &entropy ); in main()
190 if( mbedtls_ctr_drbg_seed( &ctr_drbg, mbedtls_entropy_func, &entropy, in main()
288 mbedtls_entropy_free( &entropy ); in main()

Completed in 17 milliseconds

123