Lines Matching refs:AES_BLOCK_SIZE

57 #define N_WORDS (AES_BLOCK_SIZE / sizeof(unsigned long))
73 # define load_block(d, s) memcpy((d).data, (s), AES_BLOCK_SIZE)
74 # define store_block(d, s) memcpy((d), (s).data, AES_BLOCK_SIZE)
88 OPENSSL_assert((length % AES_BLOCK_SIZE) == 0);
90 len = length / AES_BLOCK_SIZE;
98 aes_block_t *iv2p = (aes_block_t *) (ivec + AES_BLOCK_SIZE);
113 in += AES_BLOCK_SIZE;
114 out += AES_BLOCK_SIZE;
116 memcpy(ivec, ivp->data, AES_BLOCK_SIZE);
117 memcpy(ivec + AES_BLOCK_SIZE, iv2p->data, AES_BLOCK_SIZE);
124 load_block(iv2, ivec + AES_BLOCK_SIZE);
138 in += AES_BLOCK_SIZE;
139 out += AES_BLOCK_SIZE;
141 memcpy(ivec, iv.data, AES_BLOCK_SIZE);
142 memcpy(ivec + AES_BLOCK_SIZE, iv2.data, AES_BLOCK_SIZE);
150 aes_block_t *iv2p = (aes_block_t *) (ivec + AES_BLOCK_SIZE);
166 in += AES_BLOCK_SIZE;
167 out += AES_BLOCK_SIZE;
169 memcpy(ivec, ivp->data, AES_BLOCK_SIZE);
170 memcpy(ivec + AES_BLOCK_SIZE, iv2p->data, AES_BLOCK_SIZE);
177 load_block(iv2, ivec + AES_BLOCK_SIZE);
192 in += AES_BLOCK_SIZE;
193 out += AES_BLOCK_SIZE;
195 memcpy(ivec, iv.data, AES_BLOCK_SIZE);
196 memcpy(ivec + AES_BLOCK_SIZE, iv2.data, AES_BLOCK_SIZE);
215 unsigned char tmp[AES_BLOCK_SIZE];
216 unsigned char tmp2[AES_BLOCK_SIZE];
217 unsigned char tmp3[AES_BLOCK_SIZE];
218 unsigned char prev[AES_BLOCK_SIZE];
224 OPENSSL_assert((length % AES_BLOCK_SIZE) == 0);
234 iv2 = ivec + AES_BLOCK_SIZE;
235 while (len >= AES_BLOCK_SIZE) {
236 for (n = 0; n < AES_BLOCK_SIZE; ++n)
239 for (n = 0; n < AES_BLOCK_SIZE; ++n)
242 memcpy(prev, in, AES_BLOCK_SIZE);
244 len -= AES_BLOCK_SIZE;
245 in += AES_BLOCK_SIZE;
246 out += AES_BLOCK_SIZE;
250 iv = ivec + AES_BLOCK_SIZE * 2;
251 iv2 = ivec + AES_BLOCK_SIZE * 3;
253 while (len >= AES_BLOCK_SIZE) {
254 out -= AES_BLOCK_SIZE;
258 memcpy(tmp, out, AES_BLOCK_SIZE);
259 for (n = 0; n < AES_BLOCK_SIZE; ++n)
262 * hexdump(stdout, "out ^ iv", out, AES_BLOCK_SIZE);
266 * hexdump(stdout,"enc", out, AES_BLOCK_SIZE);
269 * hexdump(stdout,"iv2", iv2, AES_BLOCK_SIZE);
271 for (n = 0; n < AES_BLOCK_SIZE; ++n)
274 * hexdump(stdout,"out", out, AES_BLOCK_SIZE);
277 memcpy(prev, tmp, AES_BLOCK_SIZE);
279 len -= AES_BLOCK_SIZE;
283 iv = ivec + AES_BLOCK_SIZE * 2;
284 iv2 = ivec + AES_BLOCK_SIZE * 3;
287 while (len >= AES_BLOCK_SIZE) {
288 in -= AES_BLOCK_SIZE;
289 out -= AES_BLOCK_SIZE;
290 memcpy(tmp, in, AES_BLOCK_SIZE);
291 memcpy(tmp2, in, AES_BLOCK_SIZE);
292 for (n = 0; n < AES_BLOCK_SIZE; ++n)
295 for (n = 0; n < AES_BLOCK_SIZE; ++n)
297 memcpy(tmp3, tmp2, AES_BLOCK_SIZE);
300 len -= AES_BLOCK_SIZE;
305 iv2 = ivec + AES_BLOCK_SIZE;
307 while (len >= AES_BLOCK_SIZE) {
308 memcpy(tmp, out, AES_BLOCK_SIZE);
309 memcpy(tmp2, out, AES_BLOCK_SIZE);
310 for (n = 0; n < AES_BLOCK_SIZE; ++n)
313 for (n = 0; n < AES_BLOCK_SIZE; ++n)
315 memcpy(tmp3, tmp2, AES_BLOCK_SIZE);
318 len -= AES_BLOCK_SIZE;
319 in += AES_BLOCK_SIZE;
320 out += AES_BLOCK_SIZE;