/mbedtls-development/library/ |
A D | chacha20.c | 86 state[a] += state[b]; in chacha20_quarter_round() 87 state[d] ^= state[a]; in chacha20_quarter_round() 88 state[d] = ROTL32( state[d], 16 ); in chacha20_quarter_round() 91 state[c] += state[d]; in chacha20_quarter_round() 92 state[b] ^= state[c]; in chacha20_quarter_round() 96 state[a] += state[b]; in chacha20_quarter_round() 97 state[d] ^= state[a]; in chacha20_quarter_round() 98 state[d] = ROTL32( state[d], 8 ); in chacha20_quarter_round() 101 state[c] += state[d]; in chacha20_quarter_round() 102 state[b] ^= state[c]; in chacha20_quarter_round() [all …]
|
A D | sha512.c | 110 ctx->state[0] = UL64(0x6A09E667F3BCC908); in mbedtls_sha512_starts() 111 ctx->state[1] = UL64(0xBB67AE8584CAA73B); in mbedtls_sha512_starts() 112 ctx->state[2] = UL64(0x3C6EF372FE94F82B); in mbedtls_sha512_starts() 113 ctx->state[3] = UL64(0xA54FF53A5F1D36F1); in mbedtls_sha512_starts() 114 ctx->state[4] = UL64(0x510E527FADE682D1); in mbedtls_sha512_starts() 115 ctx->state[5] = UL64(0x9B05688C2B3E6C1F); in mbedtls_sha512_starts() 116 ctx->state[6] = UL64(0x1F83D9ABFB41BD6B); in mbedtls_sha512_starts() 117 ctx->state[7] = UL64(0x5BE0CD19137E2179); in mbedtls_sha512_starts() 125 ctx->state[0] = UL64(0xCBBB9D5DC1059ED8); in mbedtls_sha512_starts() 226 local.A[i] = ctx->state[i]; in mbedtls_internal_sha512_process() [all …]
|
A D | cmac.c | 220 mbedtls_platform_zeroize( cmac_ctx->state, sizeof( cmac_ctx->state ) ); in mbedtls_cipher_cmac_starts() 229 unsigned char *state; in mbedtls_cipher_cmac_update() local 239 state = ctx->cmac_ctx->state; in mbedtls_cipher_cmac_update() 250 cmac_xor_block( state, cmac_ctx->unprocessed_block, state, block_size ); in mbedtls_cipher_cmac_update() 252 if( ( ret = mbedtls_cipher_update( ctx, state, block_size, state, in mbedtls_cipher_cmac_update() 270 cmac_xor_block( state, input, state, block_size ); in mbedtls_cipher_cmac_update() 272 if( ( ret = mbedtls_cipher_update( ctx, state, block_size, state, in mbedtls_cipher_cmac_update() 297 unsigned char *state, *last_block; in mbedtls_cipher_cmac_finish() local 310 state = cmac_ctx->state; in mbedtls_cipher_cmac_finish() 331 cmac_xor_block( state, M_last, state, block_size ); in mbedtls_cipher_cmac_finish() [all …]
|
A D | sha256.c | 96 ctx->state[0] = 0x6A09E667; in mbedtls_sha256_starts() 97 ctx->state[1] = 0xBB67AE85; in mbedtls_sha256_starts() 98 ctx->state[2] = 0x3C6EF372; in mbedtls_sha256_starts() 99 ctx->state[3] = 0xA54FF53A; in mbedtls_sha256_starts() 100 ctx->state[4] = 0x510E527F; in mbedtls_sha256_starts() 101 ctx->state[5] = 0x9B05688C; in mbedtls_sha256_starts() 102 ctx->state[6] = 0x1F83D9AB; in mbedtls_sha256_starts() 103 ctx->state[7] = 0x5BE0CD19; in mbedtls_sha256_starts() 109 ctx->state[0] = 0xC1059ED8; in mbedtls_sha256_starts() 110 ctx->state[1] = 0x367CD507; in mbedtls_sha256_starts() [all …]
|
A D | ccm.c | 123 ctx->state |= CCM_STATE__ERROR; in mbedtls_ccm_crypt() 136 ctx->state = CCM_STATE__CLEAR; in mbedtls_ccm_clear_state() 150 if( !(ctx->state & CCM_STATE__STARTED) || !(ctx->state & CCM_STATE__LENGHTS_SET) ) in ccm_calculate_first_block_if_ready() 189 ctx->state |= CCM_STATE__ERROR; in ccm_calculate_first_block_if_ready() 196 ctx->state |= CCM_STATE__ERROR; in ccm_calculate_first_block_if_ready() 236 ctx->state |= CCM_STATE__STARTED; in mbedtls_ccm_starts() 263 ctx->state |= CCM_STATE__LENGHTS_SET; in mbedtls_ccm_set_lengths() 275 if( ctx->state & CCM_STATE__ERROR ) in mbedtls_ccm_update_ad() 324 ctx->state |= CCM_STATE__ERROR; in mbedtls_ccm_update_ad() 351 if( ctx->state & CCM_STATE__ERROR ) in mbedtls_ccm_update() [all …]
|
A D | chachapoly.c | 100 ctx->state = CHACHAPOLY_STATE_INIT; in mbedtls_chachapoly_init() 113 ctx->state = CHACHAPOLY_STATE_INIT; in mbedtls_chachapoly_free() 160 ctx->state = CHACHAPOLY_STATE_AAD; in mbedtls_chachapoly_starts() 176 if( ctx->state != CHACHAPOLY_STATE_AAD ) in mbedtls_chachapoly_update_aad() 194 if( ( ctx->state != CHACHAPOLY_STATE_AAD ) && in mbedtls_chachapoly_update() 195 ( ctx->state != CHACHAPOLY_STATE_CIPHERTEXT ) ) in mbedtls_chachapoly_update() 200 if( ctx->state == CHACHAPOLY_STATE_AAD ) in mbedtls_chachapoly_update() 202 ctx->state = CHACHAPOLY_STATE_CIPHERTEXT; in mbedtls_chachapoly_update() 243 if( ctx->state == CHACHAPOLY_STATE_INIT ) in mbedtls_chachapoly_finish() 248 if( ctx->state == CHACHAPOLY_STATE_AAD ) in mbedtls_chachapoly_finish() [all …]
|
A D | ripemd160.c | 74 ctx->state[0] = 0x67452301; in mbedtls_ripemd160_starts() 75 ctx->state[1] = 0xEFCDAB89; in mbedtls_ripemd160_starts() 76 ctx->state[2] = 0x98BADCFE; in mbedtls_ripemd160_starts() 77 ctx->state[3] = 0x10325476; in mbedtls_ripemd160_starts() 78 ctx->state[4] = 0xC3D2E1F0; in mbedtls_ripemd160_starts() 112 local.A = local.Ap = ctx->state[0]; in mbedtls_internal_ripemd160_process() 268 ctx->state[1] = ctx->state[2] + local.D + local.Ep; in mbedtls_internal_ripemd160_process() 269 ctx->state[2] = ctx->state[3] + local.E + local.Ap; in mbedtls_internal_ripemd160_process() 270 ctx->state[3] = ctx->state[4] + local.A + local.Bp; in mbedtls_internal_ripemd160_process() 271 ctx->state[4] = ctx->state[0] + local.B + local.Cp; in mbedtls_internal_ripemd160_process() [all …]
|
A D | md5.c | 73 ctx->state[0] = 0x67452301; in mbedtls_md5_starts() 74 ctx->state[1] = 0xEFCDAB89; in mbedtls_md5_starts() 75 ctx->state[2] = 0x98BADCFE; in mbedtls_md5_starts() 76 ctx->state[3] = 0x10325476; in mbedtls_md5_starts() 117 local.A = ctx->state[0]; in mbedtls_internal_md5_process() 118 local.B = ctx->state[1]; in mbedtls_internal_md5_process() 119 local.C = ctx->state[2]; in mbedtls_internal_md5_process() 120 local.D = ctx->state[3]; in mbedtls_internal_md5_process() 206 ctx->state[0] += local.A; in mbedtls_internal_md5_process() 207 ctx->state[1] += local.B; in mbedtls_internal_md5_process() [all …]
|
A D | sha1.c | 85 ctx->state[0] = 0x67452301; in mbedtls_sha1_starts() 86 ctx->state[1] = 0xEFCDAB89; in mbedtls_sha1_starts() 87 ctx->state[2] = 0x98BADCFE; in mbedtls_sha1_starts() 88 ctx->state[3] = 0x10325476; in mbedtls_sha1_starts() 89 ctx->state[4] = 0xC3D2E1F0; in mbedtls_sha1_starts() 141 local.A = ctx->state[0]; in mbedtls_internal_sha1_process() 142 local.B = ctx->state[1]; in mbedtls_internal_sha1_process() 143 local.C = ctx->state[2]; in mbedtls_internal_sha1_process() 144 local.D = ctx->state[3]; in mbedtls_internal_sha1_process() 145 local.E = ctx->state[4]; in mbedtls_internal_sha1_process() [all …]
|
A D | ecdsa.c | 67 } state; member 77 ctx->state = ecdsa_ver_init; in ecdsa_restart_ver_init() 107 } state; member 119 ctx->state = ecdsa_sig_init; in ecdsa_restart_sig_init() 144 } state; member 153 ctx->state = ecdsa_det_init; in ecdsa_restart_det_init() 289 if( rs_ctx->sig->state == ecdsa_sig_mul ) in ecdsa_sign_restartable() 291 if( rs_ctx->sig->state == ecdsa_sig_modn ) in ecdsa_sign_restartable() 336 rs_ctx->sig->state = ecdsa_sig_modn; in ecdsa_sign_restartable() 471 rs_ctx->det->state = ecdsa_det_sign; in ecdsa_sign_det_restartable() [all …]
|
A D | ssl_ticket.c | 209 unsigned char *state = state_len_bytes + TICKET_CRYPT_LEN_BYTES; in mbedtls_ssl_ticket_write() local 240 state, end - state, in mbedtls_ssl_ticket_write() 253 state, clear_len, in mbedtls_ssl_ticket_write() 254 state, end - state, &ciph_len, in mbedtls_ssl_ticket_write()
|
A D | ecp.c | 164 } state; member 176 ctx->state = ecp_rsm_init; in ecp_restart_rsm_init() 213 } state; member 223 ctx->state = ecp_rsma_mul1; in ecp_restart_ma_init() 1736 rs_ctx->rsm->state = ecp_rsm_pre_dbl; in ecp_precompute_comb() 2684 rs_ctx->ma->state = ecp_rsma_mul2; in mbedtls_ecp_muladd_restartable() 2697 rs_ctx->ma->state = ecp_rsma_add; in mbedtls_ecp_muladd_restartable() 2705 rs_ctx->ma->state = ecp_rsma_norm; in mbedtls_ecp_muladd_restartable() 3238 static uint32_t state = 42; in self_test_rng() local 3244 state = state * 1664525u + 1013904223u; in self_test_rng() [all …]
|
A D | ssl_cli.c | 1322 ssl->state++; in ssl_write_client_hello() 2121 ssl->state++; in ssl_parse_server_hello() 2883 ssl->state++; in ssl_parse_server_key_exchange() 2906 ssl->state++; in ssl_parse_server_key_exchange() 3237 ssl->state++; in ssl_parse_server_key_exchange() 3255 ssl->state++; in ssl_parse_certificate_request() 3277 ssl->state++; in ssl_parse_certificate_request() 3297 ssl->state++; in ssl_parse_certificate_request() 3461 ssl->state++; in ssl_parse_server_hello_done() 3876 ssl->state++; in ssl_write_client_key_exchange() [all …]
|
A D | ssl_tls13_server.c | 33 MBEDTLS_SSL_DEBUG_MSG( 2, ( "tls1_3 server state: %d", ssl->state ) ); in mbedtls_ssl_tls13_handshake_server_step()
|
A D | ssl_srv.c | 1904 ssl->state++; in ssl_parse_client_hello() 2518 ssl->state++; in ssl_write_server_hello() 2667 ssl->state++; in ssl_write_certificate_request() 2689 ssl->state++; in ssl_write_certificate_request() 3271 ssl->state++; in ssl_write_server_key_exchange() 3328 ssl->state++; in ssl_write_server_key_exchange() 3350 ssl->state++; in ssl_write_server_hello_done() 3982 ssl->state++; in ssl_parse_client_key_exchange() 4000 ssl->state++; in ssl_parse_certificate_verify() 4028 ssl->state++; in ssl_parse_certificate_verify() [all …]
|
/mbedtls-development/tests/scripts/ |
A D | check_names.py | 427 state = states.OUTSIDE_KEYWORD 433 if (state == states.OUTSIDE_KEYWORD and 435 state = states.IN_BRACES 436 elif (state == states.OUTSIDE_KEYWORD and 438 state = states.IN_BETWEEN 439 elif (state == states.IN_BETWEEN and 441 state = states.IN_BRACES 442 elif (state == states.IN_BRACES and 444 state = states.OUTSIDE_KEYWORD 445 elif (state == states.IN_BRACES and
|
A D | generate_test_code.py | 673 state = __state_read_name 684 if state == __state_read_args: 691 if state == __state_read_name: 694 state = __state_read_args 695 elif state == __state_read_args: 713 state = __state_read_name 714 if state == __state_read_args:
|
/mbedtls-development/docs/architecture/testing/ |
A D | psa-storage-format-testing.md | 23 …state of the storage after the key is created. The test case creates a key as indicated by the par… 27 … version W ≥ V, it creates and reads back a storage state which is known to be identical to the st… 43 The PSA subsystem provides storage on top of the PSA trusted storage interface. The state of the st… 46 * The [random generator injected seed or state file](#random-generator-state) (`PSA_CRYPTO_ITS_RAND… 48 * [Driver state files](#driver-state-files). 109 ## Random generator state 113 ## Driver state files
|
/mbedtls-development/tests/suites/ |
A D | test_suite_psa_crypto_init.function | 42 fake_entropy_state_t *state = state_arg; 45 if( state->step >= state->max_steps ) 48 *olen = MIN( len, state->length_sequence[state->step] ); 51 ++state->step;
|
/mbedtls-development/include/mbedtls/ |
A D | ripemd160.h | 45 uint32_t MBEDTLS_PRIVATE(state)[5]; /*!< intermediate digest state */
|
A D | md5.h | 54 uint32_t MBEDTLS_PRIVATE(state)[4]; /*!< intermediate digest state */
|
A D | sha1.h | 60 uint32_t MBEDTLS_PRIVATE(state)[5]; /*!< The intermediate digest state. */
|
A D | chacha20.h | 52 uint32_t MBEDTLS_PRIVATE(state)[16]; /*! The state (before round operations). */
|
A D | sha256.h | 55 uint32_t MBEDTLS_PRIVATE(state)[8]; /*!< The intermediate digest state. */
|
A D | sha512.h | 54 uint64_t MBEDTLS_PRIVATE(state)[8]; /*!< The intermediate digest state. */
|