/optee_os-3.20.0/core/lib/libtomcrypt/ |
A D | aes.c | 14 void *enc_key, size_t enc_keylen, in crypto_aes_expand_enc_key() argument 18 return crypto_accel_aes_expand_keys(key, key_len, enc_key, NULL, in crypto_aes_expand_enc_key() 29 memcpy(enc_key, skey.rijndael.eK, sizeof(skey.rijndael.eK)); in crypto_aes_expand_enc_key() 35 void crypto_aes_enc_block(const void *enc_key, size_t enc_keylen __maybe_unused, in crypto_aes_enc_block() argument 39 crypto_accel_aes_ecb_enc(dst, src, enc_key, rounds, 1); in crypto_aes_enc_block() 44 memcpy(skey.rijndael.eK, enc_key, sizeof(skey.rijndael.eK)); in crypto_aes_enc_block()
|
/optee_os-3.20.0/lib/libmbedtls/core/ |
A D | aes.c | 17 void *enc_key, size_t enc_keylen, in crypto_aes_expand_enc_key() argument 21 return crypto_accel_aes_expand_keys(key, key_len, enc_key, NULL, in crypto_aes_expand_enc_key() 33 memcpy(enc_key, ctx.buf, enc_keylen); in crypto_aes_expand_enc_key() 40 void crypto_aes_enc_block(const void *enc_key, size_t enc_keylen __maybe_unused, in crypto_aes_enc_block() argument 44 crypto_accel_aes_ecb_enc(dst, src, enc_key, rounds, 1); in crypto_aes_enc_block() 52 memcpy(ctx.buf, enc_key, enc_keylen); in crypto_aes_enc_block() 91 uint32_t enc_key[sizeof(ctx->key)] = { 0 }; in mbedtls_aes_setkey_dec() local 98 if (crypto_accel_aes_expand_keys(key, keybits / 8, enc_key, ctx->key, in mbedtls_aes_setkey_dec()
|
/optee_os-3.20.0/core/crypto/ |
A D | aes-gcm-sw.c | 54 const struct internal_aes_gcm_key *enc_key, in encrypt_block() argument 63 crypto_aes_enc_block(enc_key->data, sizeof(enc_key->data), in encrypt_block() 64 enc_key->rounds, state->ctr, state->buf_cryp); in encrypt_block() 93 const struct internal_aes_gcm_key *enc_key, in decrypt_block() argument 98 crypto_aes_enc_block(enc_key->data, sizeof(enc_key->data), in decrypt_block() 99 enc_key->rounds, state->ctr, buf_cryp); in decrypt_block()
|
A D | aes-gcm.c | 267 const struct internal_aes_gcm_key *enc_key, in operation_final() argument 273 res = __gcm_update_payload(state, enc_key, m, src, len, dst); in operation_final() 291 const struct internal_aes_gcm_key *enc_key, in __gcm_enc_final() argument 300 res = operation_final(state, enc_key, TEE_MODE_ENCRYPT, src, len, dst); in __gcm_enc_final() 319 const struct internal_aes_gcm_key *enc_key, in __gcm_dec_final() argument 328 res = operation_final(state, enc_key, TEE_MODE_DECRYPT, src, len, dst); in __gcm_dec_final() 370 TEE_Result internal_aes_gcm_enc(const struct internal_aes_gcm_key *enc_key, in internal_aes_gcm_enc() argument 379 res = __gcm_init(&state, enc_key, TEE_MODE_ENCRYPT, nonce, nonce_len, in internal_aes_gcm_enc() 390 return __gcm_enc_final(&state, enc_key, src, len, dst, tag, tag_len); in internal_aes_gcm_enc() 402 res = __gcm_init(&state, enc_key, TEE_MODE_DECRYPT, nonce, nonce_len, in internal_aes_gcm_dec() [all …]
|
/optee_os-3.20.0/core/arch/arm/crypto/ |
A D | aes_armv8a_ce.c | 64 static void expand_enc_key(uint32_t *enc_key, size_t key_len) in expand_enc_key() argument 74 uint32_t *rki = enc_key + i * kwords; in expand_enc_key() 121 void *enc_key, void *dec_key, in crypto_accel_aes_expand_keys() argument 128 if (!key || !enc_key) in crypto_accel_aes_expand_keys() 132 if (!IS_ALIGNED_WITH_TYPE(enc_key, struct aes_block) || in crypto_accel_aes_expand_keys() 142 memset(enc_key, 0, expanded_key_len); in crypto_accel_aes_expand_keys() 143 memcpy(enc_key, key, key_len); in crypto_accel_aes_expand_keys() 147 expand_enc_key(enc_key, key_len); in crypto_accel_aes_expand_keys() 149 make_dec_key(num_rounds, enc_key, dec_key); in crypto_accel_aes_expand_keys()
|
A D | aes-gcm-ce.c | 47 const struct internal_aes_gcm_key *enc_key) in internal_aes_gcm_set_key() argument 52 crypto_aes_enc_block(enc_key->data, sizeof(enc_key->data), in internal_aes_gcm_set_key() 53 enc_key->rounds, state->ctr, k); in internal_aes_gcm_set_key()
|
/optee_os-3.20.0/core/include/crypto/ |
A D | internal_aes-gcm.h | 75 TEE_Result internal_aes_gcm_enc(const struct internal_aes_gcm_key *enc_key, 81 TEE_Result internal_aes_gcm_dec(const struct internal_aes_gcm_key *enc_key, 109 const struct internal_aes_gcm_key *enc_key); 119 const struct internal_aes_gcm_key *enc_key);
|
A D | crypto_accel.h | 12 void *enc_key, void *dec_key,
|
A D | crypto.h | 395 void *enc_key, size_t enc_keylen, 406 void crypto_aes_enc_block(const void *enc_key, size_t enc_keylen,
|
/optee_os-3.20.0/ta/trusted_keys/ |
A D | entry.c | 29 uint8_t enc_key[]; member 112 res = TEE_AEEncryptFinal(crypto_op, in, in_sz, hdr->enc_key, in huk_ae_encrypt() 139 res = TEE_AEDecryptFinal(crypto_op, hdr->enc_key, enc_key_len, out, in huk_ae_decrypt()
|
/optee_os-3.20.0/scripts/ |
A D | sign_encrypt.py | 389 def encrypt_ta(self, enc_key, key_type, sig_algo, uuid, ta_version): argument 396 cipher = AESGCM(bytes.fromhex(enc_key)) 720 def decrypt_ta(enc_key): argument 723 cipher = AESGCM(bytes.fromhex(enc_key)) 829 if args.enc_key: 830 ta_image.encrypt_ta(args.enc_key, args.enc_key_type, 913 if args.enc_key is None: 916 image.decrypt_ta(args.enc_key)
|