Lines Matching refs:key_len
64 static int aes_s2v(const u8 *key, size_t key_len, in aes_s2v() argument
79 return omac1_aes_vector(key, key_len, 1, data, data_len, mac); in aes_s2v()
84 ret = omac1_aes_vector(key, key_len, 1, data, data_len, tmp); in aes_s2v()
89 ret = omac1_aes_vector(key, key_len, 1, &addr[i], &len[i], in aes_s2v()
104 ret = omac1_aes_vector(key, key_len, 1, data, &len[i], mac); in aes_s2v()
115 return omac1_aes_vector(key, key_len, 1, data, data_len, mac); in aes_s2v()
119 int aes_siv_encrypt(const u8 *key, size_t key_len, in aes_siv_encrypt() argument
132 (key_len != 32 && key_len != 48 && key_len != 64)) in aes_siv_encrypt()
135 key_len /= 2; in aes_siv_encrypt()
137 k2 = key + key_len; in aes_siv_encrypt()
146 if (aes_s2v(k1, key_len, num_elem + 1, _addr, _len, v)) in aes_siv_encrypt()
158 return aes_ctr_encrypt(k2, key_len, v, crypt_pw, pwlen); in aes_siv_encrypt()
162 int aes_siv_decrypt(const u8 *key, size_t key_len, in aes_siv_decrypt() argument
177 (key_len != 32 && key_len != 48 && key_len != 64)) in aes_siv_decrypt()
180 key_len /= 2; in aes_siv_decrypt()
182 k2 = key + key_len; in aes_siv_decrypt()
197 ret = aes_ctr_encrypt(k2, key_len, iv, out, crypt_len); in aes_siv_decrypt()
201 ret = aes_s2v(k1, key_len, num_elem + 1, _addr, _len, check); in aes_siv_decrypt()