Lines Matching refs:a
85 static void aes_ccm_encr_start(size_t L, const u8 *nonce, u8 *a) in aes_ccm_encr_start() argument
88 a[0] = L - 1; /* Flags = L' */ in aes_ccm_encr_start()
89 os_memcpy(&a[1], nonce, 15 - L); in aes_ccm_encr_start()
94 u8 *a) in aes_ccm_encr() argument
101 WPA_PUT_BE16(&a[AES_BLOCK_SIZE - 2], i); in aes_ccm_encr()
103 aes_encrypt(aes, a, out); in aes_ccm_encr()
109 WPA_PUT_BE16(&a[AES_BLOCK_SIZE - 2], i); in aes_ccm_encr()
110 aes_encrypt(aes, a, out); in aes_ccm_encr()
118 static void aes_ccm_encr_auth(void *aes, size_t M, u8 *x, u8 *a, u8 *auth) in aes_ccm_encr_auth() argument
125 WPA_PUT_BE16(&a[AES_BLOCK_SIZE - 2], 0); in aes_ccm_encr_auth()
126 aes_encrypt(aes, a, tmp); in aes_ccm_encr_auth()
133 static void aes_ccm_decr_auth(void *aes, size_t M, u8 *a, const u8 *auth, u8 *t) in aes_ccm_decr_auth() argument
140 WPA_PUT_BE16(&a[AES_BLOCK_SIZE - 2], 0); in aes_ccm_decr_auth()
141 aes_encrypt(aes, a, tmp); in aes_ccm_decr_auth()
155 u8 x[AES_BLOCK_SIZE], a[AES_BLOCK_SIZE]; in aes_ccm_ae() local
168 aes_ccm_encr_start(L, nonce, a); in aes_ccm_ae()
169 aes_ccm_encr(aes, L, plain, plain_len, crypt, a); in aes_ccm_ae()
170 aes_ccm_encr_auth(aes, M, x, a, auth); in aes_ccm_ae()
185 u8 x[AES_BLOCK_SIZE], a[AES_BLOCK_SIZE]; in aes_ccm_ad() local
196 aes_ccm_encr_start(L, nonce, a); in aes_ccm_ad()
197 aes_ccm_decr_auth(aes, M, a, auth, t); in aes_ccm_ad()
200 aes_ccm_encr(aes, L, crypt, crypt_len, plain, a); in aes_ccm_ad()