Searched refs:cipher_ctx (Results 1 – 3 of 3) sorted by relevance
/trusty/user/app/sample/hwaes/ |
D | main.c | 33 static EVP_CIPHER_CTX* cipher_ctx; variable 36 assert(!cipher_ctx); in crypt_init() 38 cipher_ctx = EVP_CIPHER_CTX_new(); in crypt_init() 39 assert(cipher_ctx); in crypt_init() 43 EVP_CIPHER_CTX_free(cipher_ctx); in crypt_shutdown() 44 cipher_ctx = NULL; in crypt_shutdown() 193 assert(cipher_ctx); in hwaes_aes_op() 194 EVP_CIPHER_CTX_reset(cipher_ctx); in hwaes_aes_op() 196 evp_ret = EVP_CipherInit_ex(cipher_ctx, cipher, NULL, NULL, NULL, in hwaes_aes_op() 203 if (args->text_in.len % EVP_CIPHER_CTX_block_size(cipher_ctx)) { in hwaes_aes_op() [all …]
|
/trusty/user/app/storage/ |
D | crypt.c | 62 static EVP_CIPHER_CTX* cipher_ctx; variable 66 assert(!cipher_ctx); in crypt_init() 69 cipher_ctx = EVP_CIPHER_CTX_new(); in crypt_init() 70 assert(cipher_ctx); in crypt_init() 77 EVP_CIPHER_CTX_free(cipher_ctx); in crypt_shutdown() 78 cipher_ctx = NULL; in crypt_shutdown() 121 assert(cipher_ctx); in crypt() 122 EVP_CIPHER_CTX_reset(cipher_ctx); in crypt() 124 evp_ret = EVP_CipherInit_ex(cipher_ctx, cipher, NULL, key->byte, iv->byte, in crypt() 131 evp_ret = EVP_CIPHER_CTX_set_padding(cipher_ctx, 0); in crypt() [all …]
|
/trusty/user/app/sample/hwcrypto/ |
D | hwkey_srv.c | 242 EVP_CIPHER_CTX* cipher_ctx = EVP_CIPHER_CTX_new(); in hwkey_get_derived_key() local 243 if (!cipher_ctx) { in hwkey_get_derived_key() 250 evp_ret = EVP_DecryptInit_ex(cipher_ctx, cipher, NULL, NULL, NULL); in hwkey_get_derived_key() 256 unsigned int iv_length = EVP_CIPHER_CTX_iv_length(cipher_ctx); in hwkey_get_derived_key() 270 evp_ret = EVP_DecryptInit_ex(cipher_ctx, cipher, NULL, key_buffer, in hwkey_get_derived_key() 277 evp_ret = EVP_CIPHER_CTX_set_padding(cipher_ctx, 0); in hwkey_get_derived_key() 283 evp_ret = EVP_DecryptUpdate(cipher_ctx, kbuf, &out_len, in hwkey_get_derived_key() 295 evp_ret = EVP_DecryptFinal_ex(cipher_ctx, NULL, &out_len); in hwkey_get_derived_key() 312 EVP_CIPHER_CTX_free(cipher_ctx); in hwkey_get_derived_key()
|