Home
last modified time | relevance | path

Searched refs:iv (Results 1 – 25 of 42) sorted by relevance

12

/trusted-firmware-m-3.6.0/lib/ext/cryptocell-312-runtime/codesafe/src/mbedtls_api/
Dccm_alt.c57 const unsigned char *iv, in mbedtls_ccm_encrypt_and_tag() argument
66 …return mbedtls_ccm_encrypt_and_tag_int(ctx, length, iv, iv_len, add, add_len, input, output, tag, … in mbedtls_ccm_encrypt_and_tag()
74 const unsigned char *iv, in mbedtls_ccm_auth_decrypt() argument
85 …return mbedtls_ccm_auth_decrypt_int( ctx, length, iv, iv_len, add, add_len, input, output, tag, ta… in mbedtls_ccm_auth_decrypt()
90 const unsigned char *iv, in mbedtls_ccm_star_encrypt_and_tag() argument
99 …return mbedtls_ccm_encrypt_and_tag_int(ctx, length, iv, iv_len, add, add_len, input, output, tag, … in mbedtls_ccm_star_encrypt_and_tag()
104 const unsigned char *iv, in mbedtls_ccm_star_auth_decrypt() argument
113 …return mbedtls_ccm_auth_decrypt_int(ctx, length, iv, iv_len, add, add_len, input, output, tag, tag… in mbedtls_ccm_star_auth_decrypt()
119 const unsigned char *iv, in mbedtls_ccm_starts() argument
124 CC_UNUSED_PARAM(iv); in mbedtls_ccm_starts()
Daes_alt.c217 unsigned char iv[AES_IV_SIZE], in mbedtls_aes_crypt_cbc()
232 if (NULL == ctx || NULL == input || NULL == output || NULL == iv) in mbedtls_aes_crypt_cbc()
260 CC_PalMemCopy(aesCtx->ivBuf, iv, AES_IV_SIZE); in mbedtls_aes_crypt_cbc()
278 CC_PalMemCopy(iv, aesCtx->ivBuf, AES_IV_SIZE); in mbedtls_aes_crypt_cbc()
292 unsigned char iv[AES_IV_SIZE], in mbedtls_aes_crypt_cfb128()
300 CC_UNUSED_PARAM(iv); in mbedtls_aes_crypt_cfb128()
312 unsigned char iv[AES_IV_SIZE], in mbedtls_aes_crypt_cfb8()
319 CC_UNUSED_PARAM(iv); in mbedtls_aes_crypt_cfb8()
334 unsigned char iv[AES_BLOCK_SIZE], in aes_crypt_ctr_ofb()
348 if (NULL == ctx || NULL == iv || NULL == input || NULL == output) in aes_crypt_ctr_ofb()
[all …]
Dgcm_alt.c464 const unsigned char *iv, in gcm_crypt_and_tag() argument
483 iv, iv_len, in gcm_crypt_and_tag()
493 rc = gcm_process_j0(ctx, iv); in gcm_crypt_and_tag()
535 const unsigned char *iv, in mbedtls_gcm_crypt_and_tag() argument
547 iv, iv_len, in mbedtls_gcm_crypt_and_tag()
556 const unsigned char *iv, in mbedtls_gcm_auth_decrypt() argument
568 iv, iv_len, in mbedtls_gcm_auth_decrypt()
580 const unsigned char *iv, in mbedtls_gcm_starts() argument
585 CC_UNUSED_PARAM(iv); in mbedtls_gcm_starts()
/trusted-firmware-m-3.6.0/lib/ext/cryptocell-312-runtime/host/src/tests/integration_cc3x/runtime_integration_test/tests/
Drun_integration_aes.c67 uint8_t iv[AES_IV_SIZE]; in runIt_aesOfbTest() local
83 memcpy(iv, IV, sizeof(iv)); in runIt_aesOfbTest()
91 RUNIT_ASSERT_API(mbedtls_aes_crypt_ofb(&ctx, sizeof(buf), 0, iv, buf, buf) == 0); in runIt_aesOfbTest()
102 memcpy(iv, IV, sizeof(iv)); in runIt_aesOfbTest()
110 RUNIT_ASSERT_API(mbedtls_aes_crypt_ofb(&ctx, sizeof(buf), 0, iv, buf, buf) == 0); in runIt_aesOfbTest()
120 …ESULT_W_PARAMS(TEST_NAME, "KEY[%ub] IV[%uB] PLAIN[%uB]", sizeof(key) * 8, sizeof(iv), sizeof(buf)); in runIt_aesOfbTest()
277 uint8_t iv[AES_IV_SIZE]; in runIt_aesCbcTest() local
291 memcpy(iv, IV, sizeof(iv)); in runIt_aesCbcTest()
295 RUNIT_PRINT_BUF(iv, AES_IV_SIZE, "iv_enc"); in runIt_aesCbcTest()
301 …RUNIT_ASSERT_API(mbedtls_aes_crypt_cbc(&ctx, MBEDTLS_AES_ENCRYPT, sizeof(buf), iv, buf, buf) == 0); in runIt_aesCbcTest()
[all …]
Drun_integration_gcm.c49 static const uint8_t iv[] = {0xCA,0xFE,0xBA,0xBE,0xFA,0xCE,0xDB,0xAD,0xDE,0xCA,0xF8,0x88}; in runIt_gcmProfiling() local
50 static const size_t iv_len = sizeof(iv); in runIt_gcmProfiling()
72 ALLOC_AND_COPY(ivBufPtr, pIvBuf, iv, iv_len); in runIt_gcmProfiling()
124 static const uint8_t iv[] = {0xCA,0xFE,0xBA,0xBE,0xFA,0xCE,0xDB,0xAD,0xDE,0xCA,0xF8,0x88}; in runIt_gcm() local
125 static const size_t iv_len = sizeof(iv); in runIt_gcm()
150 ALLOC_AND_COPY(ivBufPtr, pIvBuf, iv, iv_len); in runIt_gcm()
/trusted-firmware-m-3.6.0/platform/ext/target/stm/common/hal/accelerator/
Daes_alt.c373 unsigned char iv[16], in mbedtls_aes_crypt_cbc()
383 AES_VALIDATE_RET( iv != NULL ); in mbedtls_aes_crypt_cbc()
402 SWAP_B8_TO_B32(iv_32B[0],iv,0); in mbedtls_aes_crypt_cbc()
403 SWAP_B8_TO_B32(iv_32B[1],iv,4); in mbedtls_aes_crypt_cbc()
404 SWAP_B8_TO_B32(iv_32B[2],iv,8); in mbedtls_aes_crypt_cbc()
405 SWAP_B8_TO_B32(iv_32B[3],iv,12); in mbedtls_aes_crypt_cbc()
420 SWAP_B32_TO_B8(ctx->hcryp_aes.Instance->IVR3,iv,0); in mbedtls_aes_crypt_cbc()
421 SWAP_B32_TO_B8(ctx->hcryp_aes.Instance->IVR2,iv,4); in mbedtls_aes_crypt_cbc()
422 SWAP_B32_TO_B8(ctx->hcryp_aes.Instance->IVR1,iv,8); in mbedtls_aes_crypt_cbc()
423 SWAP_B32_TO_B8(ctx->hcryp_aes.Instance->IVR0,iv,12); in mbedtls_aes_crypt_cbc()
[all …]
Dccm_alt.c171 const unsigned char *iv, size_t iv_len, in ccm_auth_crypt() argument
236 memcpy( b0 + 1, iv, iv_len ); in ccm_auth_crypt()
374 const unsigned char *iv, size_t iv_len, in mbedtls_ccm_star_encrypt_and_tag() argument
380 CCM_VALIDATE_RET( iv != NULL ); in mbedtls_ccm_star_encrypt_and_tag()
385 return( ccm_auth_crypt( ctx, CCM_ENCRYPT, length, iv, iv_len, in mbedtls_ccm_star_encrypt_and_tag()
390 const unsigned char *iv, size_t iv_len, in mbedtls_ccm_encrypt_and_tag() argument
396 CCM_VALIDATE_RET( iv != NULL ); in mbedtls_ccm_encrypt_and_tag()
404 return( mbedtls_ccm_star_encrypt_and_tag( ctx, length, iv, iv_len, add, in mbedtls_ccm_encrypt_and_tag()
412 const unsigned char *iv, size_t iv_len, in mbedtls_ccm_star_auth_decrypt() argument
423 CCM_VALIDATE_RET( iv != NULL ); in mbedtls_ccm_star_auth_decrypt()
[all …]
Dgcm_alt.c88 const unsigned char *iv,
346 const unsigned char *iv, in gcm_starts() argument
358 GCM_VALIDATE_RET( iv != NULL ); in gcm_starts()
390 memcpy( ctx->y, iv, iv_len ); in gcm_starts()
545 const unsigned char *iv, in mbedtls_gcm_crypt_and_tag() argument
557 GCM_VALIDATE_RET( iv != NULL ); in mbedtls_gcm_crypt_and_tag()
563 if( ( ret = gcm_starts( ctx, mode, iv, iv_len, add, add_len ) ) != 0 ) in mbedtls_gcm_crypt_and_tag()
577 const unsigned char *iv, in mbedtls_gcm_auth_decrypt() argument
593 GCM_VALIDATE_RET( iv != NULL ); in mbedtls_gcm_auth_decrypt()
600 iv, iv_len, add, add_len, in mbedtls_gcm_auth_decrypt()
[all …]
/trusted-firmware-m-3.6.0/platform/ext/accelerator/cc312/cc312-rom/
Dcc3xx_chacha.c21 static void set_iv(const uint32_t *iv) in set_iv() argument
24 P_CC3XX->chacha.chacha_block_cnt_msb = iv[0]; in set_iv()
25 iv += 1; in set_iv()
27 P_CC3XX->chacha.chacha_iv[0] = iv[0]; in set_iv()
28 P_CC3XX->chacha.chacha_iv[1] = iv[1]; in set_iv()
31 static void get_iv(uint32_t *iv) in get_iv() argument
34 iv[0] = P_CC3XX->chacha.chacha_block_cnt_msb; in get_iv()
35 iv += 1; in get_iv()
37 iv[0] = P_CC3XX->chacha.chacha_iv[0]; in get_iv()
38 iv[1] = P_CC3XX->chacha.chacha_iv[1]; in get_iv()
[all …]
Dcc3xx_aes.c160 static void set_iv(const uint32_t *iv) in set_iv() argument
162 P_CC3XX->aes.aes_iv_0[0] = iv[0]; in set_iv()
163 P_CC3XX->aes.aes_iv_0[1] = iv[1]; in set_iv()
164 P_CC3XX->aes.aes_iv_0[2] = iv[2]; in set_iv()
165 P_CC3XX->aes.aes_iv_0[3] = iv[3]; in set_iv()
176 static void get_iv(uint32_t *iv) in get_iv() argument
178 iv[0] = P_CC3XX->aes.aes_iv_0[0]; in get_iv()
179 iv[1] = P_CC3XX->aes.aes_iv_0[1]; in get_iv()
180 iv[2] = P_CC3XX->aes.aes_iv_0[2]; in get_iv()
181 iv[3] = P_CC3XX->aes.aes_iv_0[3]; in get_iv()
[all …]
Dcc3xx_hash.c85 const uint32_t *iv; in cc3xx_hash_init() local
97 iv = iv_sha224; in cc3xx_hash_init()
103 iv = iv_sha256; in cc3xx_hash_init()
109 iv = iv_sha1; in cc3xx_hash_init()
118 set_hash_h(iv, iv_len); in cc3xx_hash_init()
Dcc3xx_chacha.h47 uint32_t iv[3]; member
71 const uint32_t *iv, size_t iv_len);
/trusted-firmware-m-3.6.0/lib/ext/cryptocell-312-runtime/codesafe/src/psa_driver_api/src/
Dcc3xx_psa_cipher.c199 const uint8_t *iv, size_t iv_length) in cc3xx_cipher_set_iv() argument
211 uint8_t *iv_pnt = (uint8_t *)iv; in cc3xx_cipher_set_iv()
221 counter = (iv[3] << 24) | (iv[2] << 16) | (iv[1] << 8) | iv[0]; in cc3xx_cipher_set_iv()
251 CC_PalMemCopy(operation->iv, iv, iv_length); in cc3xx_cipher_set_iv()
329 operation->iv, in cc3xx_cipher_update()
367 operation->iv, in cc3xx_cipher_update()
384 operation->iv, in cc3xx_cipher_update()
400 operation->iv, in cc3xx_cipher_update()
416 operation->iv, in cc3xx_cipher_update()
527 operation->iv, in cc3xx_cipher_finish()
[all …]
Dcc3xx_internal_aes.c111 uint8_t iv[AES_IV_SIZE], in cc3xx_aes_crypt()
123 if (NULL == ctx || NULL == input || NULL == output || NULL == iv) { in cc3xx_aes_crypt()
136 CC_PalMemCopy(ctx->ivBuf, iv, AES_IV_SIZE); in cc3xx_aes_crypt()
153 CC_PalMemCopy(iv, ctx->ivBuf, AES_IV_SIZE); in cc3xx_aes_crypt()
/trusted-firmware-m-3.6.0/secure_fw/partitions/protected_storage/crypto/
Dps_crypto_interface.c134 (void)memcpy(ps_crypto_iv_buf, crypto->ref.iv, PS_IV_LEN_BYTES); in ps_crypto_set_iv()
186 (void)memcpy(crypto->ref.iv, ps_crypto_iv_buf, PS_IV_LEN_BYTES); in ps_crypto_get_iv()
203 crypto->ref.iv, PS_IV_LEN_BYTES, in ps_crypto_encrypt_and_tag()
234 crypto->ref.iv, PS_IV_LEN_BYTES, in ps_crypto_auth_and_decrypt()
253 crypto->ref.iv, PS_IV_LEN_BYTES, in ps_crypto_generate_auth_tag()
272 crypto->ref.iv, PS_IV_LEN_BYTES, in ps_crypto_authenticate()
/trusted-firmware-m-3.6.0/lib/ext/cryptocell-312-runtime/codesafe/src/crypto_api/cc3x_sym/api/
Dmbedtls_aes_ext_dma.c213 unsigned char * iv, in mbedtls_aes_ext_dma_set_iv() argument
233 if (iv == NULL || iv_size != CC_AES_IV_SIZE_IN_BYTES) { in mbedtls_aes_ext_dma_set_iv()
238 CC_PalMemCopy((uint8_t *)ivBuff, iv, CC_AES_IV_SIZE_IN_BYTES); in mbedtls_aes_ext_dma_set_iv()
257 unsigned char *iv, in mbedtls_aes_ext_dma_finish() argument
278 (iv == NULL || iv_size != CC_AES_IV_SIZE_IN_BYTES) ) { in mbedtls_aes_ext_dma_finish()
287 CC_PalMemCopy(iv, (uint8_t *)ivBuff, CC_AES_IV_SIZE_IN_BYTES); in mbedtls_aes_ext_dma_finish()
Dmbedtls_ccm_internal.h27 const unsigned char *iv,
39 const unsigned char *iv,
/trusted-firmware-m-3.6.0/platform/ext/target/nxp/common/Native_Driver/drivers/
Dfsl_hashcrypt.h286 const uint8_t iv[16]);
304 const uint8_t iv[16]);
360 const uint8_t iv[HASHCRYPT_AES_BLOCK_SIZE]);
379 const uint8_t iv[16]);
398 const uint8_t iv[16]);
/trusted-firmware-m-3.6.0/lib/ext/cryptocell-312-runtime/shared/include/crypto_api/cc3x/
Dmbedtls_aes_ext_dma.h77 unsigned char *iv,
108 unsigned char *iv,
/trusted-firmware-m-3.6.0/platform/ext/target/arm/rss/common/provisioning/
Dbl1_provisioning.c121 (uint32_t *)cm_encrypted_bundle->iv, in provision_assembly_and_test()
122 sizeof(cm_encrypted_bundle->iv)); in provision_assembly_and_test()
130 cc3xx_aes_set_data_len(offsetof(struct cm_provisioning_bundle, iv) - in provision_assembly_and_test()
195 (uint32_t *)dm_encrypted_bundle->iv, in provision_psa_rot()
196 sizeof(dm_encrypted_bundle->iv)); in provision_psa_rot()
204 cc3xx_aes_set_data_len(offsetof(struct dm_provisioning_bundle, iv) - in provision_psa_rot()
/trusted-firmware-m-3.6.0/secure_fw/partitions/protected_storage/
Dps_encrypted_object.c170 (void *)obj->header.crypto.ref.iv, in ps_encrypted_object_read()
181 decrypt_size = data_length - sizeof(obj->header.crypto.ref.iv); in ps_encrypted_object_read()
210 wrt_size += sizeof(obj->header.crypto.ref.iv); in ps_encrypted_object_write()
215 return psa_its_set(fid, wrt_size, (const void *)obj->header.crypto.ref.iv, in ps_encrypted_object_write()
/trusted-firmware-m-3.6.0/secure_fw/partitions/crypto/
Dcrypto_cipher.c117 unsigned char *iv = out_vec[0].base; in tfm_crypto_cipher_interface() local
120 status = psa_cipher_generate_iv(operation, iv, iv_size, &out_vec[0].len); in tfm_crypto_cipher_interface()
128 const unsigned char *iv = in_vec[1].base; in tfm_crypto_cipher_interface() local
131 return psa_cipher_set_iv(operation, iv, iv_length); in tfm_crypto_cipher_interface()
/trusted-firmware-m-3.6.0/platform/ext/target/arm/rss/common/provisioning/bundle_common/
Drss_provisioning_bundle.h46 uint32_t iv[3]; member
76 uint32_t iv[3]; member
/trusted-firmware-m-3.6.0/lib/ext/cryptocell-312-runtime/codesafe/src/psa_driver_api/include/
Dcc3xx_psa_cipher.h84 const uint8_t *iv, size_t iv_length);
152 const uint8_t *iv,
/trusted-firmware-m-3.6.0/lib/ext/t_cose/src/
Dt_cose_parameters.c478 if(!q_useful_buf_c_is_null_or_empty(returned_parameters->iv)) { in parse_cose_header_parameters()
482 returned_parameters->iv = item.val.string; in parse_cose_header_parameters()
660 if(!q_useful_buf_c_is_null_or_empty(protected->iv)) { in check_and_copy_parameters()
661 if( !q_useful_buf_c_is_null_or_empty(unprotected->iv)) { in check_and_copy_parameters()
666 returned_params->iv = protected->iv; in check_and_copy_parameters()

12