/external/wpa_supplicant_8/src/crypto/ |
aes-cbc.c | 27 u8 cbc[AES_BLOCK_SIZE]; 37 os_memcpy(cbc, iv, AES_BLOCK_SIZE); 39 blocks = data_len / AES_BLOCK_SIZE; 41 for (j = 0; j < AES_BLOCK_SIZE; j++) 44 os_memcpy(pos, cbc, AES_BLOCK_SIZE); 45 pos += AES_BLOCK_SIZE; 63 u8 cbc[AES_BLOCK_SIZE], tmp[AES_BLOCK_SIZE]; 73 os_memcpy(cbc, iv, AES_BLOCK_SIZE); 75 blocks = data_len / AES_BLOCK_SIZE; [all...] |
aes-ctr.c | 31 u8 counter[AES_BLOCK_SIZE], buf[AES_BLOCK_SIZE]; 36 os_memcpy(counter, nonce, AES_BLOCK_SIZE); 41 len = (left < AES_BLOCK_SIZE) ? left : AES_BLOCK_SIZE; 47 for (i = AES_BLOCK_SIZE - 1; i >= 0; i--) {
|
aes-omac1.c | 21 for (i = 0; i < AES_BLOCK_SIZE - 1; i++) 23 pad[AES_BLOCK_SIZE - 1] <<= 1; 25 pad[AES_BLOCK_SIZE - 1] ^= 0x87; 47 u8 cbc[AES_BLOCK_SIZE], pad[AES_BLOCK_SIZE]; 57 os_memset(cbc, 0, AES_BLOCK_SIZE); 68 while (left >= AES_BLOCK_SIZE) { 69 for (i = 0; i < AES_BLOCK_SIZE; i++) { 76 if (i + 1 == AES_BLOCK_SIZE && 77 left == AES_BLOCK_SIZE) [all...] |
aes-ccm.c | 32 u8 aad_buf[2 * AES_BLOCK_SIZE]; 33 u8 b[AES_BLOCK_SIZE]; 41 WPA_PUT_BE16(&b[AES_BLOCK_SIZE - L], plain_len); 43 wpa_hexdump_key(MSG_EXCESSIVE, "CCM B_0", b, AES_BLOCK_SIZE); 56 if (aad_len > AES_BLOCK_SIZE - 2) { 57 xor_aes_block(&aad_buf[AES_BLOCK_SIZE], x); 59 aes_encrypt(aes, &aad_buf[AES_BLOCK_SIZE], x); 66 size_t last = len % AES_BLOCK_SIZE; 69 for (i = 0; i < len / AES_BLOCK_SIZE; i++) { 72 data += AES_BLOCK_SIZE; [all...] |
aes-siv.c | 17 static const u8 zero[AES_BLOCK_SIZE]; 25 for (i = 0; i < AES_BLOCK_SIZE - 1; i++) 27 pad[AES_BLOCK_SIZE - 1] <<= 1; 29 pad[AES_BLOCK_SIZE - 1] ^= 0x87; 37 for (i = 0; i < AES_BLOCK_SIZE; i++) 56 os_memset(pad, 0, AES_BLOCK_SIZE); 59 if (len < AES_BLOCK_SIZE) 67 u8 tmp[AES_BLOCK_SIZE], tmp2[AES_BLOCK_SIZE]; 74 tmp[AES_BLOCK_SIZE - 1] = 1 [all...] |
aes-eax.c | 34 u8 nonce_mac[AES_BLOCK_SIZE], hdr_mac[AES_BLOCK_SIZE], 35 data_mac[AES_BLOCK_SIZE]; 69 for (i = 0; i < AES_BLOCK_SIZE; i++) 98 u8 nonce_mac[AES_BLOCK_SIZE], hdr_mac[AES_BLOCK_SIZE], 99 data_mac[AES_BLOCK_SIZE]; 139 for (i = 0; i < AES_BLOCK_SIZE; i++) {
|
aes.h | 12 #define AES_BLOCK_SIZE 16
|
crypto_internal-cipher.c | 76 os_memcpy(ctx->u.aes.cbc, iv, AES_BLOCK_SIZE); 117 if (len % AES_BLOCK_SIZE) 119 blocks = len / AES_BLOCK_SIZE; 121 for (j = 0; j < AES_BLOCK_SIZE; j++) 125 os_memcpy(crypt, ctx->u.aes.cbc, AES_BLOCK_SIZE); 126 plain += AES_BLOCK_SIZE; 127 crypt += AES_BLOCK_SIZE; 181 if (len % AES_BLOCK_SIZE) 183 blocks = len / AES_BLOCK_SIZE; 185 os_memcpy(tmp, crypt, AES_BLOCK_SIZE); [all...] |
aes-gcm.c | 19 val = WPA_GET_BE32(block + AES_BLOCK_SIZE - 4); 21 WPA_PUT_BE32(block + AES_BLOCK_SIZE - 4, val); 146 u8 cb[AES_BLOCK_SIZE], tmp[AES_BLOCK_SIZE]; 155 os_memcpy(cb, icb, AES_BLOCK_SIZE); 160 xpos += AES_BLOCK_SIZE; 161 ypos += AES_BLOCK_SIZE; 184 os_memset(H, 0, AES_BLOCK_SIZE); 187 H, AES_BLOCK_SIZE); 199 os_memset(J0 + iv_len, 0, AES_BLOCK_SIZE - iv_len) [all...] |
aes-unwrap.c | 29 u8 a[8], *r, b[AES_BLOCK_SIZE];
|
aes-wrap.c | 28 u8 *a, *r, b[AES_BLOCK_SIZE];
|
/external/boringssl/src/crypto/aes/ |
aes_test.cc | 23 const uint8_t plaintext[AES_BLOCK_SIZE], 24 const uint8_t ciphertext[AES_BLOCK_SIZE]) { 32 uint8_t block[AES_BLOCK_SIZE]; 34 if (memcmp(block, ciphertext, AES_BLOCK_SIZE) != 0) { 40 memcpy(block, plaintext, AES_BLOCK_SIZE); 42 if (memcmp(block, ciphertext, AES_BLOCK_SIZE) != 0) { 54 if (memcmp(block, plaintext, AES_BLOCK_SIZE) != 0) { 60 memcpy(block, ciphertext, AES_BLOCK_SIZE); 62 if (memcmp(block, plaintext, AES_BLOCK_SIZE) != 0) {
|
mode_wrappers.c | 57 const AES_KEY *key, uint8_t ivec[AES_BLOCK_SIZE], 58 uint8_t ecount_buf[AES_BLOCK_SIZE], unsigned int *num) {
|
/external/boringssl/src/crypto/cmac/ |
cmac.c | 63 uint8_t k1[AES_BLOCK_SIZE]; 64 uint8_t k2[AES_BLOCK_SIZE]; 66 uint8_t block[AES_BLOCK_SIZE]; 143 static const uint8_t kZeroIV[AES_BLOCK_SIZE] = {0}; 147 uint8_t scratch[AES_BLOCK_SIZE]; 149 if (EVP_CIPHER_block_size(cipher) != AES_BLOCK_SIZE || 152 !EVP_Cipher(&ctx->cipher_ctx, scratch, kZeroIV, AES_BLOCK_SIZE) || 171 uint8_t scratch[AES_BLOCK_SIZE]; 174 size_t todo = AES_BLOCK_SIZE - ctx->block_used; 185 * |AES_BLOCK_SIZE|, in which case we can stop here, or |ctx->block_used [all...] |
/frameworks/av/drm/libdrmframework/plugins/forward-lock/internal-format/common/ |
FwdLockGlue.c | 115 size_t padding = AES_BLOCK_SIZE - (decryptedKeyLength % AES_BLOCK_SIZE); 145 return ((plaintextKeyLength / AES_BLOCK_SIZE) + 2) * AES_BLOCK_SIZE; 155 unsigned char initVector[AES_BLOCK_SIZE]; 156 if (FwdLockGlue_GetRandomNumber(initVector, AES_BLOCK_SIZE)) { 157 size_t padding = AES_BLOCK_SIZE - (plaintextKeyLength % AES_BLOCK_SIZE); 158 size_t dataLength = encryptedKeyLength - AES_BLOCK_SIZE; 161 memcpy((unsigned char *)pEncryptedKey + dataLength, initVector, AES_BLOCK_SIZE); [all...] |
/frameworks/av/drm/mediadrm/plugins/clearkey/ |
ClearKeyTypes.h | 27 const uint8_t kBlockSize = AES_BLOCK_SIZE;
|
/device/google/contexthub/util/nanoapp_encr/ |
nanoapp_encr.c | 89 if (((bufUsed - sizeof(*image)) % AES_BLOCK_SIZE) != 0) 90 padLen = AES_BLOCK_SIZE - ((bufUsed - sizeof(*image)) % AES_BLOCK_SIZE); 134 sz = sz > AES_BLOCK_SIZE ? AES_BLOCK_SIZE : sz; 137 fwrite(outBuf, AES_BLOCK_SIZE, 1, out); 146 fwrite(outBuf, AES_BLOCK_SIZE, 1, out); 148 err = fwrite(outBuf, AES_BLOCK_SIZE, 1, out) != 1; 207 if (size > AES_BLOCK_SIZE) 208 size = AES_BLOCK_SIZE; [all...] |
/external/boringssl/src/include/openssl/ |
aes.h | 68 #define AES_BLOCK_SIZE 16 112 uint8_t ivec[AES_BLOCK_SIZE], 113 uint8_t ecount_buf[AES_BLOCK_SIZE],
|
/external/lzma/C/ |
Aes.h | 11 #define AES_BLOCK_SIZE 16
28 void AesCbc_Init(UInt32 *ivAes, const Byte *iv); /* iv size is AES_BLOCK_SIZE */
|
/external/lzma/CPP/7zip/Crypto/ |
MyAes.cpp | 19 memset(_iv, 0, AES_BLOCK_SIZE);
35 if (size < AES_BLOCK_SIZE)
36 return AES_BLOCK_SIZE;
56 if (size != AES_BLOCK_SIZE)
|
MyAes.h | 26 Byte _iv[AES_BLOCK_SIZE];
|
/system/security/keystore/ |
blob.cpp | 99 if (!entropy->generate_random_data(mBlob.vector, AES_BLOCK_SIZE)) { 107 // pad data to the AES_BLOCK_SIZE 108 size_t digestedLength = ((dataLength + AES_BLOCK_SIZE - 1) / AES_BLOCK_SIZE * AES_BLOCK_SIZE); 121 uint8_t vector[AES_BLOCK_SIZE]; 122 memcpy(vector, mBlob.vector, AES_BLOCK_SIZE); 161 // the AES_BLOCK_SIZE 187 if (encryptedLength % AES_BLOCK_SIZE != 0) {
|
blob.h | 57 uint8_t vector[AES_BLOCK_SIZE]; 62 uint8_t value[VALUE_SIZE + AES_BLOCK_SIZE];
|
/system/keymaster/ |
aes_operation.cpp | 178 memset_s(aad_block_buf_.get(), AES_BLOCK_SIZE, 0); 185 aad_block_buf_.reset(new (std::nothrow) uint8_t[AES_BLOCK_SIZE]); 221 if (!output->reserve(AES_BLOCK_SIZE)) 235 assert(output_written <= AES_BLOCK_SIZE); 339 aad_block_buf_.reset(new (std::nothrow) uint8_t[AES_BLOCK_SIZE]); 353 if (block_mode_ != KM_MODE_GCM && iv_blob.data_length != AES_BLOCK_SIZE) { 354 LOG_E("Expected %d-byte IV for AES operation, but got %d bytes", AES_BLOCK_SIZE, 375 * AES_BLOCK_SIZE increments, buffering (in aad_block_buf_) when given smaller amounts of data. 391 if (aad_block_buf_length_ == AES_BLOCK_SIZE && !ProcessBufferedAadBlock(error)) 395 size_t blocks_to_process = aad.data_length / AES_BLOCK_SIZE; [all...] |
/device/google/contexthub/lib/include/nanohub/ |
aes.h | 32 #define AES_BLOCK_SIZE 16 // in bytes
|