1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24#ifndef _CRYPTO_TESTMGR_H
25#define _CRYPTO_TESTMGR_H
26
27#include <linux/netlink.h>
28#include <linux/zlib.h>
29
30#include <crypto/compress.h>
31
32#define MAX_DIGEST_SIZE 64
33#define MAX_TAP 8
34
35#define MAX_KEYLEN 56
36#define MAX_IVLEN 32
37
38struct hash_testvec {
39
40 char *key;
41 char *plaintext;
42 char *digest;
43 unsigned char tap[MAX_TAP];
44 unsigned char psize;
45 unsigned char np;
46 unsigned char ksize;
47};
48
49struct cipher_testvec {
50 char *key;
51 char *iv;
52 char *input;
53 char *result;
54 unsigned short tap[MAX_TAP];
55 int np;
56 unsigned char fail;
57 unsigned char wk;
58 unsigned char klen;
59 unsigned short ilen;
60 unsigned short rlen;
61};
62
63struct aead_testvec {
64 char *key;
65 char *iv;
66 char *input;
67 char *assoc;
68 char *result;
69 unsigned char tap[MAX_TAP];
70 unsigned char atap[MAX_TAP];
71 int np;
72 int anp;
73 unsigned char fail;
74 unsigned char novrfy;
75 unsigned char wk;
76 unsigned char klen;
77 unsigned short ilen;
78 unsigned short alen;
79 unsigned short rlen;
80};
81
82struct cprng_testvec {
83 char *key;
84 char *dt;
85 char *v;
86 char *result;
87 unsigned char klen;
88 unsigned short dtlen;
89 unsigned short vlen;
90 unsigned short rlen;
91 unsigned short loops;
92};
93
94static char zeroed_string[48];
95
96
97
98
99#define MD4_TEST_VECTORS 7
100
101static struct hash_testvec md4_tv_template [] = {
102 {
103 .plaintext = "",
104 .digest = "\x31\xd6\xcf\xe0\xd1\x6a\xe9\x31"
105 "\xb7\x3c\x59\xd7\xe0\xc0\x89\xc0",
106 }, {
107 .plaintext = "a",
108 .psize = 1,
109 .digest = "\xbd\xe5\x2c\xb3\x1d\xe3\x3e\x46"
110 "\x24\x5e\x05\xfb\xdb\xd6\xfb\x24",
111 }, {
112 .plaintext = "abc",
113 .psize = 3,
114 .digest = "\xa4\x48\x01\x7a\xaf\x21\xd8\x52"
115 "\x5f\xc1\x0a\xe8\x7a\xa6\x72\x9d",
116 }, {
117 .plaintext = "message digest",
118 .psize = 14,
119 .digest = "\xd9\x13\x0a\x81\x64\x54\x9f\xe8"
120 "\x18\x87\x48\x06\xe1\xc7\x01\x4b",
121 }, {
122 .plaintext = "abcdefghijklmnopqrstuvwxyz",
123 .psize = 26,
124 .digest = "\xd7\x9e\x1c\x30\x8a\xa5\xbb\xcd"
125 "\xee\xa8\xed\x63\xdf\x41\x2d\xa9",
126 .np = 2,
127 .tap = { 13, 13 },
128 }, {
129 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",
130 .psize = 62,
131 .digest = "\x04\x3f\x85\x82\xf2\x41\xdb\x35"
132 "\x1c\xe6\x27\xe1\x53\xe7\xf0\xe4",
133 }, {
134 .plaintext = "123456789012345678901234567890123456789012345678901234567890123"
135 "45678901234567890",
136 .psize = 80,
137 .digest = "\xe3\x3b\x4d\xdc\x9c\x38\xf2\x19"
138 "\x9c\x3e\x7b\x16\x4f\xcc\x05\x36",
139 },
140};
141
142
143
144
145#define MD5_TEST_VECTORS 7
146
147static struct hash_testvec md5_tv_template[] = {
148 {
149 .digest = "\xd4\x1d\x8c\xd9\x8f\x00\xb2\x04"
150 "\xe9\x80\x09\x98\xec\xf8\x42\x7e",
151 }, {
152 .plaintext = "a",
153 .psize = 1,
154 .digest = "\x0c\xc1\x75\xb9\xc0\xf1\xb6\xa8"
155 "\x31\xc3\x99\xe2\x69\x77\x26\x61",
156 }, {
157 .plaintext = "abc",
158 .psize = 3,
159 .digest = "\x90\x01\x50\x98\x3c\xd2\x4f\xb0"
160 "\xd6\x96\x3f\x7d\x28\xe1\x7f\x72",
161 }, {
162 .plaintext = "message digest",
163 .psize = 14,
164 .digest = "\xf9\x6b\x69\x7d\x7c\xb7\x93\x8d"
165 "\x52\x5a\x2f\x31\xaa\xf1\x61\xd0",
166 }, {
167 .plaintext = "abcdefghijklmnopqrstuvwxyz",
168 .psize = 26,
169 .digest = "\xc3\xfc\xd3\xd7\x61\x92\xe4\x00"
170 "\x7d\xfb\x49\x6c\xca\x67\xe1\x3b",
171 .np = 2,
172 .tap = {13, 13}
173 }, {
174 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",
175 .psize = 62,
176 .digest = "\xd1\x74\xab\x98\xd2\x77\xd9\xf5"
177 "\xa5\x61\x1c\x2c\x9f\x41\x9d\x9f",
178 }, {
179 .plaintext = "12345678901234567890123456789012345678901234567890123456789012"
180 "345678901234567890",
181 .psize = 80,
182 .digest = "\x57\xed\xf4\xa2\x2b\xe3\xc9\x55"
183 "\xac\x49\xda\x2e\x21\x07\xb6\x7a",
184 }
185
186};
187
188
189
190
191#define RMD128_TEST_VECTORS 10
192
193static struct hash_testvec rmd128_tv_template[] = {
194 {
195 .digest = "\xcd\xf2\x62\x13\xa1\x50\xdc\x3e"
196 "\xcb\x61\x0f\x18\xf6\xb3\x8b\x46",
197 }, {
198 .plaintext = "a",
199 .psize = 1,
200 .digest = "\x86\xbe\x7a\xfa\x33\x9d\x0f\xc7"
201 "\xcf\xc7\x85\xe7\x2f\x57\x8d\x33",
202 }, {
203 .plaintext = "abc",
204 .psize = 3,
205 .digest = "\xc1\x4a\x12\x19\x9c\x66\xe4\xba"
206 "\x84\x63\x6b\x0f\x69\x14\x4c\x77",
207 }, {
208 .plaintext = "message digest",
209 .psize = 14,
210 .digest = "\x9e\x32\x7b\x3d\x6e\x52\x30\x62"
211 "\xaf\xc1\x13\x2d\x7d\xf9\xd1\xb8",
212 }, {
213 .plaintext = "abcdefghijklmnopqrstuvwxyz",
214 .psize = 26,
215 .digest = "\xfd\x2a\xa6\x07\xf7\x1d\xc8\xf5"
216 "\x10\x71\x49\x22\xb3\x71\x83\x4e",
217 }, {
218 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcde"
219 "fghijklmnopqrstuvwxyz0123456789",
220 .psize = 62,
221 .digest = "\xd1\xe9\x59\xeb\x17\x9c\x91\x1f"
222 "\xae\xa4\x62\x4c\x60\xc5\xc7\x02",
223 }, {
224 .plaintext = "1234567890123456789012345678901234567890"
225 "1234567890123456789012345678901234567890",
226 .psize = 80,
227 .digest = "\x3f\x45\xef\x19\x47\x32\xc2\xdb"
228 "\xb2\xc4\xa2\xc7\x69\x79\x5f\xa3",
229 }, {
230 .plaintext = "abcdbcdecdefdefgefghfghighij"
231 "hijkijkljklmklmnlmnomnopnopq",
232 .psize = 56,
233 .digest = "\xa1\xaa\x06\x89\xd0\xfa\xfa\x2d"
234 "\xdc\x22\xe8\x8b\x49\x13\x3a\x06",
235 .np = 2,
236 .tap = { 28, 28 },
237 }, {
238 .plaintext = "abcdefghbcdefghicdefghijdefghijkefghijklfghi"
239 "jklmghijklmnhijklmnoijklmnopjklmnopqklmnopqr"
240 "lmnopqrsmnopqrstnopqrstu",
241 .psize = 112,
242 .digest = "\xd4\xec\xc9\x13\xe1\xdf\x77\x6b"
243 "\xf4\x8d\xe9\xd5\x5b\x1f\x25\x46",
244 }, {
245 .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
246 .psize = 32,
247 .digest = "\x13\xfc\x13\xe8\xef\xff\x34\x7d"
248 "\xe1\x93\xff\x46\xdb\xac\xcf\xd4",
249 }
250};
251
252
253
254
255#define RMD160_TEST_VECTORS 10
256
257static struct hash_testvec rmd160_tv_template[] = {
258 {
259 .digest = "\x9c\x11\x85\xa5\xc5\xe9\xfc\x54\x61\x28"
260 "\x08\x97\x7e\xe8\xf5\x48\xb2\x25\x8d\x31",
261 }, {
262 .plaintext = "a",
263 .psize = 1,
264 .digest = "\x0b\xdc\x9d\x2d\x25\x6b\x3e\xe9\xda\xae"
265 "\x34\x7b\xe6\xf4\xdc\x83\x5a\x46\x7f\xfe",
266 }, {
267 .plaintext = "abc",
268 .psize = 3,
269 .digest = "\x8e\xb2\x08\xf7\xe0\x5d\x98\x7a\x9b\x04"
270 "\x4a\x8e\x98\xc6\xb0\x87\xf1\x5a\x0b\xfc",
271 }, {
272 .plaintext = "message digest",
273 .psize = 14,
274 .digest = "\x5d\x06\x89\xef\x49\xd2\xfa\xe5\x72\xb8"
275 "\x81\xb1\x23\xa8\x5f\xfa\x21\x59\x5f\x36",
276 }, {
277 .plaintext = "abcdefghijklmnopqrstuvwxyz",
278 .psize = 26,
279 .digest = "\xf7\x1c\x27\x10\x9c\x69\x2c\x1b\x56\xbb"
280 "\xdc\xeb\x5b\x9d\x28\x65\xb3\x70\x8d\xbc",
281 }, {
282 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcde"
283 "fghijklmnopqrstuvwxyz0123456789",
284 .psize = 62,
285 .digest = "\xb0\xe2\x0b\x6e\x31\x16\x64\x02\x86\xed"
286 "\x3a\x87\xa5\x71\x30\x79\xb2\x1f\x51\x89",
287 }, {
288 .plaintext = "1234567890123456789012345678901234567890"
289 "1234567890123456789012345678901234567890",
290 .psize = 80,
291 .digest = "\x9b\x75\x2e\x45\x57\x3d\x4b\x39\xf4\xdb"
292 "\xd3\x32\x3c\xab\x82\xbf\x63\x32\x6b\xfb",
293 }, {
294 .plaintext = "abcdbcdecdefdefgefghfghighij"
295 "hijkijkljklmklmnlmnomnopnopq",
296 .psize = 56,
297 .digest = "\x12\xa0\x53\x38\x4a\x9c\x0c\x88\xe4\x05"
298 "\xa0\x6c\x27\xdc\xf4\x9a\xda\x62\xeb\x2b",
299 .np = 2,
300 .tap = { 28, 28 },
301 }, {
302 .plaintext = "abcdefghbcdefghicdefghijdefghijkefghijklfghi"
303 "jklmghijklmnhijklmnoijklmnopjklmnopqklmnopqr"
304 "lmnopqrsmnopqrstnopqrstu",
305 .psize = 112,
306 .digest = "\x6f\x3f\xa3\x9b\x6b\x50\x3c\x38\x4f\x91"
307 "\x9a\x49\xa7\xaa\x5c\x2c\x08\xbd\xfb\x45",
308 }, {
309 .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
310 .psize = 32,
311 .digest = "\x94\xc2\x64\x11\x54\x04\xe6\x33\x79\x0d"
312 "\xfc\xc8\x7b\x58\x7d\x36\x77\x06\x7d\x9f",
313 }
314};
315
316
317
318
319#define RMD256_TEST_VECTORS 8
320
321static struct hash_testvec rmd256_tv_template[] = {
322 {
323 .digest = "\x02\xba\x4c\x4e\x5f\x8e\xcd\x18"
324 "\x77\xfc\x52\xd6\x4d\x30\xe3\x7a"
325 "\x2d\x97\x74\xfb\x1e\x5d\x02\x63"
326 "\x80\xae\x01\x68\xe3\xc5\x52\x2d",
327 }, {
328 .plaintext = "a",
329 .psize = 1,
330 .digest = "\xf9\x33\x3e\x45\xd8\x57\xf5\xd9"
331 "\x0a\x91\xba\xb7\x0a\x1e\xba\x0c"
332 "\xfb\x1b\xe4\xb0\x78\x3c\x9a\xcf"
333 "\xcd\x88\x3a\x91\x34\x69\x29\x25",
334 }, {
335 .plaintext = "abc",
336 .psize = 3,
337 .digest = "\xaf\xbd\x6e\x22\x8b\x9d\x8c\xbb"
338 "\xce\xf5\xca\x2d\x03\xe6\xdb\xa1"
339 "\x0a\xc0\xbc\x7d\xcb\xe4\x68\x0e"
340 "\x1e\x42\xd2\xe9\x75\x45\x9b\x65",
341 }, {
342 .plaintext = "message digest",
343 .psize = 14,
344 .digest = "\x87\xe9\x71\x75\x9a\x1c\xe4\x7a"
345 "\x51\x4d\x5c\x91\x4c\x39\x2c\x90"
346 "\x18\xc7\xc4\x6b\xc1\x44\x65\x55"
347 "\x4a\xfc\xdf\x54\xa5\x07\x0c\x0e",
348 }, {
349 .plaintext = "abcdefghijklmnopqrstuvwxyz",
350 .psize = 26,
351 .digest = "\x64\x9d\x30\x34\x75\x1e\xa2\x16"
352 "\x77\x6b\xf9\xa1\x8a\xcc\x81\xbc"
353 "\x78\x96\x11\x8a\x51\x97\x96\x87"
354 "\x82\xdd\x1f\xd9\x7d\x8d\x51\x33",
355 }, {
356 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcde"
357 "fghijklmnopqrstuvwxyz0123456789",
358 .psize = 62,
359 .digest = "\x57\x40\xa4\x08\xac\x16\xb7\x20"
360 "\xb8\x44\x24\xae\x93\x1c\xbb\x1f"
361 "\xe3\x63\xd1\xd0\xbf\x40\x17\xf1"
362 "\xa8\x9f\x7e\xa6\xde\x77\xa0\xb8",
363 }, {
364 .plaintext = "1234567890123456789012345678901234567890"
365 "1234567890123456789012345678901234567890",
366 .psize = 80,
367 .digest = "\x06\xfd\xcc\x7a\x40\x95\x48\xaa"
368 "\xf9\x13\x68\xc0\x6a\x62\x75\xb5"
369 "\x53\xe3\xf0\x99\xbf\x0e\xa4\xed"
370 "\xfd\x67\x78\xdf\x89\xa8\x90\xdd",
371 }, {
372 .plaintext = "abcdbcdecdefdefgefghfghighij"
373 "hijkijkljklmklmnlmnomnopnopq",
374 .psize = 56,
375 .digest = "\x38\x43\x04\x55\x83\xaa\xc6\xc8"
376 "\xc8\xd9\x12\x85\x73\xe7\xa9\x80"
377 "\x9a\xfb\x2a\x0f\x34\xcc\xc3\x6e"
378 "\xa9\xe7\x2f\x16\xf6\x36\x8e\x3f",
379 .np = 2,
380 .tap = { 28, 28 },
381 }
382};
383
384
385
386
387#define RMD320_TEST_VECTORS 8
388
389static struct hash_testvec rmd320_tv_template[] = {
390 {
391 .digest = "\x22\xd6\x5d\x56\x61\x53\x6c\xdc\x75\xc1"
392 "\xfd\xf5\xc6\xde\x7b\x41\xb9\xf2\x73\x25"
393 "\xeb\xc6\x1e\x85\x57\x17\x7d\x70\x5a\x0e"
394 "\xc8\x80\x15\x1c\x3a\x32\xa0\x08\x99\xb8",
395 }, {
396 .plaintext = "a",
397 .psize = 1,
398 .digest = "\xce\x78\x85\x06\x38\xf9\x26\x58\xa5\xa5"
399 "\x85\x09\x75\x79\x92\x6d\xda\x66\x7a\x57"
400 "\x16\x56\x2c\xfc\xf6\xfb\xe7\x7f\x63\x54"
401 "\x2f\x99\xb0\x47\x05\xd6\x97\x0d\xff\x5d",
402 }, {
403 .plaintext = "abc",
404 .psize = 3,
405 .digest = "\xde\x4c\x01\xb3\x05\x4f\x89\x30\xa7\x9d"
406 "\x09\xae\x73\x8e\x92\x30\x1e\x5a\x17\x08"
407 "\x5b\xef\xfd\xc1\xb8\xd1\x16\x71\x3e\x74"
408 "\xf8\x2f\xa9\x42\xd6\x4c\xdb\xc4\x68\x2d",
409 }, {
410 .plaintext = "message digest",
411 .psize = 14,
412 .digest = "\x3a\x8e\x28\x50\x2e\xd4\x5d\x42\x2f\x68"
413 "\x84\x4f\x9d\xd3\x16\xe7\xb9\x85\x33\xfa"
414 "\x3f\x2a\x91\xd2\x9f\x84\xd4\x25\xc8\x8d"
415 "\x6b\x4e\xff\x72\x7d\xf6\x6a\x7c\x01\x97",
416 }, {
417 .plaintext = "abcdefghijklmnopqrstuvwxyz",
418 .psize = 26,
419 .digest = "\xca\xbd\xb1\x81\x0b\x92\x47\x0a\x20\x93"
420 "\xaa\x6b\xce\x05\x95\x2c\x28\x34\x8c\xf4"
421 "\x3f\xf6\x08\x41\x97\x51\x66\xbb\x40\xed"
422 "\x23\x40\x04\xb8\x82\x44\x63\xe6\xb0\x09",
423 }, {
424 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcde"
425 "fghijklmnopqrstuvwxyz0123456789",
426 .psize = 62,
427 .digest = "\xed\x54\x49\x40\xc8\x6d\x67\xf2\x50\xd2"
428 "\x32\xc3\x0b\x7b\x3e\x57\x70\xe0\xc6\x0c"
429 "\x8c\xb9\xa4\xca\xfe\x3b\x11\x38\x8a\xf9"
430 "\x92\x0e\x1b\x99\x23\x0b\x84\x3c\x86\xa4",
431 }, {
432 .plaintext = "1234567890123456789012345678901234567890"
433 "1234567890123456789012345678901234567890",
434 .psize = 80,
435 .digest = "\x55\x78\x88\xaf\x5f\x6d\x8e\xd6\x2a\xb6"
436 "\x69\x45\xc6\xd2\xa0\xa4\x7e\xcd\x53\x41"
437 "\xe9\x15\xeb\x8f\xea\x1d\x05\x24\x95\x5f"
438 "\x82\x5d\xc7\x17\xe4\xa0\x08\xab\x2d\x42",
439 }, {
440 .plaintext = "abcdbcdecdefdefgefghfghighij"
441 "hijkijkljklmklmnlmnomnopnopq",
442 .psize = 56,
443 .digest = "\xd0\x34\xa7\x95\x0c\xf7\x22\x02\x1b\xa4"
444 "\xb8\x4d\xf7\x69\xa5\xde\x20\x60\xe2\x59"
445 "\xdf\x4c\x9b\xb4\xa4\x26\x8c\x0e\x93\x5b"
446 "\xbc\x74\x70\xa9\x69\xc9\xd0\x72\xa1\xac",
447 .np = 2,
448 .tap = { 28, 28 },
449 }
450};
451
452
453
454
455
456#define SHA1_TEST_VECTORS 3
457
458static struct hash_testvec sha1_tv_template[] = {
459 {
460 .plaintext = "abc",
461 .psize = 3,
462 .digest = "\xa9\x99\x3e\x36\x47\x06\x81\x6a\xba\x3e"
463 "\x25\x71\x78\x50\xc2\x6c\x9c\xd0\xd8\x9d",
464 }, {
465 .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
466 .psize = 56,
467 .digest = "\x84\x98\x3e\x44\x1c\x3b\xd2\x6e\xba\xae"
468 "\x4a\xa1\xf9\x51\x29\xe5\xe5\x46\x70\xf1",
469 .np = 2,
470 .tap = { 28, 28 }
471 }, {
472 .plaintext = "\xec\x29\x56\x12\x44\xed\xe7\x06"
473 "\xb6\xeb\x30\xa1\xc3\x71\xd7\x44"
474 "\x50\xa1\x05\xc3\xf9\x73\x5f\x7f"
475 "\xa9\xfe\x38\xcf\x67\xf3\x04\xa5"
476 "\x73\x6a\x10\x6e\x92\xe1\x71\x39"
477 "\xa6\x81\x3b\x1c\x81\xa4\xf3\xd3"
478 "\xfb\x95\x46\xab\x42\x96\xfa\x9f"
479 "\x72\x28\x26\xc0\x66\x86\x9e\xda"
480 "\xcd\x73\xb2\x54\x80\x35\x18\x58"
481 "\x13\xe2\x26\x34\xa9\xda\x44\x00"
482 "\x0d\x95\xa2\x81\xff\x9f\x26\x4e"
483 "\xcc\xe0\xa9\x31\x22\x21\x62\xd0"
484 "\x21\xcc\xa2\x8d\xb5\xf3\xc2\xaa"
485 "\x24\x94\x5a\xb1\xe3\x1c\xb4\x13"
486 "\xae\x29\x81\x0f\xd7\x94\xca\xd5"
487 "\xdf\xaf\x29\xec\x43\xcb\x38\xd1"
488 "\x98\xfe\x4a\xe1\xda\x23\x59\x78"
489 "\x02\x21\x40\x5b\xd6\x71\x2a\x53"
490 "\x05\xda\x4b\x1b\x73\x7f\xce\x7c"
491 "\xd2\x1c\x0e\xb7\x72\x8d\x08\x23"
492 "\x5a\x90\x11",
493 .psize = 163,
494 .digest = "\x97\x01\x11\xc4\xe7\x7b\xcc\x88\xcc\x20"
495 "\x45\x9c\x02\xb6\x9b\x4a\xa8\xf5\x82\x17",
496 .np = 4,
497 .tap = { 63, 64, 31, 5 }
498 }
499};
500
501
502
503
504
505#define SHA224_TEST_VECTORS 2
506
507static struct hash_testvec sha224_tv_template[] = {
508 {
509 .plaintext = "abc",
510 .psize = 3,
511 .digest = "\x23\x09\x7D\x22\x34\x05\xD8\x22"
512 "\x86\x42\xA4\x77\xBD\xA2\x55\xB3"
513 "\x2A\xAD\xBC\xE4\xBD\xA0\xB3\xF7"
514 "\xE3\x6C\x9D\xA7",
515 }, {
516 .plaintext =
517 "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
518 .psize = 56,
519 .digest = "\x75\x38\x8B\x16\x51\x27\x76\xCC"
520 "\x5D\xBA\x5D\xA1\xFD\x89\x01\x50"
521 "\xB0\xC6\x45\x5C\xB4\xF5\x8B\x19"
522 "\x52\x52\x25\x25",
523 .np = 2,
524 .tap = { 28, 28 }
525 }
526};
527
528
529
530
531#define SHA256_TEST_VECTORS 2
532
533static struct hash_testvec sha256_tv_template[] = {
534 {
535 .plaintext = "abc",
536 .psize = 3,
537 .digest = "\xba\x78\x16\xbf\x8f\x01\xcf\xea"
538 "\x41\x41\x40\xde\x5d\xae\x22\x23"
539 "\xb0\x03\x61\xa3\x96\x17\x7a\x9c"
540 "\xb4\x10\xff\x61\xf2\x00\x15\xad",
541 }, {
542 .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
543 .psize = 56,
544 .digest = "\x24\x8d\x6a\x61\xd2\x06\x38\xb8"
545 "\xe5\xc0\x26\x93\x0c\x3e\x60\x39"
546 "\xa3\x3c\xe4\x59\x64\xff\x21\x67"
547 "\xf6\xec\xed\xd4\x19\xdb\x06\xc1",
548 .np = 2,
549 .tap = { 28, 28 }
550 },
551};
552
553
554
555
556#define SHA384_TEST_VECTORS 4
557
558static struct hash_testvec sha384_tv_template[] = {
559 {
560 .plaintext= "abc",
561 .psize = 3,
562 .digest = "\xcb\x00\x75\x3f\x45\xa3\x5e\x8b"
563 "\xb5\xa0\x3d\x69\x9a\xc6\x50\x07"
564 "\x27\x2c\x32\xab\x0e\xde\xd1\x63"
565 "\x1a\x8b\x60\x5a\x43\xff\x5b\xed"
566 "\x80\x86\x07\x2b\xa1\xe7\xcc\x23"
567 "\x58\xba\xec\xa1\x34\xc8\x25\xa7",
568 }, {
569 .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
570 .psize = 56,
571 .digest = "\x33\x91\xfd\xdd\xfc\x8d\xc7\x39"
572 "\x37\x07\xa6\x5b\x1b\x47\x09\x39"
573 "\x7c\xf8\xb1\xd1\x62\xaf\x05\xab"
574 "\xfe\x8f\x45\x0d\xe5\xf3\x6b\xc6"
575 "\xb0\x45\x5a\x85\x20\xbc\x4e\x6f"
576 "\x5f\xe9\x5b\x1f\xe3\xc8\x45\x2b",
577 }, {
578 .plaintext = "abcdefghbcdefghicdefghijdefghijkefghijklfghijklmghijklmn"
579 "hijklmnoijklmnopjklmnopqklmnopqrlmnopqrsmnopqrstnopqrstu",
580 .psize = 112,
581 .digest = "\x09\x33\x0c\x33\xf7\x11\x47\xe8"
582 "\x3d\x19\x2f\xc7\x82\xcd\x1b\x47"
583 "\x53\x11\x1b\x17\x3b\x3b\x05\xd2"
584 "\x2f\xa0\x80\x86\xe3\xb0\xf7\x12"
585 "\xfc\xc7\xc7\x1a\x55\x7e\x2d\xb9"
586 "\x66\xc3\xe9\xfa\x91\x74\x60\x39",
587 }, {
588 .plaintext = "abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcd"
589 "efghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz",
590 .psize = 104,
591 .digest = "\x3d\x20\x89\x73\xab\x35\x08\xdb"
592 "\xbd\x7e\x2c\x28\x62\xba\x29\x0a"
593 "\xd3\x01\x0e\x49\x78\xc1\x98\xdc"
594 "\x4d\x8f\xd0\x14\xe5\x82\x82\x3a"
595 "\x89\xe1\x6f\x9b\x2a\x7b\xbc\x1a"
596 "\xc9\x38\xe2\xd1\x99\xe8\xbe\xa4",
597 .np = 4,
598 .tap = { 26, 26, 26, 26 }
599 },
600};
601
602
603
604
605#define SHA512_TEST_VECTORS 4
606
607static struct hash_testvec sha512_tv_template[] = {
608 {
609 .plaintext = "abc",
610 .psize = 3,
611 .digest = "\xdd\xaf\x35\xa1\x93\x61\x7a\xba"
612 "\xcc\x41\x73\x49\xae\x20\x41\x31"
613 "\x12\xe6\xfa\x4e\x89\xa9\x7e\xa2"
614 "\x0a\x9e\xee\xe6\x4b\x55\xd3\x9a"
615 "\x21\x92\x99\x2a\x27\x4f\xc1\xa8"
616 "\x36\xba\x3c\x23\xa3\xfe\xeb\xbd"
617 "\x45\x4d\x44\x23\x64\x3c\xe8\x0e"
618 "\x2a\x9a\xc9\x4f\xa5\x4c\xa4\x9f",
619 }, {
620 .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
621 .psize = 56,
622 .digest = "\x20\x4a\x8f\xc6\xdd\xa8\x2f\x0a"
623 "\x0c\xed\x7b\xeb\x8e\x08\xa4\x16"
624 "\x57\xc1\x6e\xf4\x68\xb2\x28\xa8"
625 "\x27\x9b\xe3\x31\xa7\x03\xc3\x35"
626 "\x96\xfd\x15\xc1\x3b\x1b\x07\xf9"
627 "\xaa\x1d\x3b\xea\x57\x78\x9c\xa0"
628 "\x31\xad\x85\xc7\xa7\x1d\xd7\x03"
629 "\x54\xec\x63\x12\x38\xca\x34\x45",
630 }, {
631 .plaintext = "abcdefghbcdefghicdefghijdefghijkefghijklfghijklmghijklmn"
632 "hijklmnoijklmnopjklmnopqklmnopqrlmnopqrsmnopqrstnopqrstu",
633 .psize = 112,
634 .digest = "\x8e\x95\x9b\x75\xda\xe3\x13\xda"
635 "\x8c\xf4\xf7\x28\x14\xfc\x14\x3f"
636 "\x8f\x77\x79\xc6\xeb\x9f\x7f\xa1"
637 "\x72\x99\xae\xad\xb6\x88\x90\x18"
638 "\x50\x1d\x28\x9e\x49\x00\xf7\xe4"
639 "\x33\x1b\x99\xde\xc4\xb5\x43\x3a"
640 "\xc7\xd3\x29\xee\xb6\xdd\x26\x54"
641 "\x5e\x96\xe5\x5b\x87\x4b\xe9\x09",
642 }, {
643 .plaintext = "abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcd"
644 "efghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz",
645 .psize = 104,
646 .digest = "\x93\x0d\x0c\xef\xcb\x30\xff\x11"
647 "\x33\xb6\x89\x81\x21\xf1\xcf\x3d"
648 "\x27\x57\x8a\xfc\xaf\xe8\x67\x7c"
649 "\x52\x57\xcf\x06\x99\x11\xf7\x5d"
650 "\x8f\x58\x31\xb5\x6e\xbf\xda\x67"
651 "\xb2\x78\xe6\x6d\xff\x8b\x84\xfe"
652 "\x2b\x28\x70\xf7\x42\xa5\x80\xd8"
653 "\xed\xb4\x19\x87\x23\x28\x50\xc9",
654 .np = 4,
655 .tap = { 26, 26, 26, 26 }
656 },
657};
658
659
660
661
662
663
664
665#define WP512_TEST_VECTORS 8
666
667static struct hash_testvec wp512_tv_template[] = {
668 {
669 .plaintext = "",
670 .psize = 0,
671 .digest = "\x19\xFA\x61\xD7\x55\x22\xA4\x66"
672 "\x9B\x44\xE3\x9C\x1D\x2E\x17\x26"
673 "\xC5\x30\x23\x21\x30\xD4\x07\xF8"
674 "\x9A\xFE\xE0\x96\x49\x97\xF7\xA7"
675 "\x3E\x83\xBE\x69\x8B\x28\x8F\xEB"
676 "\xCF\x88\xE3\xE0\x3C\x4F\x07\x57"
677 "\xEA\x89\x64\xE5\x9B\x63\xD9\x37"
678 "\x08\xB1\x38\xCC\x42\xA6\x6E\xB3",
679
680
681 }, {
682 .plaintext = "a",
683 .psize = 1,
684 .digest = "\x8A\xCA\x26\x02\x79\x2A\xEC\x6F"
685 "\x11\xA6\x72\x06\x53\x1F\xB7\xD7"
686 "\xF0\xDF\xF5\x94\x13\x14\x5E\x69"
687 "\x73\xC4\x50\x01\xD0\x08\x7B\x42"
688 "\xD1\x1B\xC6\x45\x41\x3A\xEF\xF6"
689 "\x3A\x42\x39\x1A\x39\x14\x5A\x59"
690 "\x1A\x92\x20\x0D\x56\x01\x95\xE5"
691 "\x3B\x47\x85\x84\xFD\xAE\x23\x1A",
692 }, {
693 .plaintext = "abc",
694 .psize = 3,
695 .digest = "\x4E\x24\x48\xA4\xC6\xF4\x86\xBB"
696 "\x16\xB6\x56\x2C\x73\xB4\x02\x0B"
697 "\xF3\x04\x3E\x3A\x73\x1B\xCE\x72"
698 "\x1A\xE1\xB3\x03\xD9\x7E\x6D\x4C"
699 "\x71\x81\xEE\xBD\xB6\xC5\x7E\x27"
700 "\x7D\x0E\x34\x95\x71\x14\xCB\xD6"
701 "\xC7\x97\xFC\x9D\x95\xD8\xB5\x82"
702 "\xD2\x25\x29\x20\x76\xD4\xEE\xF5",
703 }, {
704 .plaintext = "message digest",
705 .psize = 14,
706 .digest = "\x37\x8C\x84\xA4\x12\x6E\x2D\xC6"
707 "\xE5\x6D\xCC\x74\x58\x37\x7A\xAC"
708 "\x83\x8D\x00\x03\x22\x30\xF5\x3C"
709 "\xE1\xF5\x70\x0C\x0F\xFB\x4D\x3B"
710 "\x84\x21\x55\x76\x59\xEF\x55\xC1"
711 "\x06\xB4\xB5\x2A\xC5\xA4\xAA\xA6"
712 "\x92\xED\x92\x00\x52\x83\x8F\x33"
713 "\x62\xE8\x6D\xBD\x37\xA8\x90\x3E",
714 }, {
715 .plaintext = "abcdefghijklmnopqrstuvwxyz",
716 .psize = 26,
717 .digest = "\xF1\xD7\x54\x66\x26\x36\xFF\xE9"
718 "\x2C\x82\xEB\xB9\x21\x2A\x48\x4A"
719 "\x8D\x38\x63\x1E\xAD\x42\x38\xF5"
720 "\x44\x2E\xE1\x3B\x80\x54\xE4\x1B"
721 "\x08\xBF\x2A\x92\x51\xC3\x0B\x6A"
722 "\x0B\x8A\xAE\x86\x17\x7A\xB4\xA6"
723 "\xF6\x8F\x67\x3E\x72\x07\x86\x5D"
724 "\x5D\x98\x19\xA3\xDB\xA4\xEB\x3B",
725 }, {
726 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
727 "abcdefghijklmnopqrstuvwxyz0123456789",
728 .psize = 62,
729 .digest = "\xDC\x37\xE0\x08\xCF\x9E\xE6\x9B"
730 "\xF1\x1F\x00\xED\x9A\xBA\x26\x90"
731 "\x1D\xD7\xC2\x8C\xDE\xC0\x66\xCC"
732 "\x6A\xF4\x2E\x40\xF8\x2F\x3A\x1E"
733 "\x08\xEB\xA2\x66\x29\x12\x9D\x8F"
734 "\xB7\xCB\x57\x21\x1B\x92\x81\xA6"
735 "\x55\x17\xCC\x87\x9D\x7B\x96\x21"
736 "\x42\xC6\x5F\x5A\x7A\xF0\x14\x67",
737 }, {
738 .plaintext = "1234567890123456789012345678901234567890"
739 "1234567890123456789012345678901234567890",
740 .psize = 80,
741 .digest = "\x46\x6E\xF1\x8B\xAB\xB0\x15\x4D"
742 "\x25\xB9\xD3\x8A\x64\x14\xF5\xC0"
743 "\x87\x84\x37\x2B\xCC\xB2\x04\xD6"
744 "\x54\x9C\x4A\xFA\xDB\x60\x14\x29"
745 "\x4D\x5B\xD8\xDF\x2A\x6C\x44\xE5"
746 "\x38\xCD\x04\x7B\x26\x81\xA5\x1A"
747 "\x2C\x60\x48\x1E\x88\xC5\xA2\x0B"
748 "\x2C\x2A\x80\xCF\x3A\x9A\x08\x3B",
749 }, {
750 .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
751 .psize = 32,
752 .digest = "\x2A\x98\x7E\xA4\x0F\x91\x70\x61"
753 "\xF5\xD6\xF0\xA0\xE4\x64\x4F\x48"
754 "\x8A\x7A\x5A\x52\xDE\xEE\x65\x62"
755 "\x07\xC5\x62\xF9\x88\xE9\x5C\x69"
756 "\x16\xBD\xC8\x03\x1B\xC5\xBE\x1B"
757 "\x7B\x94\x76\x39\xFE\x05\x0B\x56"
758 "\x93\x9B\xAA\xA0\xAD\xFF\x9A\xE6"
759 "\x74\x5B\x7B\x18\x1C\x3B\xE3\xFD",
760 },
761};
762
763#define WP384_TEST_VECTORS 8
764
765static struct hash_testvec wp384_tv_template[] = {
766 {
767 .plaintext = "",
768 .psize = 0,
769 .digest = "\x19\xFA\x61\xD7\x55\x22\xA4\x66"
770 "\x9B\x44\xE3\x9C\x1D\x2E\x17\x26"
771 "\xC5\x30\x23\x21\x30\xD4\x07\xF8"
772 "\x9A\xFE\xE0\x96\x49\x97\xF7\xA7"
773 "\x3E\x83\xBE\x69\x8B\x28\x8F\xEB"
774 "\xCF\x88\xE3\xE0\x3C\x4F\x07\x57",
775
776
777 }, {
778 .plaintext = "a",
779 .psize = 1,
780 .digest = "\x8A\xCA\x26\x02\x79\x2A\xEC\x6F"
781 "\x11\xA6\x72\x06\x53\x1F\xB7\xD7"
782 "\xF0\xDF\xF5\x94\x13\x14\x5E\x69"
783 "\x73\xC4\x50\x01\xD0\x08\x7B\x42"
784 "\xD1\x1B\xC6\x45\x41\x3A\xEF\xF6"
785 "\x3A\x42\x39\x1A\x39\x14\x5A\x59",
786 }, {
787 .plaintext = "abc",
788 .psize = 3,
789 .digest = "\x4E\x24\x48\xA4\xC6\xF4\x86\xBB"
790 "\x16\xB6\x56\x2C\x73\xB4\x02\x0B"
791 "\xF3\x04\x3E\x3A\x73\x1B\xCE\x72"
792 "\x1A\xE1\xB3\x03\xD9\x7E\x6D\x4C"
793 "\x71\x81\xEE\xBD\xB6\xC5\x7E\x27"
794 "\x7D\x0E\x34\x95\x71\x14\xCB\xD6",
795 }, {
796 .plaintext = "message digest",
797 .psize = 14,
798 .digest = "\x37\x8C\x84\xA4\x12\x6E\x2D\xC6"
799 "\xE5\x6D\xCC\x74\x58\x37\x7A\xAC"
800 "\x83\x8D\x00\x03\x22\x30\xF5\x3C"
801 "\xE1\xF5\x70\x0C\x0F\xFB\x4D\x3B"
802 "\x84\x21\x55\x76\x59\xEF\x55\xC1"
803 "\x06\xB4\xB5\x2A\xC5\xA4\xAA\xA6",
804 }, {
805 .plaintext = "abcdefghijklmnopqrstuvwxyz",
806 .psize = 26,
807 .digest = "\xF1\xD7\x54\x66\x26\x36\xFF\xE9"
808 "\x2C\x82\xEB\xB9\x21\x2A\x48\x4A"
809 "\x8D\x38\x63\x1E\xAD\x42\x38\xF5"
810 "\x44\x2E\xE1\x3B\x80\x54\xE4\x1B"
811 "\x08\xBF\x2A\x92\x51\xC3\x0B\x6A"
812 "\x0B\x8A\xAE\x86\x17\x7A\xB4\xA6",
813 }, {
814 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
815 "abcdefghijklmnopqrstuvwxyz0123456789",
816 .psize = 62,
817 .digest = "\xDC\x37\xE0\x08\xCF\x9E\xE6\x9B"
818 "\xF1\x1F\x00\xED\x9A\xBA\x26\x90"
819 "\x1D\xD7\xC2\x8C\xDE\xC0\x66\xCC"
820 "\x6A\xF4\x2E\x40\xF8\x2F\x3A\x1E"
821 "\x08\xEB\xA2\x66\x29\x12\x9D\x8F"
822 "\xB7\xCB\x57\x21\x1B\x92\x81\xA6",
823 }, {
824 .plaintext = "1234567890123456789012345678901234567890"
825 "1234567890123456789012345678901234567890",
826 .psize = 80,
827 .digest = "\x46\x6E\xF1\x8B\xAB\xB0\x15\x4D"
828 "\x25\xB9\xD3\x8A\x64\x14\xF5\xC0"
829 "\x87\x84\x37\x2B\xCC\xB2\x04\xD6"
830 "\x54\x9C\x4A\xFA\xDB\x60\x14\x29"
831 "\x4D\x5B\xD8\xDF\x2A\x6C\x44\xE5"
832 "\x38\xCD\x04\x7B\x26\x81\xA5\x1A",
833 }, {
834 .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
835 .psize = 32,
836 .digest = "\x2A\x98\x7E\xA4\x0F\x91\x70\x61"
837 "\xF5\xD6\xF0\xA0\xE4\x64\x4F\x48"
838 "\x8A\x7A\x5A\x52\xDE\xEE\x65\x62"
839 "\x07\xC5\x62\xF9\x88\xE9\x5C\x69"
840 "\x16\xBD\xC8\x03\x1B\xC5\xBE\x1B"
841 "\x7B\x94\x76\x39\xFE\x05\x0B\x56",
842 },
843};
844
845#define WP256_TEST_VECTORS 8
846
847static struct hash_testvec wp256_tv_template[] = {
848 {
849 .plaintext = "",
850 .psize = 0,
851 .digest = "\x19\xFA\x61\xD7\x55\x22\xA4\x66"
852 "\x9B\x44\xE3\x9C\x1D\x2E\x17\x26"
853 "\xC5\x30\x23\x21\x30\xD4\x07\xF8"
854 "\x9A\xFE\xE0\x96\x49\x97\xF7\xA7",
855
856
857 }, {
858 .plaintext = "a",
859 .psize = 1,
860 .digest = "\x8A\xCA\x26\x02\x79\x2A\xEC\x6F"
861 "\x11\xA6\x72\x06\x53\x1F\xB7\xD7"
862 "\xF0\xDF\xF5\x94\x13\x14\x5E\x69"
863 "\x73\xC4\x50\x01\xD0\x08\x7B\x42",
864 }, {
865 .plaintext = "abc",
866 .psize = 3,
867 .digest = "\x4E\x24\x48\xA4\xC6\xF4\x86\xBB"
868 "\x16\xB6\x56\x2C\x73\xB4\x02\x0B"
869 "\xF3\x04\x3E\x3A\x73\x1B\xCE\x72"
870 "\x1A\xE1\xB3\x03\xD9\x7E\x6D\x4C",
871 }, {
872 .plaintext = "message digest",
873 .psize = 14,
874 .digest = "\x37\x8C\x84\xA4\x12\x6E\x2D\xC6"
875 "\xE5\x6D\xCC\x74\x58\x37\x7A\xAC"
876 "\x83\x8D\x00\x03\x22\x30\xF5\x3C"
877 "\xE1\xF5\x70\x0C\x0F\xFB\x4D\x3B",
878 }, {
879 .plaintext = "abcdefghijklmnopqrstuvwxyz",
880 .psize = 26,
881 .digest = "\xF1\xD7\x54\x66\x26\x36\xFF\xE9"
882 "\x2C\x82\xEB\xB9\x21\x2A\x48\x4A"
883 "\x8D\x38\x63\x1E\xAD\x42\x38\xF5"
884 "\x44\x2E\xE1\x3B\x80\x54\xE4\x1B",
885 }, {
886 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
887 "abcdefghijklmnopqrstuvwxyz0123456789",
888 .psize = 62,
889 .digest = "\xDC\x37\xE0\x08\xCF\x9E\xE6\x9B"
890 "\xF1\x1F\x00\xED\x9A\xBA\x26\x90"
891 "\x1D\xD7\xC2\x8C\xDE\xC0\x66\xCC"
892 "\x6A\xF4\x2E\x40\xF8\x2F\x3A\x1E",
893 }, {
894 .plaintext = "1234567890123456789012345678901234567890"
895 "1234567890123456789012345678901234567890",
896 .psize = 80,
897 .digest = "\x46\x6E\xF1\x8B\xAB\xB0\x15\x4D"
898 "\x25\xB9\xD3\x8A\x64\x14\xF5\xC0"
899 "\x87\x84\x37\x2B\xCC\xB2\x04\xD6"
900 "\x54\x9C\x4A\xFA\xDB\x60\x14\x29",
901 }, {
902 .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
903 .psize = 32,
904 .digest = "\x2A\x98\x7E\xA4\x0F\x91\x70\x61"
905 "\xF5\xD6\xF0\xA0\xE4\x64\x4F\x48"
906 "\x8A\x7A\x5A\x52\xDE\xEE\x65\x62"
907 "\x07\xC5\x62\xF9\x88\xE9\x5C\x69",
908 },
909};
910
911
912
913
914#define TGR192_TEST_VECTORS 6
915
916static struct hash_testvec tgr192_tv_template[] = {
917 {
918 .plaintext = "",
919 .psize = 0,
920 .digest = "\x24\xf0\x13\x0c\x63\xac\x93\x32"
921 "\x16\x16\x6e\x76\xb1\xbb\x92\x5f"
922 "\xf3\x73\xde\x2d\x49\x58\x4e\x7a",
923 }, {
924 .plaintext = "abc",
925 .psize = 3,
926 .digest = "\xf2\x58\xc1\xe8\x84\x14\xab\x2a"
927 "\x52\x7a\xb5\x41\xff\xc5\xb8\xbf"
928 "\x93\x5f\x7b\x95\x1c\x13\x29\x51",
929 }, {
930 .plaintext = "Tiger",
931 .psize = 5,
932 .digest = "\x9f\x00\xf5\x99\x07\x23\x00\xdd"
933 "\x27\x6a\xbb\x38\xc8\xeb\x6d\xec"
934 "\x37\x79\x0c\x11\x6f\x9d\x2b\xdf",
935 }, {
936 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-",
937 .psize = 64,
938 .digest = "\x87\xfb\x2a\x90\x83\x85\x1c\xf7"
939 "\x47\x0d\x2c\xf8\x10\xe6\xdf\x9e"
940 "\xb5\x86\x44\x50\x34\xa5\xa3\x86",
941 }, {
942 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ=abcdefghijklmnopqrstuvwxyz+0123456789",
943 .psize = 64,
944 .digest = "\x46\x7d\xb8\x08\x63\xeb\xce\x48"
945 "\x8d\xf1\xcd\x12\x61\x65\x5d\xe9"
946 "\x57\x89\x65\x65\x97\x5f\x91\x97",
947 }, {
948 .plaintext = "Tiger - A Fast New Hash Function, "
949 "by Ross Anderson and Eli Biham, "
950 "proceedings of Fast Software Encryption 3, "
951 "Cambridge, 1996.",
952 .psize = 125,
953 .digest = "\x3d\x9a\xeb\x03\xd1\xbd\x1a\x63"
954 "\x57\xb2\x77\x4d\xfd\x6d\x5b\x24"
955 "\xdd\x68\x15\x1d\x50\x39\x74\xfc",
956 },
957};
958
959#define TGR160_TEST_VECTORS 6
960
961static struct hash_testvec tgr160_tv_template[] = {
962 {
963 .plaintext = "",
964 .psize = 0,
965 .digest = "\x24\xf0\x13\x0c\x63\xac\x93\x32"
966 "\x16\x16\x6e\x76\xb1\xbb\x92\x5f"
967 "\xf3\x73\xde\x2d",
968 }, {
969 .plaintext = "abc",
970 .psize = 3,
971 .digest = "\xf2\x58\xc1\xe8\x84\x14\xab\x2a"
972 "\x52\x7a\xb5\x41\xff\xc5\xb8\xbf"
973 "\x93\x5f\x7b\x95",
974 }, {
975 .plaintext = "Tiger",
976 .psize = 5,
977 .digest = "\x9f\x00\xf5\x99\x07\x23\x00\xdd"
978 "\x27\x6a\xbb\x38\xc8\xeb\x6d\xec"
979 "\x37\x79\x0c\x11",
980 }, {
981 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-",
982 .psize = 64,
983 .digest = "\x87\xfb\x2a\x90\x83\x85\x1c\xf7"
984 "\x47\x0d\x2c\xf8\x10\xe6\xdf\x9e"
985 "\xb5\x86\x44\x50",
986 }, {
987 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ=abcdefghijklmnopqrstuvwxyz+0123456789",
988 .psize = 64,
989 .digest = "\x46\x7d\xb8\x08\x63\xeb\xce\x48"
990 "\x8d\xf1\xcd\x12\x61\x65\x5d\xe9"
991 "\x57\x89\x65\x65",
992 }, {
993 .plaintext = "Tiger - A Fast New Hash Function, "
994 "by Ross Anderson and Eli Biham, "
995 "proceedings of Fast Software Encryption 3, "
996 "Cambridge, 1996.",
997 .psize = 125,
998 .digest = "\x3d\x9a\xeb\x03\xd1\xbd\x1a\x63"
999 "\x57\xb2\x77\x4d\xfd\x6d\x5b\x24"
1000 "\xdd\x68\x15\x1d",
1001 },
1002};
1003
1004#define TGR128_TEST_VECTORS 6
1005
1006static struct hash_testvec tgr128_tv_template[] = {
1007 {
1008 .plaintext = "",
1009 .psize = 0,
1010 .digest = "\x24\xf0\x13\x0c\x63\xac\x93\x32"
1011 "\x16\x16\x6e\x76\xb1\xbb\x92\x5f",
1012 }, {
1013 .plaintext = "abc",
1014 .psize = 3,
1015 .digest = "\xf2\x58\xc1\xe8\x84\x14\xab\x2a"
1016 "\x52\x7a\xb5\x41\xff\xc5\xb8\xbf",
1017 }, {
1018 .plaintext = "Tiger",
1019 .psize = 5,
1020 .digest = "\x9f\x00\xf5\x99\x07\x23\x00\xdd"
1021 "\x27\x6a\xbb\x38\xc8\xeb\x6d\xec",
1022 }, {
1023 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-",
1024 .psize = 64,
1025 .digest = "\x87\xfb\x2a\x90\x83\x85\x1c\xf7"
1026 "\x47\x0d\x2c\xf8\x10\xe6\xdf\x9e",
1027 }, {
1028 .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ=abcdefghijklmnopqrstuvwxyz+0123456789",
1029 .psize = 64,
1030 .digest = "\x46\x7d\xb8\x08\x63\xeb\xce\x48"
1031 "\x8d\xf1\xcd\x12\x61\x65\x5d\xe9",
1032 }, {
1033 .plaintext = "Tiger - A Fast New Hash Function, "
1034 "by Ross Anderson and Eli Biham, "
1035 "proceedings of Fast Software Encryption 3, "
1036 "Cambridge, 1996.",
1037 .psize = 125,
1038 .digest = "\x3d\x9a\xeb\x03\xd1\xbd\x1a\x63"
1039 "\x57\xb2\x77\x4d\xfd\x6d\x5b\x24",
1040 },
1041};
1042
1043#define GHASH_TEST_VECTORS 1
1044
1045static struct hash_testvec ghash_tv_template[] =
1046{
1047 {
1048
1049 .key = "\xdf\xa6\xbf\x4d\xed\x81\xdb\x03\xff\xca\xff\x95\xf8\x30\xf0\x61",
1050 .ksize = 16,
1051 .plaintext = "\x95\x2b\x2a\x56\xa5\x60\x04a\xc0\xb3\x2b\x66\x56\xa0\x5b\x40\xb6",
1052 .psize = 16,
1053 .digest = "\xda\x53\xeb\x0a\xd2\xc5\x5b\xb6"
1054 "\x4f\xc4\x80\x2c\xc3\xfe\xda\x60",
1055 },
1056};
1057
1058
1059
1060
1061
1062#define HMAC_MD5_TEST_VECTORS 7
1063
1064static struct hash_testvec hmac_md5_tv_template[] =
1065{
1066 {
1067 .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b",
1068 .ksize = 16,
1069 .plaintext = "Hi There",
1070 .psize = 8,
1071 .digest = "\x92\x94\x72\x7a\x36\x38\xbb\x1c"
1072 "\x13\xf4\x8e\xf8\x15\x8b\xfc\x9d",
1073 }, {
1074 .key = "Jefe",
1075 .ksize = 4,
1076 .plaintext = "what do ya want for nothing?",
1077 .psize = 28,
1078 .digest = "\x75\x0c\x78\x3e\x6a\xb0\xb5\x03"
1079 "\xea\xa8\x6e\x31\x0a\x5d\xb7\x38",
1080 .np = 2,
1081 .tap = {14, 14}
1082 }, {
1083 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
1084 .ksize = 16,
1085 .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1086 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1087 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1088 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
1089 .psize = 50,
1090 .digest = "\x56\xbe\x34\x52\x1d\x14\x4c\x88"
1091 "\xdb\xb8\xc7\x33\xf0\xe8\xb3\xf6",
1092 }, {
1093 .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
1094 "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
1095 "\x11\x12\x13\x14\x15\x16\x17\x18\x19",
1096 .ksize = 25,
1097 .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1098 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1099 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1100 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
1101 .psize = 50,
1102 .digest = "\x69\x7e\xaf\x0a\xca\x3a\x3a\xea"
1103 "\x3a\x75\x16\x47\x46\xff\xaa\x79",
1104 }, {
1105 .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c",
1106 .ksize = 16,
1107 .plaintext = "Test With Truncation",
1108 .psize = 20,
1109 .digest = "\x56\x46\x1e\xf2\x34\x2e\xdc\x00"
1110 "\xf9\xba\xb9\x95\x69\x0e\xfd\x4c",
1111 }, {
1112 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1113 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1114 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1115 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1116 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1117 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1118 "\xaa\xaa",
1119 .ksize = 80,
1120 .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
1121 .psize = 54,
1122 .digest = "\x6b\x1a\xb7\xfe\x4b\xd7\xbf\x8f"
1123 "\x0b\x62\xe6\xce\x61\xb9\xd0\xcd",
1124 }, {
1125 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1126 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1127 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1128 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1129 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1130 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1131 "\xaa\xaa",
1132 .ksize = 80,
1133 .plaintext = "Test Using Larger Than Block-Size Key and Larger Than One "
1134 "Block-Size Data",
1135 .psize = 73,
1136 .digest = "\x6f\x63\x0f\xad\x67\xcd\xa0\xee"
1137 "\x1f\xb1\xf5\x62\xdb\x3a\xa5\x3e",
1138 },
1139};
1140
1141
1142
1143
1144#define HMAC_RMD128_TEST_VECTORS 7
1145
1146static struct hash_testvec hmac_rmd128_tv_template[] = {
1147 {
1148 .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b",
1149 .ksize = 16,
1150 .plaintext = "Hi There",
1151 .psize = 8,
1152 .digest = "\xfb\xf6\x1f\x94\x92\xaa\x4b\xbf"
1153 "\x81\xc1\x72\xe8\x4e\x07\x34\xdb",
1154 }, {
1155 .key = "Jefe",
1156 .ksize = 4,
1157 .plaintext = "what do ya want for nothing?",
1158 .psize = 28,
1159 .digest = "\x87\x5f\x82\x88\x62\xb6\xb3\x34"
1160 "\xb4\x27\xc5\x5f\x9f\x7f\xf0\x9b",
1161 .np = 2,
1162 .tap = { 14, 14 },
1163 }, {
1164 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
1165 .ksize = 16,
1166 .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1167 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1168 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1169 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
1170 .psize = 50,
1171 .digest = "\x09\xf0\xb2\x84\x6d\x2f\x54\x3d"
1172 "\xa3\x63\xcb\xec\x8d\x62\xa3\x8d",
1173 }, {
1174 .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
1175 "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
1176 "\x11\x12\x13\x14\x15\x16\x17\x18\x19",
1177 .ksize = 25,
1178 .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1179 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1180 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1181 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
1182 .psize = 50,
1183 .digest = "\xbd\xbb\xd7\xcf\x03\xe4\x4b\x5a"
1184 "\xa6\x0a\xf8\x15\xbe\x4d\x22\x94",
1185 }, {
1186 .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c",
1187 .ksize = 16,
1188 .plaintext = "Test With Truncation",
1189 .psize = 20,
1190 .digest = "\xe7\x98\x08\xf2\x4b\x25\xfd\x03"
1191 "\x1c\x15\x5f\x0d\x55\x1d\x9a\x3a",
1192 }, {
1193 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1194 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1195 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1196 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1197 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1198 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1199 "\xaa\xaa",
1200 .ksize = 80,
1201 .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
1202 .psize = 54,
1203 .digest = "\xdc\x73\x29\x28\xde\x98\x10\x4a"
1204 "\x1f\x59\xd3\x73\xc1\x50\xac\xbb",
1205 }, {
1206 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1207 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1208 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1209 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1210 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1211 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1212 "\xaa\xaa",
1213 .ksize = 80,
1214 .plaintext = "Test Using Larger Than Block-Size Key and Larger Than One "
1215 "Block-Size Data",
1216 .psize = 73,
1217 .digest = "\x5c\x6b\xec\x96\x79\x3e\x16\xd4"
1218 "\x06\x90\xc2\x37\x63\x5f\x30\xc5",
1219 },
1220};
1221
1222
1223
1224
1225#define HMAC_RMD160_TEST_VECTORS 7
1226
1227static struct hash_testvec hmac_rmd160_tv_template[] = {
1228 {
1229 .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b",
1230 .ksize = 20,
1231 .plaintext = "Hi There",
1232 .psize = 8,
1233 .digest = "\x24\xcb\x4b\xd6\x7d\x20\xfc\x1a\x5d\x2e"
1234 "\xd7\x73\x2d\xcc\x39\x37\x7f\x0a\x56\x68",
1235 }, {
1236 .key = "Jefe",
1237 .ksize = 4,
1238 .plaintext = "what do ya want for nothing?",
1239 .psize = 28,
1240 .digest = "\xdd\xa6\xc0\x21\x3a\x48\x5a\x9e\x24\xf4"
1241 "\x74\x20\x64\xa7\xf0\x33\xb4\x3c\x40\x69",
1242 .np = 2,
1243 .tap = { 14, 14 },
1244 }, {
1245 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
1246 .ksize = 20,
1247 .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1248 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1249 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1250 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
1251 .psize = 50,
1252 .digest = "\xb0\xb1\x05\x36\x0d\xe7\x59\x96\x0a\xb4"
1253 "\xf3\x52\x98\xe1\x16\xe2\x95\xd8\xe7\xc1",
1254 }, {
1255 .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
1256 "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
1257 "\x11\x12\x13\x14\x15\x16\x17\x18\x19",
1258 .ksize = 25,
1259 .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1260 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1261 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1262 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
1263 .psize = 50,
1264 .digest = "\xd5\xca\x86\x2f\x4d\x21\xd5\xe6\x10\xe1"
1265 "\x8b\x4c\xf1\xbe\xb9\x7a\x43\x65\xec\xf4",
1266 }, {
1267 .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c",
1268 .ksize = 20,
1269 .plaintext = "Test With Truncation",
1270 .psize = 20,
1271 .digest = "\x76\x19\x69\x39\x78\xf9\x1d\x90\x53\x9a"
1272 "\xe7\x86\x50\x0f\xf3\xd8\xe0\x51\x8e\x39",
1273 }, {
1274 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1275 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1276 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1277 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1278 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1279 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1280 "\xaa\xaa",
1281 .ksize = 80,
1282 .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
1283 .psize = 54,
1284 .digest = "\x64\x66\xca\x07\xac\x5e\xac\x29\xe1\xbd"
1285 "\x52\x3e\x5a\xda\x76\x05\xb7\x91\xfd\x8b",
1286 }, {
1287 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1288 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1289 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1290 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1291 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1292 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1293 "\xaa\xaa",
1294 .ksize = 80,
1295 .plaintext = "Test Using Larger Than Block-Size Key and Larger Than One "
1296 "Block-Size Data",
1297 .psize = 73,
1298 .digest = "\x69\xea\x60\x79\x8d\x71\x61\x6c\xce\x5f"
1299 "\xd0\x87\x1e\x23\x75\x4c\xd7\x5d\x5a\x0a",
1300 },
1301};
1302
1303
1304
1305
1306#define HMAC_SHA1_TEST_VECTORS 7
1307
1308static struct hash_testvec hmac_sha1_tv_template[] = {
1309 {
1310 .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b",
1311 .ksize = 20,
1312 .plaintext = "Hi There",
1313 .psize = 8,
1314 .digest = "\xb6\x17\x31\x86\x55\x05\x72\x64"
1315 "\xe2\x8b\xc0\xb6\xfb\x37\x8c\x8e\xf1"
1316 "\x46\xbe",
1317 }, {
1318 .key = "Jefe",
1319 .ksize = 4,
1320 .plaintext = "what do ya want for nothing?",
1321 .psize = 28,
1322 .digest = "\xef\xfc\xdf\x6a\xe5\xeb\x2f\xa2\xd2\x74"
1323 "\x16\xd5\xf1\x84\xdf\x9c\x25\x9a\x7c\x79",
1324 .np = 2,
1325 .tap = { 14, 14 }
1326 }, {
1327 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
1328 .ksize = 20,
1329 .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1330 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1331 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1332 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
1333 .psize = 50,
1334 .digest = "\x12\x5d\x73\x42\xb9\xac\x11\xcd\x91\xa3"
1335 "\x9a\xf4\x8a\xa1\x7b\x4f\x63\xf1\x75\xd3",
1336 }, {
1337 .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
1338 "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
1339 "\x11\x12\x13\x14\x15\x16\x17\x18\x19",
1340 .ksize = 25,
1341 .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1342 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1343 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1344 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
1345 .psize = 50,
1346 .digest = "\x4c\x90\x07\xf4\x02\x62\x50\xc6\xbc\x84"
1347 "\x14\xf9\xbf\x50\xc8\x6c\x2d\x72\x35\xda",
1348 }, {
1349 .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c",
1350 .ksize = 20,
1351 .plaintext = "Test With Truncation",
1352 .psize = 20,
1353 .digest = "\x4c\x1a\x03\x42\x4b\x55\xe0\x7f\xe7\xf2"
1354 "\x7b\xe1\xd5\x8b\xb9\x32\x4a\x9a\x5a\x04",
1355 }, {
1356 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1357 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1358 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1359 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1360 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1361 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1362 "\xaa\xaa",
1363 .ksize = 80,
1364 .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
1365 .psize = 54,
1366 .digest = "\xaa\x4a\xe5\xe1\x52\x72\xd0\x0e\x95\x70"
1367 "\x56\x37\xce\x8a\x3b\x55\xed\x40\x21\x12",
1368 }, {
1369 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1370 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1371 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1372 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1373 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1374 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1375 "\xaa\xaa",
1376 .ksize = 80,
1377 .plaintext = "Test Using Larger Than Block-Size Key and Larger Than One "
1378 "Block-Size Data",
1379 .psize = 73,
1380 .digest = "\xe8\xe9\x9d\x0f\x45\x23\x7d\x78\x6d\x6b"
1381 "\xba\xa7\x96\x5c\x78\x08\xbb\xff\x1a\x91",
1382 },
1383};
1384
1385
1386
1387
1388
1389#define HMAC_SHA224_TEST_VECTORS 4
1390
1391static struct hash_testvec hmac_sha224_tv_template[] = {
1392 {
1393 .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
1394 "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
1395 "\x0b\x0b\x0b\x0b",
1396 .ksize = 20,
1397
1398 .plaintext = "\x48\x69\x20\x54\x68\x65\x72\x65",
1399 .psize = 8,
1400 .digest = "\x89\x6f\xb1\x12\x8a\xbb\xdf\x19"
1401 "\x68\x32\x10\x7c\xd4\x9d\xf3\x3f"
1402 "\x47\xb4\xb1\x16\x99\x12\xba\x4f"
1403 "\x53\x68\x4b\x22",
1404 }, {
1405 .key = "Jefe",
1406 .ksize = 4,
1407
1408 .plaintext = "\x77\x68\x61\x74\x20\x64\x6f\x20"
1409 "\x79\x61\x20\x77\x61\x6e\x74\x20"
1410 "\x66\x6f\x72\x20\x6e\x6f\x74\x68"
1411 "\x69\x6e\x67\x3f",
1412 .psize = 28,
1413 .digest = "\xa3\x0e\x01\x09\x8b\xc6\xdb\xbf"
1414 "\x45\x69\x0f\x3a\x7e\x9e\x6d\x0f"
1415 "\x8b\xbe\xa2\xa3\x9e\x61\x48\x00"
1416 "\x8f\xd0\x5e\x44",
1417 .np = 4,
1418 .tap = { 7, 7, 7, 7 }
1419 }, {
1420 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1421 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1422 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1423 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1424 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1425 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1426 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1427 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1428 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1429 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1430 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1431 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1432 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1433 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1434 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1435 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1436 "\xaa\xaa\xaa",
1437 .ksize = 131,
1438
1439 .plaintext = "\x54\x65\x73\x74\x20\x55\x73\x69"
1440 "\x6e\x67\x20\x4c\x61\x72\x67\x65"
1441 "\x72\x20\x54\x68\x61\x6e\x20\x42"
1442 "\x6c\x6f\x63\x6b\x2d\x53\x69\x7a"
1443 "\x65\x20\x4b\x65\x79\x20\x2d\x20"
1444 "\x48\x61\x73\x68\x20\x4b\x65\x79"
1445 "\x20\x46\x69\x72\x73\x74",
1446 .psize = 54,
1447 .digest = "\x95\xe9\xa0\xdb\x96\x20\x95\xad"
1448 "\xae\xbe\x9b\x2d\x6f\x0d\xbc\xe2"
1449 "\xd4\x99\xf1\x12\xf2\xd2\xb7\x27"
1450 "\x3f\xa6\x87\x0e",
1451 }, {
1452 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1453 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1454 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1455 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1456 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1457 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1458 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1459 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1460 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1461 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1462 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1463 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1464 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1465 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1466 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1467 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1468 "\xaa\xaa\xaa",
1469 .ksize = 131,
1470
1471
1472
1473 .plaintext = "\x54\x68\x69\x73\x20\x69\x73\x20"
1474 "\x61\x20\x74\x65\x73\x74\x20\x75"
1475 "\x73\x69\x6e\x67\x20\x61\x20\x6c"
1476 "\x61\x72\x67\x65\x72\x20\x74\x68"
1477 "\x61\x6e\x20\x62\x6c\x6f\x63\x6b"
1478 "\x2d\x73\x69\x7a\x65\x20\x6b\x65"
1479 "\x79\x20\x61\x6e\x64\x20\x61\x20"
1480 "\x6c\x61\x72\x67\x65\x72\x20\x74"
1481 "\x68\x61\x6e\x20\x62\x6c\x6f\x63"
1482 "\x6b\x2d\x73\x69\x7a\x65\x20\x64"
1483 "\x61\x74\x61\x2e\x20\x54\x68\x65"
1484 "\x20\x6b\x65\x79\x20\x6e\x65\x65"
1485 "\x64\x73\x20\x74\x6f\x20\x62\x65"
1486 "\x20\x68\x61\x73\x68\x65\x64\x20"
1487 "\x62\x65\x66\x6f\x72\x65\x20\x62"
1488 "\x65\x69\x6e\x67\x20\x75\x73\x65"
1489 "\x64\x20\x62\x79\x20\x74\x68\x65"
1490 "\x20\x48\x4d\x41\x43\x20\x61\x6c"
1491 "\x67\x6f\x72\x69\x74\x68\x6d\x2e",
1492 .psize = 152,
1493 .digest = "\x3a\x85\x41\x66\xac\x5d\x9f\x02"
1494 "\x3f\x54\xd5\x17\xd0\xb3\x9d\xbd"
1495 "\x94\x67\x70\xdb\x9c\x2b\x95\xc9"
1496 "\xf6\xf5\x65\xd1",
1497 },
1498};
1499
1500
1501
1502
1503
1504#define HMAC_SHA256_TEST_VECTORS 10
1505
1506static struct hash_testvec hmac_sha256_tv_template[] = {
1507 {
1508 .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
1509 "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
1510 "\x11\x12\x13\x14\x15\x16\x17\x18"
1511 "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20",
1512 .ksize = 32,
1513 .plaintext = "abc",
1514 .psize = 3,
1515 .digest = "\xa2\x1b\x1f\x5d\x4c\xf4\xf7\x3a"
1516 "\x4d\xd9\x39\x75\x0f\x7a\x06\x6a"
1517 "\x7f\x98\xcc\x13\x1c\xb1\x6a\x66"
1518 "\x92\x75\x90\x21\xcf\xab\x81\x81",
1519 }, {
1520 .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
1521 "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
1522 "\x11\x12\x13\x14\x15\x16\x17\x18"
1523 "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20",
1524 .ksize = 32,
1525 .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
1526 .psize = 56,
1527 .digest = "\x10\x4f\xdc\x12\x57\x32\x8f\x08"
1528 "\x18\x4b\xa7\x31\x31\xc5\x3c\xae"
1529 "\xe6\x98\xe3\x61\x19\x42\x11\x49"
1530 "\xea\x8c\x71\x24\x56\x69\x7d\x30",
1531 }, {
1532 .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
1533 "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
1534 "\x11\x12\x13\x14\x15\x16\x17\x18"
1535 "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20",
1536 .ksize = 32,
1537 .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq"
1538 "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
1539 .psize = 112,
1540 .digest = "\x47\x03\x05\xfc\x7e\x40\xfe\x34"
1541 "\xd3\xee\xb3\xe7\x73\xd9\x5a\xab"
1542 "\x73\xac\xf0\xfd\x06\x04\x47\xa5"
1543 "\xeb\x45\x95\xbf\x33\xa9\xd1\xa3",
1544 }, {
1545 .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
1546 "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
1547 "\x0b\x0b\x0b\x0b\x0b\x0b",
1548 .ksize = 32,
1549 .plaintext = "Hi There",
1550 .psize = 8,
1551 .digest = "\x19\x8a\x60\x7e\xb4\x4b\xfb\xc6"
1552 "\x99\x03\xa0\xf1\xcf\x2b\xbd\xc5"
1553 "\xba\x0a\xa3\xf3\xd9\xae\x3c\x1c"
1554 "\x7a\x3b\x16\x96\xa0\xb6\x8c\xf7",
1555 }, {
1556 .key = "Jefe",
1557 .ksize = 4,
1558 .plaintext = "what do ya want for nothing?",
1559 .psize = 28,
1560 .digest = "\x5b\xdc\xc1\x46\xbf\x60\x75\x4e"
1561 "\x6a\x04\x24\x26\x08\x95\x75\xc7"
1562 "\x5a\x00\x3f\x08\x9d\x27\x39\x83"
1563 "\x9d\xec\x58\xb9\x64\xec\x38\x43",
1564 .np = 2,
1565 .tap = { 14, 14 }
1566 }, {
1567 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1568 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1569 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
1570 .ksize = 32,
1571 .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1572 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1573 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
1574 "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
1575 .psize = 50,
1576 .digest = "\xcd\xcb\x12\x20\xd1\xec\xcc\xea"
1577 "\x91\xe5\x3a\xba\x30\x92\xf9\x62"
1578 "\xe5\x49\xfe\x6c\xe9\xed\x7f\xdc"
1579 "\x43\x19\x1f\xbd\xe4\x5c\x30\xb0",
1580 }, {
1581 .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
1582 "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
1583 "\x11\x12\x13\x14\x15\x16\x17\x18"
1584 "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20"
1585 "\x21\x22\x23\x24\x25",
1586 .ksize = 37,
1587 .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1588 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1589 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
1590 "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
1591 .psize = 50,
1592 .digest = "\xd4\x63\x3c\x17\xf6\xfb\x8d\x74"
1593 "\x4c\x66\xde\xe0\xf8\xf0\x74\x55"
1594 "\x6e\xc4\xaf\x55\xef\x07\x99\x85"
1595 "\x41\x46\x8e\xb4\x9b\xd2\xe9\x17",
1596 }, {
1597 .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c"
1598 "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c"
1599 "\x0c\x0c\x0c\x0c\x0c\x0c",
1600 .ksize = 32,
1601 .plaintext = "Test With Truncation",
1602 .psize = 20,
1603 .digest = "\x75\x46\xaf\x01\x84\x1f\xc0\x9b"
1604 "\x1a\xb9\xc3\x74\x9a\x5f\x1c\x17"
1605 "\xd4\xf5\x89\x66\x8a\x58\x7b\x27"
1606 "\x00\xa9\xc9\x7c\x11\x93\xcf\x42",
1607 }, {
1608 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1609 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1610 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1611 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1612 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1613 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1614 "\xaa\xaa",
1615 .ksize = 80,
1616 .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
1617 .psize = 54,
1618 .digest = "\x69\x53\x02\x5e\xd9\x6f\x0c\x09"
1619 "\xf8\x0a\x96\xf7\x8e\x65\x38\xdb"
1620 "\xe2\xe7\xb8\x20\xe3\xdd\x97\x0e"
1621 "\x7d\xdd\x39\x09\x1b\x32\x35\x2f",
1622 }, {
1623 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1624 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1625 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1626 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1627 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1628 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1629 "\xaa\xaa",
1630 .ksize = 80,
1631 .plaintext = "Test Using Larger Than Block-Size Key and Larger Than "
1632 "One Block-Size Data",
1633 .psize = 73,
1634 .digest = "\x63\x55\xac\x22\xe8\x90\xd0\xa3"
1635 "\xc8\x48\x1a\x5c\xa4\x82\x5b\xc8"
1636 "\x84\xd3\xe7\xa1\xff\x98\xa2\xfc"
1637 "\x2a\xc7\xd8\xe0\x64\xc3\xb2\xe6",
1638 },
1639};
1640
1641#define XCBC_AES_TEST_VECTORS 6
1642
1643static struct hash_testvec aes_xcbc128_tv_template[] = {
1644 {
1645 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1646 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1647 .plaintext = zeroed_string,
1648 .digest = "\x75\xf0\x25\x1d\x52\x8a\xc0\x1c"
1649 "\x45\x73\xdf\xd5\x84\xd7\x9f\x29",
1650 .psize = 0,
1651 .ksize = 16,
1652 }, {
1653 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1654 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1655 .plaintext = "\x00\x01\x02",
1656 .digest = "\x5b\x37\x65\x80\xae\x2f\x19\xaf"
1657 "\xe7\x21\x9c\xee\xf1\x72\x75\x6f",
1658 .psize = 3,
1659 .ksize = 16,
1660 } , {
1661 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1662 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1663 .plaintext = "\x00\x01\x02\x03\x04\x05\x06\x07"
1664 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1665 .digest = "\xd2\xa2\x46\xfa\x34\x9b\x68\xa7"
1666 "\x99\x98\xa4\x39\x4f\xf7\xa2\x63",
1667 .psize = 16,
1668 .ksize = 16,
1669 }, {
1670 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1671 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1672 .plaintext = "\x00\x01\x02\x03\x04\x05\x06\x07"
1673 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
1674 "\x10\x11\x12\x13",
1675 .digest = "\x47\xf5\x1b\x45\x64\x96\x62\x15"
1676 "\xb8\x98\x5c\x63\x05\x5e\xd3\x08",
1677 .tap = { 10, 10 },
1678 .psize = 20,
1679 .np = 2,
1680 .ksize = 16,
1681 }, {
1682 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1683 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1684 .plaintext = "\x00\x01\x02\x03\x04\x05\x06\x07"
1685 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
1686 "\x10\x11\x12\x13\x14\x15\x16\x17"
1687 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
1688 .digest = "\xf5\x4f\x0e\xc8\xd2\xb9\xf3\xd3"
1689 "\x68\x07\x73\x4b\xd5\x28\x3f\xd4",
1690 .psize = 32,
1691 .ksize = 16,
1692 }, {
1693 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1694 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1695 .plaintext = "\x00\x01\x02\x03\x04\x05\x06\x07"
1696 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
1697 "\x10\x11\x12\x13\x14\x15\x16\x17"
1698 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
1699 "\x20\x21",
1700 .digest = "\xbe\xcb\xb3\xbc\xcd\xb5\x18\xa3"
1701 "\x06\x77\xd5\x48\x1f\xb6\xb4\xd8",
1702 .tap = { 17, 17 },
1703 .psize = 34,
1704 .np = 2,
1705 .ksize = 16,
1706 }
1707};
1708
1709#define VMAC_AES_TEST_VECTORS 8
1710static char vmac_string1[128] = {'\x01', '\x01', '\x01', '\x01',
1711 '\x02', '\x03', '\x02', '\x02',
1712 '\x02', '\x04', '\x01', '\x07',
1713 '\x04', '\x01', '\x04', '\x03',};
1714static char vmac_string2[128] = {'a', 'b', 'c',};
1715static char vmac_string3[128] = {'a', 'b', 'c', 'a', 'b', 'c',
1716 'a', 'b', 'c', 'a', 'b', 'c',
1717 'a', 'b', 'c', 'a', 'b', 'c',
1718 'a', 'b', 'c', 'a', 'b', 'c',
1719 'a', 'b', 'c', 'a', 'b', 'c',
1720 'a', 'b', 'c', 'a', 'b', 'c',
1721 'a', 'b', 'c', 'a', 'b', 'c',
1722 'a', 'b', 'c', 'a', 'b', 'c',
1723 };
1724
1725static struct hash_testvec aes_vmac128_tv_template[] = {
1726 {
1727 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1728 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1729 .plaintext = NULL,
1730 .digest = "\x07\x58\x80\x35\x77\xa4\x7b\x54",
1731 .psize = 0,
1732 .ksize = 16,
1733 }, {
1734 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1735 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1736 .plaintext = vmac_string1,
1737 .digest = "\xce\xf5\x3c\xd3\xae\x68\x8c\xa1",
1738 .psize = 128,
1739 .ksize = 16,
1740 }, {
1741 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1742 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1743 .plaintext = vmac_string2,
1744 .digest = "\xc9\x27\xb0\x73\x81\xbd\x14\x2d",
1745 .psize = 128,
1746 .ksize = 16,
1747 }, {
1748 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
1749 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
1750 .plaintext = vmac_string3,
1751 .digest = "\x8d\x1a\x95\x8c\x98\x47\x0b\x19",
1752 .psize = 128,
1753 .ksize = 16,
1754 }, {
1755 .key = "abcdefghijklmnop",
1756 .plaintext = NULL,
1757 .digest = "\x3b\x89\xa1\x26\x9e\x55\x8f\x84",
1758 .psize = 0,
1759 .ksize = 16,
1760 }, {
1761 .key = "abcdefghijklmnop",
1762 .plaintext = vmac_string1,
1763 .digest = "\xab\x5e\xab\xb0\xf6\x8d\x74\xc2",
1764 .psize = 128,
1765 .ksize = 16,
1766 }, {
1767 .key = "abcdefghijklmnop",
1768 .plaintext = vmac_string2,
1769 .digest = "\x11\x15\x68\x42\x3d\x7b\x09\xdf",
1770 .psize = 128,
1771 .ksize = 16,
1772 }, {
1773 .key = "abcdefghijklmnop",
1774 .plaintext = vmac_string3,
1775 .digest = "\x8b\x32\x8f\xe1\xed\x8f\xfa\xd4",
1776 .psize = 128,
1777 .ksize = 16,
1778 },
1779};
1780
1781
1782
1783
1784
1785#define HMAC_SHA384_TEST_VECTORS 4
1786
1787static struct hash_testvec hmac_sha384_tv_template[] = {
1788 {
1789 .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
1790 "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
1791 "\x0b\x0b\x0b\x0b",
1792 .ksize = 20,
1793 .plaintext = "Hi There",
1794 .psize = 8,
1795 .digest = "\xaf\xd0\x39\x44\xd8\x48\x95\x62"
1796 "\x6b\x08\x25\xf4\xab\x46\x90\x7f"
1797 "\x15\xf9\xda\xdb\xe4\x10\x1e\xc6"
1798 "\x82\xaa\x03\x4c\x7c\xeb\xc5\x9c"
1799 "\xfa\xea\x9e\xa9\x07\x6e\xde\x7f"
1800 "\x4a\xf1\x52\xe8\xb2\xfa\x9c\xb6",
1801 }, {
1802 .key = "Jefe",
1803 .ksize = 4,
1804 .plaintext = "what do ya want for nothing?",
1805 .psize = 28,
1806 .digest = "\xaf\x45\xd2\xe3\x76\x48\x40\x31"
1807 "\x61\x7f\x78\xd2\xb5\x8a\x6b\x1b"
1808 "\x9c\x7e\xf4\x64\xf5\xa0\x1b\x47"
1809 "\xe4\x2e\xc3\x73\x63\x22\x44\x5e"
1810 "\x8e\x22\x40\xca\x5e\x69\xe2\xc7"
1811 "\x8b\x32\x39\xec\xfa\xb2\x16\x49",
1812 .np = 4,
1813 .tap = { 7, 7, 7, 7 }
1814 }, {
1815 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1816 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1817 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1818 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1819 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1820 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1821 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1822 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1823 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1824 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1825 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1826 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1827 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1828 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1829 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1830 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1831 "\xaa\xaa\xaa",
1832 .ksize = 131,
1833 .plaintext = "Test Using Larger Than Block-Siz"
1834 "e Key - Hash Key First",
1835 .psize = 54,
1836 .digest = "\x4e\xce\x08\x44\x85\x81\x3e\x90"
1837 "\x88\xd2\xc6\x3a\x04\x1b\xc5\xb4"
1838 "\x4f\x9e\xf1\x01\x2a\x2b\x58\x8f"
1839 "\x3c\xd1\x1f\x05\x03\x3a\xc4\xc6"
1840 "\x0c\x2e\xf6\xab\x40\x30\xfe\x82"
1841 "\x96\x24\x8d\xf1\x63\xf4\x49\x52",
1842 }, {
1843 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1844 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1845 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1846 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1847 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1848 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1849 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1850 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1851 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1852 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1853 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1854 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1855 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1856 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1857 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1858 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1859 "\xaa\xaa\xaa",
1860 .ksize = 131,
1861 .plaintext = "This is a test u"
1862 "sing a larger th"
1863 "an block-size ke"
1864 "y and a larger t"
1865 "han block-size d"
1866 "ata. The key nee"
1867 "ds to be hashed "
1868 "before being use"
1869 "d by the HMAC al"
1870 "gorithm.",
1871 .psize = 152,
1872 .digest = "\x66\x17\x17\x8e\x94\x1f\x02\x0d"
1873 "\x35\x1e\x2f\x25\x4e\x8f\xd3\x2c"
1874 "\x60\x24\x20\xfe\xb0\xb8\xfb\x9a"
1875 "\xdc\xce\xbb\x82\x46\x1e\x99\xc5"
1876 "\xa6\x78\xcc\x31\xe7\x99\x17\x6d"
1877 "\x38\x60\xe6\x11\x0c\x46\x52\x3e",
1878 },
1879};
1880
1881
1882
1883
1884
1885#define HMAC_SHA512_TEST_VECTORS 4
1886
1887static struct hash_testvec hmac_sha512_tv_template[] = {
1888 {
1889 .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
1890 "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
1891 "\x0b\x0b\x0b\x0b",
1892 .ksize = 20,
1893 .plaintext = "Hi There",
1894 .psize = 8,
1895 .digest = "\x87\xaa\x7c\xde\xa5\xef\x61\x9d"
1896 "\x4f\xf0\xb4\x24\x1a\x1d\x6c\xb0"
1897 "\x23\x79\xf4\xe2\xce\x4e\xc2\x78"
1898 "\x7a\xd0\xb3\x05\x45\xe1\x7c\xde"
1899 "\xda\xa8\x33\xb7\xd6\xb8\xa7\x02"
1900 "\x03\x8b\x27\x4e\xae\xa3\xf4\xe4"
1901 "\xbe\x9d\x91\x4e\xeb\x61\xf1\x70"
1902 "\x2e\x69\x6c\x20\x3a\x12\x68\x54",
1903 }, {
1904 .key = "Jefe",
1905 .ksize = 4,
1906 .plaintext = "what do ya want for nothing?",
1907 .psize = 28,
1908 .digest = "\x16\x4b\x7a\x7b\xfc\xf8\x19\xe2"
1909 "\xe3\x95\xfb\xe7\x3b\x56\xe0\xa3"
1910 "\x87\xbd\x64\x22\x2e\x83\x1f\xd6"
1911 "\x10\x27\x0c\xd7\xea\x25\x05\x54"
1912 "\x97\x58\xbf\x75\xc0\x5a\x99\x4a"
1913 "\x6d\x03\x4f\x65\xf8\xf0\xe6\xfd"
1914 "\xca\xea\xb1\xa3\x4d\x4a\x6b\x4b"
1915 "\x63\x6e\x07\x0a\x38\xbc\xe7\x37",
1916 .np = 4,
1917 .tap = { 7, 7, 7, 7 }
1918 }, {
1919 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1920 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1921 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1922 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1923 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1924 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1925 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1926 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1927 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1928 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1929 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1930 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1931 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1932 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1933 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1934 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1935 "\xaa\xaa\xaa",
1936 .ksize = 131,
1937 .plaintext = "Test Using Large"
1938 "r Than Block-Siz"
1939 "e Key - Hash Key"
1940 " First",
1941 .psize = 54,
1942 .digest = "\x80\xb2\x42\x63\xc7\xc1\xa3\xeb"
1943 "\xb7\x14\x93\xc1\xdd\x7b\xe8\xb4"
1944 "\x9b\x46\xd1\xf4\x1b\x4a\xee\xc1"
1945 "\x12\x1b\x01\x37\x83\xf8\xf3\x52"
1946 "\x6b\x56\xd0\x37\xe0\x5f\x25\x98"
1947 "\xbd\x0f\xd2\x21\x5d\x6a\x1e\x52"
1948 "\x95\xe6\x4f\x73\xf6\x3f\x0a\xec"
1949 "\x8b\x91\x5a\x98\x5d\x78\x65\x98",
1950 }, {
1951 .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1952 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1953 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1954 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1955 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1956 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1957 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1958 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1959 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1960 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1961 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1962 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1963 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1964 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1965 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1966 "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
1967 "\xaa\xaa\xaa",
1968 .ksize = 131,
1969 .plaintext =
1970 "This is a test u"
1971 "sing a larger th"
1972 "an block-size ke"
1973 "y and a larger t"
1974 "han block-size d"
1975 "ata. The key nee"
1976 "ds to be hashed "
1977 "before being use"
1978 "d by the HMAC al"
1979 "gorithm.",
1980 .psize = 152,
1981 .digest = "\xe3\x7b\x6a\x77\x5d\xc8\x7d\xba"
1982 "\xa4\xdf\xa9\xf9\x6e\x5e\x3f\xfd"
1983 "\xde\xbd\x71\xf8\x86\x72\x89\x86"
1984 "\x5d\xf5\xa3\x2d\x20\xcd\xc9\x44"
1985 "\xb6\x02\x2c\xac\x3c\x49\x82\xb1"
1986 "\x0d\x5e\xeb\x55\xc3\xe4\xde\x15"
1987 "\x13\x46\x76\xfb\x6d\xe0\x44\x60"
1988 "\x65\xc9\x74\x40\xfa\x8c\x6a\x58",
1989 },
1990};
1991
1992
1993
1994
1995#define DES_ENC_TEST_VECTORS 10
1996#define DES_DEC_TEST_VECTORS 4
1997#define DES_CBC_ENC_TEST_VECTORS 5
1998#define DES_CBC_DEC_TEST_VECTORS 4
1999#define DES3_EDE_ENC_TEST_VECTORS 3
2000#define DES3_EDE_DEC_TEST_VECTORS 3
2001#define DES3_EDE_CBC_ENC_TEST_VECTORS 1
2002#define DES3_EDE_CBC_DEC_TEST_VECTORS 1
2003
2004static struct cipher_testvec des_enc_tv_template[] = {
2005 {
2006 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2007 .klen = 8,
2008 .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7",
2009 .ilen = 8,
2010 .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d",
2011 .rlen = 8,
2012 }, {
2013 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2014 .klen = 8,
2015 .input = "\x22\x33\x44\x55\x66\x77\x88\x99",
2016 .ilen = 8,
2017 .result = "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b",
2018 .rlen = 8,
2019 }, {
2020 .key = "\x7c\xa1\x10\x45\x4a\x1a\x6e\x57",
2021 .klen = 8,
2022 .input = "\x01\xa1\xd6\xd0\x39\x77\x67\x42",
2023 .ilen = 8,
2024 .result = "\x69\x0f\x5b\x0d\x9a\x26\x93\x9b",
2025 .rlen = 8,
2026 }, {
2027 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2028 .klen = 8,
2029 .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
2030 "\x22\x33\x44\x55\x66\x77\x88\x99"
2031 "\xca\xfe\xba\xbe\xfe\xed\xbe\xef",
2032 .ilen = 24,
2033 .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
2034 "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b"
2035 "\xb4\x99\x26\xf7\x1f\xe1\xd4\x90",
2036 .rlen = 24,
2037 }, {
2038 .fail = 1,
2039 .wk = 1,
2040 .key = "\x01\x01\x01\x01\x01\x01\x01\x01",
2041 .klen = 8,
2042 .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7",
2043 .ilen = 8,
2044 .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d",
2045 .rlen = 8,
2046 }, {
2047 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2048 .klen = 8,
2049 .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
2050 "\x22\x33\x44\x55\x66\x77\x88\x99",
2051 .ilen = 16,
2052 .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
2053 "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b",
2054 .rlen = 16,
2055 .np = 2,
2056 .tap = { 8, 8 }
2057 }, {
2058 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2059 .klen = 8,
2060 .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
2061 "\x22\x33\x44\x55\x66\x77\x88\x99"
2062 "\xca\xfe\xba\xbe\xfe\xed\xbe\xef"
2063 "\x22\x33\x44\x55\x66\x77\x88\x99",
2064 .ilen = 32,
2065 .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
2066 "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b"
2067 "\xb4\x99\x26\xf7\x1f\xe1\xd4\x90"
2068 "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b",
2069 .rlen = 32,
2070 .np = 3,
2071 .tap = { 14, 10, 8 }
2072 }, {
2073 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2074 .klen = 8,
2075 .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
2076 "\x22\x33\x44\x55\x66\x77\x88\x99"
2077 "\xca\xfe\xba\xbe\xfe\xed\xbe\xef",
2078 .ilen = 24,
2079 .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
2080 "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b"
2081 "\xb4\x99\x26\xf7\x1f\xe1\xd4\x90",
2082 .rlen = 24,
2083 .np = 4,
2084 .tap = { 2, 1, 3, 18 }
2085 }, {
2086 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2087 .klen = 8,
2088 .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
2089 "\x22\x33\x44\x55\x66\x77\x88\x99",
2090 .ilen = 16,
2091 .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
2092 "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b",
2093 .rlen = 16,
2094 .np = 5,
2095 .tap = { 2, 2, 2, 2, 8 }
2096 }, {
2097 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2098 .klen = 8,
2099 .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7",
2100 .ilen = 8,
2101 .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d",
2102 .rlen = 8,
2103 .np = 8,
2104 .tap = { 1, 1, 1, 1, 1, 1, 1, 1 }
2105 },
2106};
2107
2108static struct cipher_testvec des_dec_tv_template[] = {
2109 {
2110 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2111 .klen = 8,
2112 .input = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d",
2113 .ilen = 8,
2114 .result = "\x01\x23\x45\x67\x89\xab\xcd\xe7",
2115 .rlen = 8,
2116 }, {
2117 .key = "\x7c\xa1\x10\x45\x4a\x1a\x6e\x57",
2118 .klen = 8,
2119 .input = "\x69\x0f\x5b\x0d\x9a\x26\x93\x9b",
2120 .ilen = 8,
2121 .result = "\x01\xa1\xd6\xd0\x39\x77\x67\x42",
2122 .rlen = 8,
2123 }, {
2124 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2125 .klen = 8,
2126 .input = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
2127 "\x69\x0f\x5b\x0d\x9a\x26\x93\x9b",
2128 .ilen = 16,
2129 .result = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
2130 "\xa3\x99\x7b\xca\xaf\x69\xa0\xf5",
2131 .rlen = 16,
2132 .np = 2,
2133 .tap = { 8, 8 }
2134 }, {
2135 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2136 .klen = 8,
2137 .input = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
2138 "\x69\x0f\x5b\x0d\x9a\x26\x93\x9b",
2139 .ilen = 16,
2140 .result = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
2141 "\xa3\x99\x7b\xca\xaf\x69\xa0\xf5",
2142 .rlen = 16,
2143 .np = 3,
2144 .tap = { 3, 12, 1 }
2145 },
2146};
2147
2148static struct cipher_testvec des_cbc_enc_tv_template[] = {
2149 {
2150 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2151 .klen = 8,
2152 .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2153 .input = "\x37\x36\x35\x34\x33\x32\x31\x20"
2154 "\x4e\x6f\x77\x20\x69\x73\x20\x74"
2155 "\x68\x65\x20\x74\x69\x6d\x65\x20",
2156 .ilen = 24,
2157 .result = "\xcc\xd1\x73\xff\xab\x20\x39\xf4"
2158 "\xac\xd8\xae\xfd\xdf\xd8\xa1\xeb"
2159 "\x46\x8e\x91\x15\x78\x88\xba\x68",
2160 .rlen = 24,
2161 }, {
2162 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2163 .klen = 8,
2164 .iv = "\x12\x34\x56\x78\x90\xab\xcd\xef",
2165 .input = "\x4e\x6f\x77\x20\x69\x73\x20\x74",
2166 .ilen = 8,
2167 .result = "\xe5\xc7\xcd\xde\x87\x2b\xf2\x7c",
2168 .rlen = 8,
2169 }, {
2170 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2171 .klen = 8,
2172 .iv = "\xe5\xc7\xcd\xde\x87\x2b\xf2\x7c",
2173 .input = "\x68\x65\x20\x74\x69\x6d\x65\x20",
2174 .ilen = 8,
2175 .result = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
2176 .rlen = 8,
2177 }, {
2178 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2179 .klen = 8,
2180 .iv = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
2181 .input = "\x66\x6f\x72\x20\x61\x6c\x6c\x20",
2182 .ilen = 8,
2183 .result = "\x68\x37\x88\x49\x9a\x7c\x05\xf6",
2184 .rlen = 8,
2185 }, {
2186
2187 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2188 .klen = 8,
2189 .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2190 .input = "\x37\x36\x35\x34\x33\x32\x31\x20"
2191 "\x4e\x6f\x77\x20\x69\x73\x20\x74"
2192 "\x68\x65\x20\x74\x69\x6d\x65\x20",
2193 .ilen = 24,
2194 .result = "\xcc\xd1\x73\xff\xab\x20\x39\xf4"
2195 "\xac\xd8\xae\xfd\xdf\xd8\xa1\xeb"
2196 "\x46\x8e\x91\x15\x78\x88\xba\x68",
2197 .rlen = 24,
2198 .np = 2,
2199 .tap = { 13, 11 }
2200 },
2201};
2202
2203static struct cipher_testvec des_cbc_dec_tv_template[] = {
2204 {
2205 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2206 .klen = 8,
2207 .iv = "\x12\x34\x56\x78\x90\xab\xcd\xef",
2208 .input = "\xe5\xc7\xcd\xde\x87\x2b\xf2\x7c",
2209 .ilen = 8,
2210 .result = "\x4e\x6f\x77\x20\x69\x73\x20\x74",
2211 .rlen = 8,
2212 }, {
2213 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2214 .klen = 8,
2215 .iv = "\xe5\xc7\xcd\xde\x87\x2b\xf2\x7c",
2216 .input = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
2217 .ilen = 8,
2218 .result = "\x68\x65\x20\x74\x69\x6d\x65\x20",
2219 .rlen = 8,
2220 }, {
2221 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2222 .klen = 8,
2223 .iv = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
2224 .input = "\x68\x37\x88\x49\x9a\x7c\x05\xf6",
2225 .ilen = 8,
2226 .result = "\x66\x6f\x72\x20\x61\x6c\x6c\x20",
2227 .rlen = 8,
2228 }, {
2229 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2230 .klen = 8,
2231 .iv = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
2232 .input = "\x68\x37\x88\x49\x9a\x7c\x05\xf6",
2233 .ilen = 8,
2234 .result = "\x66\x6f\x72\x20\x61\x6c\x6c\x20",
2235 .rlen = 8,
2236 .np = 2,
2237 .tap = { 4, 4 }
2238 },
2239};
2240
2241static struct cipher_testvec des3_ede_enc_tv_template[] = {
2242 {
2243 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
2244 "\x55\x55\x55\x55\x55\x55\x55\x55"
2245 "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2246 .klen = 24,
2247 .input = "\x73\x6f\x6d\x65\x64\x61\x74\x61",
2248 .ilen = 8,
2249 .result = "\x18\xd7\x48\xe5\x63\x62\x05\x72",
2250 .rlen = 8,
2251 }, {
2252 .key = "\x03\x52\x02\x07\x67\x20\x82\x17"
2253 "\x86\x02\x87\x66\x59\x08\x21\x98"
2254 "\x64\x05\x6a\xbd\xfe\xa9\x34\x57",
2255 .klen = 24,
2256 .input = "\x73\x71\x75\x69\x67\x67\x6c\x65",
2257 .ilen = 8,
2258 .result = "\xc0\x7d\x2a\x0f\xa5\x66\xfa\x30",
2259 .rlen = 8,
2260 }, {
2261 .key = "\x10\x46\x10\x34\x89\x98\x80\x20"
2262 "\x91\x07\xd0\x15\x89\x19\x01\x01"
2263 "\x19\x07\x92\x10\x98\x1a\x01\x01",
2264 .klen = 24,
2265 .input = "\x00\x00\x00\x00\x00\x00\x00\x00",
2266 .ilen = 8,
2267 .result = "\xe1\xef\x62\xc3\x32\xfe\x82\x5b",
2268 .rlen = 8,
2269 },
2270};
2271
2272static struct cipher_testvec des3_ede_dec_tv_template[] = {
2273 {
2274 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
2275 "\x55\x55\x55\x55\x55\x55\x55\x55"
2276 "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2277 .klen = 24,
2278 .input = "\x18\xd7\x48\xe5\x63\x62\x05\x72",
2279 .ilen = 8,
2280 .result = "\x73\x6f\x6d\x65\x64\x61\x74\x61",
2281 .rlen = 8,
2282 }, {
2283 .key = "\x03\x52\x02\x07\x67\x20\x82\x17"
2284 "\x86\x02\x87\x66\x59\x08\x21\x98"
2285 "\x64\x05\x6a\xbd\xfe\xa9\x34\x57",
2286 .klen = 24,
2287 .input = "\xc0\x7d\x2a\x0f\xa5\x66\xfa\x30",
2288 .ilen = 8,
2289 .result = "\x73\x71\x75\x69\x67\x67\x6c\x65",
2290 .rlen = 8,
2291 }, {
2292 .key = "\x10\x46\x10\x34\x89\x98\x80\x20"
2293 "\x91\x07\xd0\x15\x89\x19\x01\x01"
2294 "\x19\x07\x92\x10\x98\x1a\x01\x01",
2295 .klen = 24,
2296 .input = "\xe1\xef\x62\xc3\x32\xfe\x82\x5b",
2297 .ilen = 8,
2298 .result = "\x00\x00\x00\x00\x00\x00\x00\x00",
2299 .rlen = 8,
2300 },
2301};
2302
2303static struct cipher_testvec des3_ede_cbc_enc_tv_template[] = {
2304 {
2305 .key = "\xE9\xC0\xFF\x2E\x76\x0B\x64\x24"
2306 "\x44\x4D\x99\x5A\x12\xD6\x40\xC0"
2307 "\xEA\xC2\x84\xE8\x14\x95\xDB\xE8",
2308 .klen = 24,
2309 .iv = "\x7D\x33\x88\x93\x0F\x93\xB2\x42",
2310 .input = "\x6f\x54\x20\x6f\x61\x4d\x79\x6e"
2311 "\x53\x20\x63\x65\x65\x72\x73\x74"
2312 "\x54\x20\x6f\x6f\x4d\x20\x6e\x61"
2313 "\x20\x79\x65\x53\x72\x63\x74\x65"
2314 "\x20\x73\x6f\x54\x20\x6f\x61\x4d"
2315 "\x79\x6e\x53\x20\x63\x65\x65\x72"
2316 "\x73\x74\x54\x20\x6f\x6f\x4d\x20"
2317 "\x6e\x61\x20\x79\x65\x53\x72\x63"
2318 "\x74\x65\x20\x73\x6f\x54\x20\x6f"
2319 "\x61\x4d\x79\x6e\x53\x20\x63\x65"
2320 "\x65\x72\x73\x74\x54\x20\x6f\x6f"
2321 "\x4d\x20\x6e\x61\x20\x79\x65\x53"
2322 "\x72\x63\x74\x65\x20\x73\x6f\x54"
2323 "\x20\x6f\x61\x4d\x79\x6e\x53\x20"
2324 "\x63\x65\x65\x72\x73\x74\x54\x20"
2325 "\x6f\x6f\x4d\x20\x6e\x61\x0a\x79",
2326 .ilen = 128,
2327 .result = "\x0e\x2d\xb6\x97\x3c\x56\x33\xf4"
2328 "\x67\x17\x21\xc7\x6e\x8a\xd5\x49"
2329 "\x74\xb3\x49\x05\xc5\x1c\xd0\xed"
2330 "\x12\x56\x5c\x53\x96\xb6\x00\x7d"
2331 "\x90\x48\xfc\xf5\x8d\x29\x39\xcc"
2332 "\x8a\xd5\x35\x18\x36\x23\x4e\xd7"
2333 "\x76\xd1\xda\x0c\x94\x67\xbb\x04"
2334 "\x8b\xf2\x03\x6c\xa8\xcf\xb6\xea"
2335 "\x22\x64\x47\xaa\x8f\x75\x13\xbf"
2336 "\x9f\xc2\xc3\xf0\xc9\x56\xc5\x7a"
2337 "\x71\x63\x2e\x89\x7b\x1e\x12\xca"
2338 "\xe2\x5f\xaf\xd8\xa4\xf8\xc9\x7a"
2339 "\xd6\xf9\x21\x31\x62\x44\x45\xa6"
2340 "\xd6\xbc\x5a\xd3\x2d\x54\x43\xcc"
2341 "\x9d\xde\xa5\x70\xe9\x42\x45\x8a"
2342 "\x6b\xfa\xb1\x91\x13\xb0\xd9\x19",
2343 .rlen = 128,
2344 },
2345};
2346
2347static struct cipher_testvec des3_ede_cbc_dec_tv_template[] = {
2348 {
2349 .key = "\xE9\xC0\xFF\x2E\x76\x0B\x64\x24"
2350 "\x44\x4D\x99\x5A\x12\xD6\x40\xC0"
2351 "\xEA\xC2\x84\xE8\x14\x95\xDB\xE8",
2352 .klen = 24,
2353 .iv = "\x7D\x33\x88\x93\x0F\x93\xB2\x42",
2354 .input = "\x0e\x2d\xb6\x97\x3c\x56\x33\xf4"
2355 "\x67\x17\x21\xc7\x6e\x8a\xd5\x49"
2356 "\x74\xb3\x49\x05\xc5\x1c\xd0\xed"
2357 "\x12\x56\x5c\x53\x96\xb6\x00\x7d"
2358 "\x90\x48\xfc\xf5\x8d\x29\x39\xcc"
2359 "\x8a\xd5\x35\x18\x36\x23\x4e\xd7"
2360 "\x76\xd1\xda\x0c\x94\x67\xbb\x04"
2361 "\x8b\xf2\x03\x6c\xa8\xcf\xb6\xea"
2362 "\x22\x64\x47\xaa\x8f\x75\x13\xbf"
2363 "\x9f\xc2\xc3\xf0\xc9\x56\xc5\x7a"
2364 "\x71\x63\x2e\x89\x7b\x1e\x12\xca"
2365 "\xe2\x5f\xaf\xd8\xa4\xf8\xc9\x7a"
2366 "\xd6\xf9\x21\x31\x62\x44\x45\xa6"
2367 "\xd6\xbc\x5a\xd3\x2d\x54\x43\xcc"
2368 "\x9d\xde\xa5\x70\xe9\x42\x45\x8a"
2369 "\x6b\xfa\xb1\x91\x13\xb0\xd9\x19",
2370 .ilen = 128,
2371 .result = "\x6f\x54\x20\x6f\x61\x4d\x79\x6e"
2372 "\x53\x20\x63\x65\x65\x72\x73\x74"
2373 "\x54\x20\x6f\x6f\x4d\x20\x6e\x61"
2374 "\x20\x79\x65\x53\x72\x63\x74\x65"
2375 "\x20\x73\x6f\x54\x20\x6f\x61\x4d"
2376 "\x79\x6e\x53\x20\x63\x65\x65\x72"
2377 "\x73\x74\x54\x20\x6f\x6f\x4d\x20"
2378 "\x6e\x61\x20\x79\x65\x53\x72\x63"
2379 "\x74\x65\x20\x73\x6f\x54\x20\x6f"
2380 "\x61\x4d\x79\x6e\x53\x20\x63\x65"
2381 "\x65\x72\x73\x74\x54\x20\x6f\x6f"
2382 "\x4d\x20\x6e\x61\x20\x79\x65\x53"
2383 "\x72\x63\x74\x65\x20\x73\x6f\x54"
2384 "\x20\x6f\x61\x4d\x79\x6e\x53\x20"
2385 "\x63\x65\x65\x72\x73\x74\x54\x20"
2386 "\x6f\x6f\x4d\x20\x6e\x61\x0a\x79",
2387 .rlen = 128,
2388 },
2389};
2390
2391
2392
2393
2394#define BF_ENC_TEST_VECTORS 7
2395#define BF_DEC_TEST_VECTORS 7
2396#define BF_CBC_ENC_TEST_VECTORS 2
2397#define BF_CBC_DEC_TEST_VECTORS 2
2398#define BF_CTR_ENC_TEST_VECTORS 2
2399#define BF_CTR_DEC_TEST_VECTORS 2
2400
2401static struct cipher_testvec bf_enc_tv_template[] = {
2402 {
2403 .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
2404 .klen = 8,
2405 .input = "\x00\x00\x00\x00\x00\x00\x00\x00",
2406 .ilen = 8,
2407 .result = "\x4e\xf9\x97\x45\x61\x98\xdd\x78",
2408 .rlen = 8,
2409 }, {
2410 .key = "\x1f\x1f\x1f\x1f\x0e\x0e\x0e\x0e",
2411 .klen = 8,
2412 .input = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2413 .ilen = 8,
2414 .result = "\xa7\x90\x79\x51\x08\xea\x3c\xae",
2415 .rlen = 8,
2416 }, {
2417 .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
2418 .klen = 8,
2419 .input = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2420 .ilen = 8,
2421 .result = "\xe8\x7a\x24\x4e\x2c\xc8\x5e\x82",
2422 .rlen = 8,
2423 }, {
2424 .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
2425 "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f",
2426 .klen = 16,
2427 .input = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2428 .ilen = 8,
2429 .result = "\x93\x14\x28\x87\xee\x3b\xe1\x5c",
2430 .rlen = 8,
2431 }, {
2432 .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
2433 "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f"
2434 "\x00\x11\x22\x33\x44",
2435 .klen = 21,
2436 .input = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2437 .ilen = 8,
2438 .result = "\xe6\xf5\x1e\xd7\x9b\x9d\xb2\x1f",
2439 .rlen = 8,
2440 }, {
2441 .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
2442 "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f"
2443 "\x00\x11\x22\x33\x44\x55\x66\x77"
2444 "\x04\x68\x91\x04\xc2\xfd\x3b\x2f"
2445 "\x58\x40\x23\x64\x1a\xba\x61\x76"
2446 "\x1f\x1f\x1f\x1f\x0e\x0e\x0e\x0e"
2447 "\xff\xff\xff\xff\xff\xff\xff\xff",
2448 .klen = 56,
2449 .input = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2450 .ilen = 8,
2451 .result = "\xc0\x45\x04\x01\x2e\x4e\x1f\x53",
2452 .rlen = 8,
2453 }, {
2454 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2455 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2456 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2457 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2458 .klen = 32,
2459 .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2460 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2461 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2462 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2463 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
2464 .ilen = 40,
2465 .result = "\x96\x87\x3D\x0C\x7B\xFB\xBD\x1F"
2466 "\xE3\xC1\x99\x6D\x39\xD4\xC2\x7D"
2467 "\xD7\x87\xA1\xF2\xDF\x51\x71\x26"
2468 "\xC2\xF4\x6D\xFF\xF6\xCD\x6B\x40"
2469 "\xE1\xB3\xBF\xD4\x38\x2B\xC8\x3B",
2470 .rlen = 40,
2471 },
2472};
2473
2474static struct cipher_testvec bf_dec_tv_template[] = {
2475 {
2476 .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
2477 .klen = 8,
2478 .input = "\x4e\xf9\x97\x45\x61\x98\xdd\x78",
2479 .ilen = 8,
2480 .result = "\x00\x00\x00\x00\x00\x00\x00\x00",
2481 .rlen = 8,
2482 }, {
2483 .key = "\x1f\x1f\x1f\x1f\x0e\x0e\x0e\x0e",
2484 .klen = 8,
2485 .input = "\xa7\x90\x79\x51\x08\xea\x3c\xae",
2486 .ilen = 8,
2487 .result = "\x01\x23\x45\x67\x89\xab\xcd\xef",
2488 .rlen = 8,
2489 }, {
2490 .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
2491 .klen = 8,
2492 .input = "\xe8\x7a\x24\x4e\x2c\xc8\x5e\x82",
2493 .ilen = 8,
2494 .result = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2495 .rlen = 8,
2496 }, {
2497 .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
2498 "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f",
2499 .klen = 16,
2500 .input = "\x93\x14\x28\x87\xee\x3b\xe1\x5c",
2501 .ilen = 8,
2502 .result = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2503 .rlen = 8,
2504 }, {
2505 .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
2506 "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f"
2507 "\x00\x11\x22\x33\x44",
2508 .klen = 21,
2509 .input = "\xe6\xf5\x1e\xd7\x9b\x9d\xb2\x1f",
2510 .ilen = 8,
2511 .result = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2512 .rlen = 8,
2513 }, {
2514 .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
2515 "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f"
2516 "\x00\x11\x22\x33\x44\x55\x66\x77"
2517 "\x04\x68\x91\x04\xc2\xfd\x3b\x2f"
2518 "\x58\x40\x23\x64\x1a\xba\x61\x76"
2519 "\x1f\x1f\x1f\x1f\x0e\x0e\x0e\x0e"
2520 "\xff\xff\xff\xff\xff\xff\xff\xff",
2521 .klen = 56,
2522 .input = "\xc0\x45\x04\x01\x2e\x4e\x1f\x53",
2523 .ilen = 8,
2524 .result = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2525 .rlen = 8,
2526 }, {
2527 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2528 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2529 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2530 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2531 .klen = 32,
2532 .input = "\x96\x87\x3D\x0C\x7B\xFB\xBD\x1F"
2533 "\xE3\xC1\x99\x6D\x39\xD4\xC2\x7D"
2534 "\xD7\x87\xA1\xF2\xDF\x51\x71\x26"
2535 "\xC2\xF4\x6D\xFF\xF6\xCD\x6B\x40"
2536 "\xE1\xB3\xBF\xD4\x38\x2B\xC8\x3B",
2537 .ilen = 40,
2538 .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2539 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2540 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2541 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2542 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
2543 .rlen = 40,
2544 },
2545};
2546
2547static struct cipher_testvec bf_cbc_enc_tv_template[] = {
2548 {
2549 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
2550 "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
2551 .klen = 16,
2552 .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2553 .input = "\x37\x36\x35\x34\x33\x32\x31\x20"
2554 "\x4e\x6f\x77\x20\x69\x73\x20\x74"
2555 "\x68\x65\x20\x74\x69\x6d\x65\x20"
2556 "\x66\x6f\x72\x20\x00\x00\x00\x00",
2557 .ilen = 32,
2558 .result = "\x6b\x77\xb4\xd6\x30\x06\xde\xe6"
2559 "\x05\xb1\x56\xe2\x74\x03\x97\x93"
2560 "\x58\xde\xb9\xe7\x15\x46\x16\xd9"
2561 "\x59\xf1\x65\x2b\xd5\xff\x92\xcc",
2562 .rlen = 32,
2563 }, {
2564 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2565 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2566 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2567 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2568 .klen = 32,
2569 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
2570 .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2571 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2572 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2573 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2574 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
2575 .ilen = 40,
2576 .result = "\xB4\xFE\xA5\xBB\x3D\x2C\x27\x06"
2577 "\x06\x2B\x3A\x92\xB2\xF5\x5E\x62"
2578 "\x84\xCD\xF7\x66\x7E\x41\x6C\x8E"
2579 "\x1B\xD9\x02\xB6\x48\xB0\x87\x25"
2580 "\x01\x9C\x93\x63\x51\x60\x82\xD2",
2581 .rlen = 40,
2582 },
2583};
2584
2585static struct cipher_testvec bf_cbc_dec_tv_template[] = {
2586 {
2587 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
2588 "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
2589 .klen = 16,
2590 .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
2591 .input = "\x6b\x77\xb4\xd6\x30\x06\xde\xe6"
2592 "\x05\xb1\x56\xe2\x74\x03\x97\x93"
2593 "\x58\xde\xb9\xe7\x15\x46\x16\xd9"
2594 "\x59\xf1\x65\x2b\xd5\xff\x92\xcc",
2595 .ilen = 32,
2596 .result = "\x37\x36\x35\x34\x33\x32\x31\x20"
2597 "\x4e\x6f\x77\x20\x69\x73\x20\x74"
2598 "\x68\x65\x20\x74\x69\x6d\x65\x20"
2599 "\x66\x6f\x72\x20\x00\x00\x00\x00",
2600 .rlen = 32,
2601 }, {
2602 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2603 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2604 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2605 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2606 .klen = 32,
2607 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
2608 .input = "\xB4\xFE\xA5\xBB\x3D\x2C\x27\x06"
2609 "\x06\x2B\x3A\x92\xB2\xF5\x5E\x62"
2610 "\x84\xCD\xF7\x66\x7E\x41\x6C\x8E"
2611 "\x1B\xD9\x02\xB6\x48\xB0\x87\x25"
2612 "\x01\x9C\x93\x63\x51\x60\x82\xD2",
2613 .ilen = 40,
2614 .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2615 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2616 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2617 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2618 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
2619 .rlen = 40,
2620 },
2621};
2622
2623static struct cipher_testvec bf_ctr_enc_tv_template[] = {
2624 {
2625 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2626 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2627 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2628 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2629 .klen = 32,
2630 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
2631 .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2632 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2633 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2634 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2635 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
2636 .ilen = 40,
2637 .result = "\xC7\xA3\xDF\xB9\x05\xF4\x9E\x8D"
2638 "\x9E\xDF\x38\x18\x83\x07\xEF\xC1"
2639 "\x93\x3C\xAA\xAA\xFE\x06\x42\xCC"
2640 "\x0D\x70\x86\x5A\x44\xAD\x85\x17"
2641 "\xE4\x1F\x5E\xA5\x89\xAC\x32\xBC",
2642 .rlen = 40,
2643 }, {
2644 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2645 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2646 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2647 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2648 .klen = 32,
2649 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
2650 .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2651 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2652 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2653 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2654 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
2655 "\x6D\x04\x9B",
2656 .ilen = 43,
2657 .result = "\xC7\xA3\xDF\xB9\x05\xF4\x9E\x8D"
2658 "\x9E\xDF\x38\x18\x83\x07\xEF\xC1"
2659 "\x93\x3C\xAA\xAA\xFE\x06\x42\xCC"
2660 "\x0D\x70\x86\x5A\x44\xAD\x85\x17"
2661 "\xE4\x1F\x5E\xA5\x89\xAC\x32\xBC"
2662 "\x3D\xA7\xE9",
2663 .rlen = 43,
2664 },
2665};
2666
2667static struct cipher_testvec bf_ctr_dec_tv_template[] = {
2668 {
2669 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2670 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2671 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2672 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2673 .klen = 32,
2674 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
2675 .input = "\xC7\xA3\xDF\xB9\x05\xF4\x9E\x8D"
2676 "\x9E\xDF\x38\x18\x83\x07\xEF\xC1"
2677 "\x93\x3C\xAA\xAA\xFE\x06\x42\xCC"
2678 "\x0D\x70\x86\x5A\x44\xAD\x85\x17"
2679 "\xE4\x1F\x5E\xA5\x89\xAC\x32\xBC",
2680 .ilen = 40,
2681 .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2682 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2683 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2684 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2685 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
2686 .rlen = 40,
2687 }, {
2688 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2689 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2690 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2691 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2692 .klen = 32,
2693 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
2694 .input = "\xC7\xA3\xDF\xB9\x05\xF4\x9E\x8D"
2695 "\x9E\xDF\x38\x18\x83\x07\xEF\xC1"
2696 "\x93\x3C\xAA\xAA\xFE\x06\x42\xCC"
2697 "\x0D\x70\x86\x5A\x44\xAD\x85\x17"
2698 "\xE4\x1F\x5E\xA5\x89\xAC\x32\xBC"
2699 "\x3D\xA7\xE9",
2700 .ilen = 43,
2701 .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2702 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2703 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2704 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2705 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
2706 "\x6D\x04\x9B",
2707 .rlen = 43,
2708 },
2709};
2710
2711
2712
2713
2714#define TF_ENC_TEST_VECTORS 4
2715#define TF_DEC_TEST_VECTORS 4
2716#define TF_CBC_ENC_TEST_VECTORS 5
2717#define TF_CBC_DEC_TEST_VECTORS 5
2718#define TF_CTR_ENC_TEST_VECTORS 2
2719#define TF_CTR_DEC_TEST_VECTORS 2
2720
2721static struct cipher_testvec tf_enc_tv_template[] = {
2722 {
2723 .key = zeroed_string,
2724 .klen = 16,
2725 .input = zeroed_string,
2726 .ilen = 16,
2727 .result = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
2728 "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
2729 .rlen = 16,
2730 }, {
2731 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
2732 "\xfe\xdc\xba\x98\x76\x54\x32\x10"
2733 "\x00\x11\x22\x33\x44\x55\x66\x77",
2734 .klen = 24,
2735 .input = zeroed_string,
2736 .ilen = 16,
2737 .result = "\xcf\xd1\xd2\xe5\xa9\xbe\x9c\xdf"
2738 "\x50\x1f\x13\xb8\x92\xbd\x22\x48",
2739 .rlen = 16,
2740 }, {
2741 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
2742 "\xfe\xdc\xba\x98\x76\x54\x32\x10"
2743 "\x00\x11\x22\x33\x44\x55\x66\x77"
2744 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
2745 .klen = 32,
2746 .input = zeroed_string,
2747 .ilen = 16,
2748 .result = "\x37\x52\x7b\xe0\x05\x23\x34\xb8"
2749 "\x9f\x0c\xfc\xca\xe8\x7c\xfa\x20",
2750 .rlen = 16,
2751 }, {
2752 .key = "\x3F\x85\x62\x3F\x1C\xF9\xD6\x1C"
2753 "\xF9\xD6\xB3\x90\x6D\x4A\x90\x6D"
2754 "\x4A\x27\x04\xE1\x27\x04\xE1\xBE"
2755 "\x9B\x78\xBE\x9B\x78\x55\x32\x0F",
2756 .klen = 32,
2757 .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2758 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2759 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2760 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2761 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
2762 "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
2763 "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
2764 "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
2765 .ilen = 64,
2766 .result = "\x88\xCB\x1E\xC2\xAF\x8A\x97\xFF"
2767 "\xF6\x90\x46\x9C\x4A\x0F\x08\xDC"
2768 "\xDE\xAB\xAD\xFA\xFC\xA8\xC2\x3D"
2769 "\xE0\xE4\x8B\x3F\xD5\xA3\xF7\x14"
2770 "\x34\x9E\xB6\x08\xB2\xDD\xA8\xF5"
2771 "\xDF\xFA\xC7\xE8\x09\x50\x76\x08"
2772 "\xA2\xB6\x6A\x59\xC0\x2B\x6D\x05"
2773 "\x89\xF6\x82\xF0\xD3\xDB\x06\x02",
2774 .rlen = 64,
2775 },
2776};
2777
2778static struct cipher_testvec tf_dec_tv_template[] = {
2779 {
2780 .key = zeroed_string,
2781 .klen = 16,
2782 .input = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
2783 "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
2784 .ilen = 16,
2785 .result = zeroed_string,
2786 .rlen = 16,
2787 }, {
2788 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
2789 "\xfe\xdc\xba\x98\x76\x54\x32\x10"
2790 "\x00\x11\x22\x33\x44\x55\x66\x77",
2791 .klen = 24,
2792 .input = "\xcf\xd1\xd2\xe5\xa9\xbe\x9c\xdf"
2793 "\x50\x1f\x13\xb8\x92\xbd\x22\x48",
2794 .ilen = 16,
2795 .result = zeroed_string,
2796 .rlen = 16,
2797 }, {
2798 .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
2799 "\xfe\xdc\xba\x98\x76\x54\x32\x10"
2800 "\x00\x11\x22\x33\x44\x55\x66\x77"
2801 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
2802 .klen = 32,
2803 .input = "\x37\x52\x7b\xe0\x05\x23\x34\xb8"
2804 "\x9f\x0c\xfc\xca\xe8\x7c\xfa\x20",
2805 .ilen = 16,
2806 .result = zeroed_string,
2807 .rlen = 16,
2808 }, {
2809 .key = "\x3F\x85\x62\x3F\x1C\xF9\xD6\x1C"
2810 "\xF9\xD6\xB3\x90\x6D\x4A\x90\x6D"
2811 "\x4A\x27\x04\xE1\x27\x04\xE1\xBE"
2812 "\x9B\x78\xBE\x9B\x78\x55\x32\x0F",
2813 .klen = 32,
2814 .input = "\x88\xCB\x1E\xC2\xAF\x8A\x97\xFF"
2815 "\xF6\x90\x46\x9C\x4A\x0F\x08\xDC"
2816 "\xDE\xAB\xAD\xFA\xFC\xA8\xC2\x3D"
2817 "\xE0\xE4\x8B\x3F\xD5\xA3\xF7\x14"
2818 "\x34\x9E\xB6\x08\xB2\xDD\xA8\xF5"
2819 "\xDF\xFA\xC7\xE8\x09\x50\x76\x08"
2820 "\xA2\xB6\x6A\x59\xC0\x2B\x6D\x05"
2821 "\x89\xF6\x82\xF0\xD3\xDB\x06\x02",
2822 .ilen = 64,
2823 .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2824 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2825 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2826 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2827 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
2828 "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
2829 "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
2830 "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
2831 .rlen = 64,
2832 },
2833};
2834
2835static struct cipher_testvec tf_cbc_enc_tv_template[] = {
2836 {
2837 .key = zeroed_string,
2838 .klen = 16,
2839 .iv = zeroed_string,
2840 .input = zeroed_string,
2841 .ilen = 16,
2842 .result = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
2843 "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
2844 .rlen = 16,
2845 }, {
2846 .key = zeroed_string,
2847 .klen = 16,
2848 .iv = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
2849 "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
2850 .input = zeroed_string,
2851 .ilen = 16,
2852 .result = "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
2853 "\x86\xcb\x08\x6b\x78\x9f\x54\x19",
2854 .rlen = 16,
2855 }, {
2856 .key = zeroed_string,
2857 .klen = 16,
2858 .iv = "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
2859 "\x86\xcb\x08\x6b\x78\x9f\x54\x19",
2860 .input = zeroed_string,
2861 .ilen = 16,
2862 .result = "\x05\xef\x8c\x61\xa8\x11\x58\x26"
2863 "\x34\xba\x5c\xb7\x10\x6a\xa6\x41",
2864 .rlen = 16,
2865 }, {
2866 .key = zeroed_string,
2867 .klen = 16,
2868 .iv = zeroed_string,
2869 .input = zeroed_string,
2870 .ilen = 48,
2871 .result = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
2872 "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a"
2873 "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
2874 "\x86\xcb\x08\x6b\x78\x9f\x54\x19"
2875 "\x05\xef\x8c\x61\xa8\x11\x58\x26"
2876 "\x34\xba\x5c\xb7\x10\x6a\xa6\x41",
2877 .rlen = 48,
2878 }, {
2879 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2880 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2881 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2882 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2883 .klen = 32,
2884 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
2885 "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
2886 .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2887 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2888 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2889 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2890 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
2891 "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
2892 "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
2893 "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
2894 .ilen = 64,
2895 .result = "\xC8\xFF\xF2\x53\xA6\x27\x09\xD1"
2896 "\x33\x38\xC2\xC0\x0C\x14\x7E\xB5"
2897 "\x26\x1B\x05\x0C\x05\x12\x3F\xC0"
2898 "\xF9\x1C\x02\x28\x40\x96\x6F\xD0"
2899 "\x3D\x32\xDF\xDA\x56\x00\x6E\xEE"
2900 "\x5B\x2A\x72\x9D\xC2\x4D\x19\xBC"
2901 "\x8C\x53\xFA\x87\x6F\xDD\x81\xA3"
2902 "\xB1\xD3\x44\x65\xDF\xE7\x63\x38",
2903 .rlen = 64,
2904 },
2905};
2906
2907static struct cipher_testvec tf_cbc_dec_tv_template[] = {
2908 {
2909 .key = zeroed_string,
2910 .klen = 16,
2911 .iv = zeroed_string,
2912 .input = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
2913 "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
2914 .ilen = 16,
2915 .result = zeroed_string,
2916 .rlen = 16,
2917 }, {
2918 .key = zeroed_string,
2919 .klen = 16,
2920 .iv = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
2921 "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
2922 .input = "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
2923 "\x86\xcb\x08\x6b\x78\x9f\x54\x19",
2924 .ilen = 16,
2925 .result = zeroed_string,
2926 .rlen = 16,
2927 }, {
2928 .key = zeroed_string,
2929 .klen = 16,
2930 .iv = "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
2931 "\x86\xcb\x08\x6b\x78\x9f\x54\x19",
2932 .input = "\x05\xef\x8c\x61\xa8\x11\x58\x26"
2933 "\x34\xba\x5c\xb7\x10\x6a\xa6\x41",
2934 .ilen = 16,
2935 .result = zeroed_string,
2936 .rlen = 16,
2937 }, {
2938 .key = zeroed_string,
2939 .klen = 16,
2940 .iv = zeroed_string,
2941 .input = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
2942 "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a"
2943 "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
2944 "\x86\xcb\x08\x6b\x78\x9f\x54\x19"
2945 "\x05\xef\x8c\x61\xa8\x11\x58\x26"
2946 "\x34\xba\x5c\xb7\x10\x6a\xa6\x41",
2947 .ilen = 48,
2948 .result = zeroed_string,
2949 .rlen = 48,
2950 }, {
2951 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2952 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2953 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2954 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2955 .klen = 32,
2956 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
2957 "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
2958 .input = "\xC8\xFF\xF2\x53\xA6\x27\x09\xD1"
2959 "\x33\x38\xC2\xC0\x0C\x14\x7E\xB5"
2960 "\x26\x1B\x05\x0C\x05\x12\x3F\xC0"
2961 "\xF9\x1C\x02\x28\x40\x96\x6F\xD0"
2962 "\x3D\x32\xDF\xDA\x56\x00\x6E\xEE"
2963 "\x5B\x2A\x72\x9D\xC2\x4D\x19\xBC"
2964 "\x8C\x53\xFA\x87\x6F\xDD\x81\xA3"
2965 "\xB1\xD3\x44\x65\xDF\xE7\x63\x38",
2966 .ilen = 64,
2967 .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2968 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2969 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2970 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2971 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
2972 "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
2973 "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
2974 "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
2975 .rlen = 64,
2976 },
2977};
2978
2979static struct cipher_testvec tf_ctr_enc_tv_template[] = {
2980 {
2981 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
2982 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
2983 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
2984 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
2985 .klen = 32,
2986 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
2987 "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
2988 .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
2989 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
2990 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
2991 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
2992 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
2993 "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
2994 "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
2995 "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
2996 .ilen = 64,
2997 .result = "\xDF\xDD\x69\xFA\xB0\x2E\xFD\xFE"
2998 "\x70\x9E\xC5\x4B\xC9\xD4\xA1\x30"
2999 "\x26\x9B\x89\xA1\xEE\x43\xE0\x52"
3000 "\x55\x17\x4E\xC7\x0E\x33\x1F\xF1"
3001 "\x9F\x8D\x40\x9F\x24\xFD\x92\xA0"
3002 "\xBC\x8F\x35\xDD\x67\x38\xD8\xAA"
3003 "\xCF\xF8\x48\xCA\xFB\xE4\x5C\x60"
3004 "\x01\x41\x21\x12\x38\xAB\x52\x4F",
3005 .rlen = 64,
3006 }, {
3007 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
3008 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
3009 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
3010 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
3011 .klen = 32,
3012 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
3013 "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
3014 .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
3015 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
3016 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
3017 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
3018 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
3019 "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
3020 "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
3021 "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
3022 "\xC3\x37\xCE",
3023 .ilen = 67,
3024 .result = "\xDF\xDD\x69\xFA\xB0\x2E\xFD\xFE"
3025 "\x70\x9E\xC5\x4B\xC9\xD4\xA1\x30"
3026 "\x26\x9B\x89\xA1\xEE\x43\xE0\x52"
3027 "\x55\x17\x4E\xC7\x0E\x33\x1F\xF1"
3028 "\x9F\x8D\x40\x9F\x24\xFD\x92\xA0"
3029 "\xBC\x8F\x35\xDD\x67\x38\xD8\xAA"
3030 "\xCF\xF8\x48\xCA\xFB\xE4\x5C\x60"
3031 "\x01\x41\x21\x12\x38\xAB\x52\x4F"
3032 "\xA8\x57\x20",
3033 .rlen = 67,
3034 },
3035};
3036
3037static struct cipher_testvec tf_ctr_dec_tv_template[] = {
3038 {
3039 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
3040 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
3041 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
3042 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
3043 .klen = 32,
3044 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
3045 "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
3046 .input = "\xDF\xDD\x69\xFA\xB0\x2E\xFD\xFE"
3047 "\x70\x9E\xC5\x4B\xC9\xD4\xA1\x30"
3048 "\x26\x9B\x89\xA1\xEE\x43\xE0\x52"
3049 "\x55\x17\x4E\xC7\x0E\x33\x1F\xF1"
3050 "\x9F\x8D\x40\x9F\x24\xFD\x92\xA0"
3051 "\xBC\x8F\x35\xDD\x67\x38\xD8\xAA"
3052 "\xCF\xF8\x48\xCA\xFB\xE4\x5C\x60"
3053 "\x01\x41\x21\x12\x38\xAB\x52\x4F",
3054 .ilen = 64,
3055 .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
3056 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
3057 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
3058 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
3059 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
3060 "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
3061 "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
3062 "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
3063 .rlen = 64,
3064 }, {
3065 .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
3066 "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
3067 "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
3068 "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
3069 .klen = 32,
3070 .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
3071 "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
3072 .input = "\xDF\xDD\x69\xFA\xB0\x2E\xFD\xFE"
3073 "\x70\x9E\xC5\x4B\xC9\xD4\xA1\x30"
3074 "\x26\x9B\x89\xA1\xEE\x43\xE0\x52"
3075 "\x55\x17\x4E\xC7\x0E\x33\x1F\xF1"
3076 "\x9F\x8D\x40\x9F\x24\xFD\x92\xA0"
3077 "\xBC\x8F\x35\xDD\x67\x38\xD8\xAA"
3078 "\xCF\xF8\x48\xCA\xFB\xE4\x5C\x60"
3079 "\x01\x41\x21\x12\x38\xAB\x52\x4F"
3080 "\xA8\x57\x20",
3081 .ilen = 67,
3082 .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
3083 "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
3084 "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
3085 "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
3086 "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
3087 "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
3088 "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
3089 "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
3090 "\xC3\x37\xCE",
3091 .rlen = 67,
3092 },
3093};
3094
3095
3096
3097
3098
3099#define SERPENT_ENC_TEST_VECTORS 4
3100#define SERPENT_DEC_TEST_VECTORS 4
3101
3102#define TNEPRES_ENC_TEST_VECTORS 4
3103#define TNEPRES_DEC_TEST_VECTORS 4
3104
3105static struct cipher_testvec serpent_enc_tv_template[] = {
3106 {
3107 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
3108 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3109 .ilen = 16,
3110 .result = "\x12\x07\xfc\xce\x9b\xd0\xd6\x47"
3111 "\x6a\xe9\x8f\xbe\xd1\x43\xa0\xe2",
3112 .rlen = 16,
3113 }, {
3114 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3115 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3116 .klen = 16,
3117 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
3118 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3119 .ilen = 16,
3120 .result = "\x4c\x7d\x8a\x32\x80\x72\xa2\x2c"
3121 "\x82\x3e\x4a\x1f\x3a\xcd\xa1\x6d",
3122 .rlen = 16,
3123 }, {
3124 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3125 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3126 "\x10\x11\x12\x13\x14\x15\x16\x17"
3127 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
3128 .klen = 32,
3129 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
3130 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3131 .ilen = 16,
3132 .result = "\xde\x26\x9f\xf8\x33\xe4\x32\xb8"
3133 "\x5b\x2e\x88\xd2\x70\x1c\xe7\x5c",
3134 .rlen = 16,
3135 }, {
3136 .key = "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x80",
3137 .klen = 16,
3138 .input = zeroed_string,
3139 .ilen = 16,
3140 .result = "\xdd\xd2\x6b\x98\xa5\xff\xd8\x2c"
3141 "\x05\x34\x5a\x9d\xad\xbf\xaf\x49",
3142 .rlen = 16,
3143 },
3144};
3145
3146static struct cipher_testvec tnepres_enc_tv_template[] = {
3147 {
3148 .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
3149 "\x00\x00\x00\x00\x00\x00\x00\x00",
3150 .key = "\x80\x00\x00\x00\x00\x00\x00\x00"
3151 "\x00\x00\x00\x00\x00\x00\x00\x00",
3152 .klen = 16,
3153 .ilen = 16,
3154 .result = "\x49\xaf\xbf\xad\x9d\x5a\x34\x05"
3155 "\x2c\xd8\xff\xa5\x98\x6b\xd2\xdd",
3156 .rlen = 16,
3157 }, {
3158 .key = "\x80\x00\x00\x00\x00\x00\x00\x00"
3159 "\x00\x00\x00\x00\x00\x00\x00\x00"
3160 "\x00\x00\x00\x00\x00\x00\x00\x00",
3161 .klen = 24,
3162 .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
3163 "\x00\x00\x00\x00\x00\x00\x00\x00",
3164 .ilen = 16,
3165 .result = "\xe7\x8e\x54\x02\xc7\x19\x55\x68"
3166 "\xac\x36\x78\xf7\xa3\xf6\x0c\x66",
3167 .rlen = 16,
3168 }, {
3169 .key = "\x80\x00\x00\x00\x00\x00\x00\x00"
3170 "\x00\x00\x00\x00\x00\x00\x00\x00"
3171 "\x00\x00\x00\x00\x00\x00\x00\x00"
3172 "\x00\x00\x00\x00\x00\x00\x00\x00",
3173 .klen = 32,
3174 .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
3175 "\x00\x00\x00\x00\x00\x00\x00\x00",
3176 .ilen = 16,
3177 .result = "\xab\xed\x96\xe7\x66\xbf\x28\xcb"
3178 "\xc0\xeb\xd2\x1a\x82\xef\x08\x19",
3179 .rlen = 16,
3180 }, {
3181 .key = "\x1f\x1e\x1d\x1c\x1b\x1a\x19\x18"
3182 "\x17\x16\x15\x14\x13\x12\x11\x10"
3183 "\x0f\x0e\x0d\x0c\x0b\x0a\x09\x08"
3184 "\x07\x06\x05\x04\x03\x02\x01\x00",
3185 .klen = 32,
3186 .input = "\x0f\x0e\x0d\x0c\x0b\x0a\x09\x08"
3187 "\x07\x06\x05\x04\x03\x02\x01\x00",
3188 .ilen = 16,
3189 .result = "\x5c\xe7\x1c\x70\xd2\x88\x2e\x5b"
3190 "\xb8\x32\xe4\x33\xf8\x9f\x26\xde",
3191 .rlen = 16,
3192 },
3193};
3194
3195
3196static struct cipher_testvec serpent_dec_tv_template[] = {
3197 {
3198 .input = "\x12\x07\xfc\xce\x9b\xd0\xd6\x47"
3199 "\x6a\xe9\x8f\xbe\xd1\x43\xa0\xe2",
3200 .ilen = 16,
3201 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
3202 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3203 .rlen = 16,
3204 }, {
3205 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3206 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3207 .klen = 16,
3208 .input = "\x4c\x7d\x8a\x32\x80\x72\xa2\x2c"
3209 "\x82\x3e\x4a\x1f\x3a\xcd\xa1\x6d",
3210 .ilen = 16,
3211 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
3212 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3213 .rlen = 16,
3214 }, {
3215 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3216 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3217 "\x10\x11\x12\x13\x14\x15\x16\x17"
3218 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
3219 .klen = 32,
3220 .input = "\xde\x26\x9f\xf8\x33\xe4\x32\xb8"
3221 "\x5b\x2e\x88\xd2\x70\x1c\xe7\x5c",
3222 .ilen = 16,
3223 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
3224 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3225 .rlen = 16,
3226 }, {
3227 .key = "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x80",
3228 .klen = 16,
3229 .input = "\xdd\xd2\x6b\x98\xa5\xff\xd8\x2c"
3230 "\x05\x34\x5a\x9d\xad\xbf\xaf\x49",
3231 .ilen = 16,
3232 .result = zeroed_string,
3233 .rlen = 16,
3234 },
3235};
3236
3237static struct cipher_testvec tnepres_dec_tv_template[] = {
3238 {
3239 .input = "\x41\xcc\x6b\x31\x59\x31\x45\x97"
3240 "\x6d\x6f\xbb\x38\x4b\x37\x21\x28",
3241 .ilen = 16,
3242 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
3243 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3244 .rlen = 16,
3245 }, {
3246 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3247 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3248 .klen = 16,
3249 .input = "\xea\xf4\xd7\xfc\xd8\x01\x34\x47"
3250 "\x81\x45\x0b\xfa\x0c\xd6\xad\x6e",
3251 .ilen = 16,
3252 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
3253 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3254 .rlen = 16,
3255 }, {
3256 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3257 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3258 "\x10\x11\x12\x13\x14\x15\x16\x17"
3259 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
3260 .klen = 32,
3261 .input = "\x64\xa9\x1a\x37\xed\x9f\xe7\x49"
3262 "\xa8\x4e\x76\xd6\xf5\x0d\x78\xee",
3263 .ilen = 16,
3264 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
3265 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3266 .rlen = 16,
3267 }, {
3268 .key = "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x80",
3269 .klen = 16,
3270 .input = "\x3d\xda\xbf\xc0\x06\xda\xab\x06"
3271 "\x46\x2a\xf4\xef\x81\x54\x4e\x26",
3272 .ilen = 16,
3273 .result = zeroed_string,
3274 .rlen = 16,
3275 },
3276};
3277
3278
3279
3280#define CAST6_ENC_TEST_VECTORS 3
3281#define CAST6_DEC_TEST_VECTORS 3
3282
3283static struct cipher_testvec cast6_enc_tv_template[] = {
3284 {
3285 .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
3286 "\x0a\xf7\x56\x47\xf2\x9f\x61\x5d",
3287 .klen = 16,
3288 .input = zeroed_string,
3289 .ilen = 16,
3290 .result = "\xc8\x42\xa0\x89\x72\xb4\x3d\x20"
3291 "\x83\x6c\x91\xd1\xb7\x53\x0f\x6b",
3292 .rlen = 16,
3293 }, {
3294 .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
3295 "\xbe\xd0\xac\x83\x94\x0a\xc2\x98"
3296 "\xba\xc7\x7a\x77\x17\x94\x28\x63",
3297 .klen = 24,
3298 .input = zeroed_string,
3299 .ilen = 16,
3300 .result = "\x1b\x38\x6c\x02\x10\xdc\xad\xcb"
3301 "\xdd\x0e\x41\xaa\x08\xa7\xa7\xe8",
3302 .rlen = 16,
3303 }, {
3304 .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
3305 "\xbe\xd0\xac\x83\x94\x0a\xc2\x98"
3306 "\x8d\x7c\x47\xce\x26\x49\x08\x46"
3307 "\x1c\xc1\xb5\x13\x7a\xe6\xb6\x04",
3308 .klen = 32,
3309 .input = zeroed_string,
3310 .ilen = 16,
3311 .result = "\x4f\x6a\x20\x38\x28\x68\x97\xb9"
3312 "\xc9\x87\x01\x36\x55\x33\x17\xfa",
3313 .rlen = 16,
3314 },
3315};
3316
3317static struct cipher_testvec cast6_dec_tv_template[] = {
3318 {
3319 .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
3320 "\x0a\xf7\x56\x47\xf2\x9f\x61\x5d",
3321 .klen = 16,
3322 .input = "\xc8\x42\xa0\x89\x72\xb4\x3d\x20"
3323 "\x83\x6c\x91\xd1\xb7\x53\x0f\x6b",
3324 .ilen = 16,
3325 .result = zeroed_string,
3326 .rlen = 16,
3327 }, {
3328 .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
3329 "\xbe\xd0\xac\x83\x94\x0a\xc2\x98"
3330 "\xba\xc7\x7a\x77\x17\x94\x28\x63",
3331 .klen = 24,
3332 .input = "\x1b\x38\x6c\x02\x10\xdc\xad\xcb"
3333 "\xdd\x0e\x41\xaa\x08\xa7\xa7\xe8",
3334 .ilen = 16,
3335 .result = zeroed_string,
3336 .rlen = 16,
3337 }, {
3338 .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
3339 "\xbe\xd0\xac\x83\x94\x0a\xc2\x98"
3340 "\x8d\x7c\x47\xce\x26\x49\x08\x46"
3341 "\x1c\xc1\xb5\x13\x7a\xe6\xb6\x04",
3342 .klen = 32,
3343 .input = "\x4f\x6a\x20\x38\x28\x68\x97\xb9"
3344 "\xc9\x87\x01\x36\x55\x33\x17\xfa",
3345 .ilen = 16,
3346 .result = zeroed_string,
3347 .rlen = 16,
3348 },
3349};
3350
3351
3352
3353
3354
3355#define AES_ENC_TEST_VECTORS 3
3356#define AES_DEC_TEST_VECTORS 3
3357#define AES_CBC_ENC_TEST_VECTORS 4
3358#define AES_CBC_DEC_TEST_VECTORS 4
3359#define AES_LRW_ENC_TEST_VECTORS 8
3360#define AES_LRW_DEC_TEST_VECTORS 8
3361#define AES_XTS_ENC_TEST_VECTORS 5
3362#define AES_XTS_DEC_TEST_VECTORS 5
3363#define AES_CTR_ENC_TEST_VECTORS 3
3364#define AES_CTR_DEC_TEST_VECTORS 3
3365#define AES_OFB_ENC_TEST_VECTORS 1
3366#define AES_OFB_DEC_TEST_VECTORS 1
3367#define AES_CTR_3686_ENC_TEST_VECTORS 7
3368#define AES_CTR_3686_DEC_TEST_VECTORS 6
3369#define AES_GCM_ENC_TEST_VECTORS 9
3370#define AES_GCM_DEC_TEST_VECTORS 8
3371#define AES_GCM_4106_ENC_TEST_VECTORS 7
3372#define AES_GCM_4106_DEC_TEST_VECTORS 7
3373#define AES_CCM_ENC_TEST_VECTORS 7
3374#define AES_CCM_DEC_TEST_VECTORS 7
3375#define AES_CCM_4309_ENC_TEST_VECTORS 7
3376#define AES_CCM_4309_DEC_TEST_VECTORS 10
3377
3378static struct cipher_testvec aes_enc_tv_template[] = {
3379 {
3380 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3381 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3382 .klen = 16,
3383 .input = "\x00\x11\x22\x33\x44\x55\x66\x77"
3384 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
3385 .ilen = 16,
3386 .result = "\x69\xc4\xe0\xd8\x6a\x7b\x04\x30"
3387 "\xd8\xcd\xb7\x80\x70\xb4\xc5\x5a",
3388 .rlen = 16,
3389 }, {
3390 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3391 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3392 "\x10\x11\x12\x13\x14\x15\x16\x17",
3393 .klen = 24,
3394 .input = "\x00\x11\x22\x33\x44\x55\x66\x77"
3395 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
3396 .ilen = 16,
3397 .result = "\xdd\xa9\x7c\xa4\x86\x4c\xdf\xe0"
3398 "\x6e\xaf\x70\xa0\xec\x0d\x71\x91",
3399 .rlen = 16,
3400 }, {
3401 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3402 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3403 "\x10\x11\x12\x13\x14\x15\x16\x17"
3404 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
3405 .klen = 32,
3406 .input = "\x00\x11\x22\x33\x44\x55\x66\x77"
3407 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
3408 .ilen = 16,
3409 .result = "\x8e\xa2\xb7\xca\x51\x67\x45\xbf"
3410 "\xea\xfc\x49\x90\x4b\x49\x60\x89",
3411 .rlen = 16,
3412 },
3413};
3414
3415static struct cipher_testvec aes_dec_tv_template[] = {
3416 {
3417 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3418 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3419 .klen = 16,
3420 .input = "\x69\xc4\xe0\xd8\x6a\x7b\x04\x30"
3421 "\xd8\xcd\xb7\x80\x70\xb4\xc5\x5a",
3422 .ilen = 16,
3423 .result = "\x00\x11\x22\x33\x44\x55\x66\x77"
3424 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
3425 .rlen = 16,
3426 }, {
3427 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3428 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3429 "\x10\x11\x12\x13\x14\x15\x16\x17",
3430 .klen = 24,
3431 .input = "\xdd\xa9\x7c\xa4\x86\x4c\xdf\xe0"
3432 "\x6e\xaf\x70\xa0\xec\x0d\x71\x91",
3433 .ilen = 16,
3434 .result = "\x00\x11\x22\x33\x44\x55\x66\x77"
3435 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
3436 .rlen = 16,
3437 }, {
3438 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
3439 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3440 "\x10\x11\x12\x13\x14\x15\x16\x17"
3441 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
3442 .klen = 32,
3443 .input = "\x8e\xa2\xb7\xca\x51\x67\x45\xbf"
3444 "\xea\xfc\x49\x90\x4b\x49\x60\x89",
3445 .ilen = 16,
3446 .result = "\x00\x11\x22\x33\x44\x55\x66\x77"
3447 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
3448 .rlen = 16,
3449 },
3450};
3451
3452static struct cipher_testvec aes_cbc_enc_tv_template[] = {
3453 {
3454 .key = "\x06\xa9\x21\x40\x36\xb8\xa1\x5b"
3455 "\x51\x2e\x03\xd5\x34\x12\x00\x06",
3456 .klen = 16,
3457 .iv = "\x3d\xaf\xba\x42\x9d\x9e\xb4\x30"
3458 "\xb4\x22\xda\x80\x2c\x9f\xac\x41",
3459 .input = "Single block msg",
3460 .ilen = 16,
3461 .result = "\xe3\x53\x77\x9c\x10\x79\xae\xb8"
3462 "\x27\x08\x94\x2d\xbe\x77\x18\x1a",
3463 .rlen = 16,
3464 }, {
3465 .key = "\xc2\x86\x69\x6d\x88\x7c\x9a\xa0"
3466 "\x61\x1b\xbb\x3e\x20\x25\xa4\x5a",
3467 .klen = 16,
3468 .iv = "\x56\x2e\x17\x99\x6d\x09\x3d\x28"
3469 "\xdd\xb3\xba\x69\x5a\x2e\x6f\x58",
3470 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
3471 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3472 "\x10\x11\x12\x13\x14\x15\x16\x17"
3473 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
3474 .ilen = 32,
3475 .result = "\xd2\x96\xcd\x94\xc2\xcc\xcf\x8a"
3476 "\x3a\x86\x30\x28\xb5\xe1\xdc\x0a"
3477 "\x75\x86\x60\x2d\x25\x3c\xff\xf9"
3478 "\x1b\x82\x66\xbe\xa6\xd6\x1a\xb1",
3479 .rlen = 32,
3480 }, {
3481 .key = "\x8e\x73\xb0\xf7\xda\x0e\x64\x52"
3482 "\xc8\x10\xf3\x2b\x80\x90\x79\xe5"
3483 "\x62\xf8\xea\xd2\x52\x2c\x6b\x7b",
3484 .klen = 24,
3485 .iv = "\x00\x01\x02\x03\x04\x05\x06\x07"
3486 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3487 .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
3488 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
3489 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
3490 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
3491 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
3492 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
3493 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
3494 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
3495 .ilen = 64,
3496 .result = "\x4f\x02\x1d\xb2\x43\xbc\x63\x3d"
3497 "\x71\x78\x18\x3a\x9f\xa0\x71\xe8"
3498 "\xb4\xd9\xad\xa9\xad\x7d\xed\xf4"
3499 "\xe5\xe7\x38\x76\x3f\x69\x14\x5a"
3500 "\x57\x1b\x24\x20\x12\xfb\x7a\xe0"
3501 "\x7f\xa9\xba\xac\x3d\xf1\x02\xe0"
3502 "\x08\xb0\xe2\x79\x88\x59\x88\x81"
3503 "\xd9\x20\xa9\xe6\x4f\x56\x15\xcd",
3504 .rlen = 64,
3505 }, {
3506 .key = "\x60\x3d\xeb\x10\x15\xca\x71\xbe"
3507 "\x2b\x73\xae\xf0\x85\x7d\x77\x81"
3508 "\x1f\x35\x2c\x07\x3b\x61\x08\xd7"
3509 "\x2d\x98\x10\xa3\x09\x14\xdf\xf4",
3510 .klen = 32,
3511 .iv = "\x00\x01\x02\x03\x04\x05\x06\x07"
3512 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3513 .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
3514 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
3515 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
3516 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
3517 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
3518 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
3519 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
3520 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
3521 .ilen = 64,
3522 .result = "\xf5\x8c\x4c\x04\xd6\xe5\xf1\xba"
3523 "\x77\x9e\xab\xfb\x5f\x7b\xfb\xd6"
3524 "\x9c\xfc\x4e\x96\x7e\xdb\x80\x8d"
3525 "\x67\x9f\x77\x7b\xc6\x70\x2c\x7d"
3526 "\x39\xf2\x33\x69\xa9\xd9\xba\xcf"
3527 "\xa5\x30\xe2\x63\x04\x23\x14\x61"
3528 "\xb2\xeb\x05\xe2\xc3\x9b\xe9\xfc"
3529 "\xda\x6c\x19\x07\x8c\x6a\x9d\x1b",
3530 .rlen = 64,
3531 },
3532};
3533
3534static struct cipher_testvec aes_cbc_dec_tv_template[] = {
3535 {
3536 .key = "\x06\xa9\x21\x40\x36\xb8\xa1\x5b"
3537 "\x51\x2e\x03\xd5\x34\x12\x00\x06",
3538 .klen = 16,
3539 .iv = "\x3d\xaf\xba\x42\x9d\x9e\xb4\x30"
3540 "\xb4\x22\xda\x80\x2c\x9f\xac\x41",
3541 .input = "\xe3\x53\x77\x9c\x10\x79\xae\xb8"
3542 "\x27\x08\x94\x2d\xbe\x77\x18\x1a",
3543 .ilen = 16,
3544 .result = "Single block msg",
3545 .rlen = 16,
3546 }, {
3547 .key = "\xc2\x86\x69\x6d\x88\x7c\x9a\xa0"
3548 "\x61\x1b\xbb\x3e\x20\x25\xa4\x5a",
3549 .klen = 16,
3550 .iv = "\x56\x2e\x17\x99\x6d\x09\x3d\x28"
3551 "\xdd\xb3\xba\x69\x5a\x2e\x6f\x58",
3552 .input = "\xd2\x96\xcd\x94\xc2\xcc\xcf\x8a"
3553 "\x3a\x86\x30\x28\xb5\xe1\xdc\x0a"
3554 "\x75\x86\x60\x2d\x25\x3c\xff\xf9"
3555 "\x1b\x82\x66\xbe\xa6\xd6\x1a\xb1",
3556 .ilen = 32,
3557 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
3558 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
3559 "\x10\x11\x12\x13\x14\x15\x16\x17"
3560 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
3561 .rlen = 32,
3562 }, {
3563 .key = "\x8e\x73\xb0\xf7\xda\x0e\x64\x52"
3564 "\xc8\x10\xf3\x2b\x80\x90\x79\xe5"
3565 "\x62\xf8\xea\xd2\x52\x2c\x6b\x7b",
3566 .klen = 24,
3567 .iv = "\x00\x01\x02\x03\x04\x05\x06\x07"
3568 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3569 .input = "\x4f\x02\x1d\xb2\x43\xbc\x63\x3d"
3570 "\x71\x78\x18\x3a\x9f\xa0\x71\xe8"
3571 "\xb4\xd9\xad\xa9\xad\x7d\xed\xf4"
3572 "\xe5\xe7\x38\x76\x3f\x69\x14\x5a"
3573 "\x57\x1b\x24\x20\x12\xfb\x7a\xe0"
3574 "\x7f\xa9\xba\xac\x3d\xf1\x02\xe0"
3575 "\x08\xb0\xe2\x79\x88\x59\x88\x81"
3576 "\xd9\x20\xa9\xe6\x4f\x56\x15\xcd",
3577 .ilen = 64,
3578 .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
3579 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
3580 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
3581 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
3582 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
3583 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
3584 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
3585 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
3586 .rlen = 64,
3587 }, {
3588 .key = "\x60\x3d\xeb\x10\x15\xca\x71\xbe"
3589 "\x2b\x73\xae\xf0\x85\x7d\x77\x81"
3590 "\x1f\x35\x2c\x07\x3b\x61\x08\xd7"
3591 "\x2d\x98\x10\xa3\x09\x14\xdf\xf4",
3592 .klen = 32,
3593 .iv = "\x00\x01\x02\x03\x04\x05\x06\x07"
3594 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
3595 .input = "\xf5\x8c\x4c\x04\xd6\xe5\xf1\xba"
3596 "\x77\x9e\xab\xfb\x5f\x7b\xfb\xd6"
3597 "\x9c\xfc\x4e\x96\x7e\xdb\x80\x8d"
3598 "\x67\x9f\x77\x7b\xc6\x70\x2c\x7d"
3599 "\x39\xf2\x33\x69\xa9\xd9\xba\xcf"
3600 "\xa5\x30\xe2\x63\x04\x23\x14\x61"
3601 "\xb2\xeb\x05\xe2\xc3\x9b\xe9\xfc"
3602 "\xda\x6c\x19\x07\x8c\x6a\x9d\x1b",
3603 .ilen = 64,
3604 .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
3605 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
3606 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
3607 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
3608 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
3609 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
3610 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
3611 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
3612 .rlen = 64,
3613 },
3614};
3615
3616static struct cipher_testvec aes_lrw_enc_tv_template[] = {
3617
3618 {
3619 .key = "\x45\x62\xac\x25\xf8\x28\x17\x6d"
3620 "\x4c\x26\x84\x14\xb5\x68\x01\x85"
3621 "\x25\x8e\x2a\x05\xe7\x3e\x9d\x03"
3622 "\xee\x5a\x83\x0c\xcc\x09\x4c\x87",
3623 .klen = 32,
3624 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3625 "\x00\x00\x00\x00\x00\x00\x00\x01",
3626 .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
3627 "\x38\x39\x41\x42\x43\x44\x45\x46",
3628 .ilen = 16,
3629 .result = "\xf1\xb2\x73\xcd\x65\xa3\xdf\x5f"
3630 "\xe9\x5d\x48\x92\x54\x63\x4e\xb8",
3631 .rlen = 16,
3632 }, {
3633 .key = "\x59\x70\x47\x14\xf5\x57\x47\x8c"
3634 "\xd7\x79\xe8\x0f\x54\x88\x79\x44"
3635 "\x0d\x48\xf0\xb7\xb1\x5a\x53\xea"
3636 "\x1c\xaa\x6b\x29\xc2\xca\xfb\xaf",
3637 .klen = 32,
3638 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3639 "\x00\x00\x00\x00\x00\x00\x00\x02",
3640 .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
3641 "\x38\x39\x41\x42\x43\x44\x45\x46",
3642 .ilen = 16,
3643 .result = "\x00\xc8\x2b\xae\x95\xbb\xcd\xe5"
3644 "\x27\x4f\x07\x69\xb2\x60\xe1\x36",
3645 .rlen = 16,
3646 }, {
3647 .key = "\xd8\x2a\x91\x34\xb2\x6a\x56\x50"
3648 "\x30\xfe\x69\xe2\x37\x7f\x98\x47"
3649 "\xcd\xf9\x0b\x16\x0c\x64\x8f\xb6"
3650 "\xb0\x0d\x0d\x1b\xae\x85\x87\x1f",
3651 .klen = 32,
3652 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3653 "\x00\x00\x00\x02\x00\x00\x00\x00",
3654 .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
3655 "\x38\x39\x41\x42\x43\x44\x45\x46",
3656 .ilen = 16,
3657 .result = "\x76\x32\x21\x83\xed\x8f\xf1\x82"
3658 "\xf9\x59\x62\x03\x69\x0e\x5e\x01",
3659 .rlen = 16,
3660 }, {
3661 .key = "\x0f\x6a\xef\xf8\xd3\xd2\xbb\x15"
3662 "\x25\x83\xf7\x3c\x1f\x01\x28\x74"
3663 "\xca\xc6\xbc\x35\x4d\x4a\x65\x54"
3664 "\x90\xae\x61\xcf\x7b\xae\xbd\xcc"
3665 "\xad\xe4\x94\xc5\x4a\x29\xae\x70",
3666 .klen = 40,
3667 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3668 "\x00\x00\x00\x00\x00\x00\x00\x01",
3669 .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
3670 "\x38\x39\x41\x42\x43\x44\x45\x46",
3671 .ilen = 16,
3672 .result = "\x9c\x0f\x15\x2f\x55\xa2\xd8\xf0"
3673 "\xd6\x7b\x8f\x9e\x28\x22\xbc\x41",
3674 .rlen = 16,
3675 }, {
3676 .key = "\x8a\xd4\xee\x10\x2f\xbd\x81\xff"
3677 "\xf8\x86\xce\xac\x93\xc5\xad\xc6"
3678 "\xa0\x19\x07\xc0\x9d\xf7\xbb\xdd"
3679 "\x52\x13\xb2\xb7\xf0\xff\x11\xd8"
3680 "\xd6\x08\xd0\xcd\x2e\xb1\x17\x6f",
3681 .klen = 40,
3682 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3683 "\x00\x00\x00\x02\x00\x00\x00\x00",
3684 .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
3685 "\x38\x39\x41\x42\x43\x44\x45\x46",
3686 .ilen = 16,
3687 .result = "\xd4\x27\x6a\x7f\x14\x91\x3d\x65"
3688 "\xc8\x60\x48\x02\x87\xe3\x34\x06",
3689 .rlen = 16,
3690 }, {
3691 .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
3692 "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
3693 "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
3694 "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
3695 "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
3696 "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
3697 .klen = 48,
3698 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3699 "\x00\x00\x00\x00\x00\x00\x00\x01",
3700 .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
3701 "\x38\x39\x41\x42\x43\x44\x45\x46",
3702 .ilen = 16,
3703 .result = "\xbd\x06\xb8\xe1\xdb\x98\x89\x9e"
3704 "\xc4\x98\xe4\x91\xcf\x1c\x70\x2b",
3705 .rlen = 16,
3706 }, {
3707 .key = "\xfb\x76\x15\xb2\x3d\x80\x89\x1d"
3708 "\xd4\x70\x98\x0b\xc7\x95\x84\xc8"
3709 "\xb2\xfb\x64\xce\x60\x97\x87\x8d"
3710 "\x17\xfc\xe4\x5a\x49\xe8\x30\xb7"
3711 "\x6e\x78\x17\xe7\x2d\x5e\x12\xd4"
3712 "\x60\x64\x04\x7a\xf1\x2f\x9e\x0c",
3713 .klen = 48,
3714 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3715 "\x00\x00\x00\x02\x00\x00\x00\x00",
3716 .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
3717 "\x38\x39\x41\x42\x43\x44\x45\x46",
3718 .ilen = 16,
3719 .result = "\x5b\x90\x8e\xc1\xab\xdd\x67\x5f"
3720 "\x3d\x69\x8a\x95\x53\xc8\x9c\xe5",
3721 .rlen = 16,
3722 }, {
3723
3724 .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
3725 "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
3726 "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
3727 "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
3728 "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
3729 "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
3730 .klen = 48,
3731 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3732 "\x00\x00\x00\x00\x00\x00\x00\x01",
3733 .input = "\x05\x11\xb7\x18\xab\xc6\x2d\xac"
3734 "\x70\x5d\xf6\x22\x94\xcd\xe5\x6c"
3735 "\x17\x6b\xf6\x1c\xf0\xf3\x6e\xf8"
3736 "\x50\x38\x1f\x71\x49\xb6\x57\xd6"
3737 "\x8f\xcb\x8d\x6b\xe3\xa6\x29\x90"
3738 "\xfe\x2a\x62\x82\xae\x6d\x8b\xf6"
3739 "\xad\x1e\x9e\x20\x5f\x38\xbe\x04"
3740 "\xda\x10\x8e\xed\xa2\xa4\x87\xab"
3741 "\xda\x6b\xb4\x0c\x75\xba\xd3\x7c"
3742 "\xc9\xac\x42\x31\x95\x7c\xc9\x04"
3743 "\xeb\xd5\x6e\x32\x69\x8a\xdb\xa6"
3744 "\x15\xd7\x3f\x4f\x2f\x66\x69\x03"
3745 "\x9c\x1f\x54\x0f\xde\x1f\xf3\x65"
3746 "\x4c\x96\x12\xed\x7c\x92\x03\x01"
3747 "\x6f\xbc\x35\x93\xac\xf1\x27\xf1"
3748 "\xb4\x96\x82\x5a\x5f\xb0\xa0\x50"
3749 "\x89\xa4\x8e\x66\x44\x85\xcc\xfd"
3750 "\x33\x14\x70\xe3\x96\xb2\xc3\xd3"
3751 "\xbb\x54\x5a\x1a\xf9\x74\xa2\xc5"
3752 "\x2d\x64\x75\xdd\xb4\x54\xe6\x74"
3753 "\x8c\xd3\x9d\x9e\x86\xab\x51\x53"
3754 "\xb7\x93\x3e\x6f\xd0\x4e\x2c\x40"
3755 "\xf6\xa8\x2e\x3e\x9d\xf4\x66\xa5"
3756 "\x76\x12\x73\x44\x1a\x56\xd7\x72"
3757 "\x88\xcd\x21\x8c\x4c\x0f\xfe\xda"
3758 "\x95\xe0\x3a\xa6\xa5\x84\x46\xcd"
3759 "\xd5\x3e\x9d\x3a\xe2\x67\xe6\x60"
3760 "\x1a\xe2\x70\x85\x58\xc2\x1b\x09"
3761 "\xe1\xd7\x2c\xca\xad\xa8\x8f\xf9"
3762 "\xac\xb3\x0e\xdb\xca\x2e\xe2\xb8"
3763 "\x51\x71\xd9\x3c\x6c\xf1\x56\xf8"
3764 "\xea\x9c\xf1\xfb\x0c\xe6\xb7\x10"
3765 "\x1c\xf8\xa9\x7c\xe8\x53\x35\xc1"
3766 "\x90\x3e\x76\x4a\x74\xa4\x21\x2c"
3767 "\xf6\x2c\x4e\x0f\x94\x3a\x88\x2e"
3768 "\x41\x09\x6a\x33\x7d\xf6\xdd\x3f"
3769 "\x8d\x23\x31\x74\x84\xeb\x88\x6e"
3770 "\xcc\xb9\xbc\x22\x83\x19\x07\x22"
3771 "\xa5\x2d\xdf\xa5\xf3\x80\x85\x78"
3772 "\x84\x39\x6a\x6d\x6a\x99\x4f\xa5"
3773 "\x15\xfe\x46\xb0\xe4\x6c\xa5\x41"
3774 "\x3c\xce\x8f\x42\x60\x71\xa7\x75"
3775 "\x08\x40\x65\x8a\x82\xbf\xf5\x43"
3776 "\x71\x96\xa9\x4d\x44\x8a\x20\xbe"
3777 "\xfa\x4d\xbb\xc0\x7d\x31\x96\x65"
3778 "\xe7\x75\xe5\x3e\xfd\x92\x3b\xc9"
3779 "\x55\xbb\x16\x7e\xf7\xc2\x8c\xa4"
3780 "\x40\x1d\xe5\xef\x0e\xdf\xe4\x9a"
3781 "\x62\x73\x65\xfd\x46\x63\x25\x3d"
3782 "\x2b\xaf\xe5\x64\xfe\xa5\x5c\xcf"
3783 "\x24\xf3\xb4\xac\x64\xba\xdf\x4b"
3784 "\xc6\x96\x7d\x81\x2d\x8d\x97\xf7"
3785 "\xc5\x68\x77\x84\x32\x2b\xcc\x85"
3786 "\x74\x96\xf0\x12\x77\x61\xb9\xeb"
3787 "\x71\xaa\x82\xcb\x1c\xdb\x89\xc8"
3788 "\xc6\xb5\xe3\x5c\x7d\x39\x07\x24"
3789 "\xda\x39\x87\x45\xc0\x2b\xbb\x01"
3790 "\xac\xbc\x2a\x5c\x7f\xfc\xe8\xce"
3791 "\x6d\x9c\x6f\xed\xd3\xc1\xa1\xd6"
3792 "\xc5\x55\xa9\x66\x2f\xe1\xc8\x32"
3793 "\xa6\x5d\xa4\x3a\x98\x73\xe8\x45"
3794 "\xa4\xc7\xa8\xb4\xf6\x13\x03\xf6"
3795 "\xe9\x2e\xc4\x29\x0f\x84\xdb\xc4"
3796 "\x21\xc4\xc2\x75\x67\x89\x37\x0a",
3797 .ilen = 512,
3798 .result = "\x1a\x1d\xa9\x30\xad\xf9\x2f\x9b"
3799 "\xb6\x1d\xae\xef\xf0\x2f\xf8\x5a"
3800 "\x39\x3c\xbf\x2a\xb2\x45\xb2\x23"
3801 "\x1b\x63\x3c\xcf\xaa\xbe\xcf\x4e"
3802 "\xfa\xe8\x29\xc2\x20\x68\x2b\x3c"
3803 "\x2e\x8b\xf7\x6e\x25\xbd\xe3\x3d"
3804 "\x66\x27\xd6\xaf\xd6\x64\x3e\xe3"
3805 "\xe8\x58\x46\x97\x39\x51\x07\xde"
3806 "\xcb\x37\xbc\xa9\xc0\x5f\x75\xc3"
3807 "\x0e\x84\x23\x1d\x16\xd4\x1c\x59"
3808 "\x9c\x1a\x02\x55\xab\x3a\x97\x1d"
3809 "\xdf\xdd\xc7\x06\x51\xd7\x70\xae"
3810 "\x23\xc6\x8c\xf5\x1e\xa0\xe5\x82"
3811 "\xb8\xb2\xbf\x04\xa0\x32\x8e\x68"
3812 "\xeb\xaf\x6e\x2d\x94\x22\x2f\xce"
3813 "\x4c\xb5\x59\xe2\xa2\x2f\xa0\x98"
3814 "\x1a\x97\xc6\xd4\xb5\x00\x59\xf2"
3815 "\x84\x14\x72\xb1\x9a\x6e\xa3\x7f"
3816 "\xea\x20\xe7\xcb\x65\x77\x3a\xdf"
3817 "\xc8\x97\x67\x15\xc2\x2a\x27\xcc"
3818 "\x18\x55\xa1\x24\x0b\x24\x24\xaf"
3819 "\x5b\xec\x68\xb8\xc8\xf5\xba\x63"
3820 "\xff\xed\x89\xce\xd5\x3d\x88\xf3"
3821 "\x25\xef\x05\x7c\x3a\xef\xeb\xd8"
3822 "\x7a\x32\x0d\xd1\x1e\x58\x59\x99"
3823 "\x90\x25\xb5\x26\xb0\xe3\x2b\x6c"
3824 "\x4c\xa9\x8b\x84\x4f\x5e\x01\x50"
3825 "\x41\x30\x58\xc5\x62\x74\x52\x1d"
3826 "\x45\x24\x6a\x42\x64\x4f\x97\x1c"
3827 "\xa8\x66\xb5\x6d\x79\xd4\x0d\x48"
3828 "\xc5\x5f\xf3\x90\x32\xdd\xdd\xe1"
3829 "\xe4\xa9\x9f\xfc\xc3\x52\x5a\x46"
3830 "\xe4\x81\x84\x95\x36\x59\x7a\x6b"
3831 "\xaa\xb3\x60\xad\xce\x9f\x9f\x28"
3832 "\xe0\x01\x75\x22\xc4\x4e\xa9\x62"
3833 "\x5c\x62\x0d\x00\xcb\x13\xe8\x43"
3834 "\x72\xd4\x2d\x53\x46\xb5\xd1\x16"
3835 "\x22\x18\xdf\x34\x33\xf5\xd6\x1c"
3836 "\xb8\x79\x78\x97\x94\xff\x72\x13"
3837 "\x4c\x27\xfc\xcb\xbf\x01\x53\xa6"
3838 "\xb4\x50\x6e\xde\xdf\xb5\x43\xa4"
3839 "\x59\xdf\x52\xf9\x7c\xe0\x11\x6f"
3840 "\x2d\x14\x8e\x24\x61\x2c\xe1\x17"
3841 "\xcc\xce\x51\x0c\x19\x8a\x82\x30"
3842 "\x94\xd5\x3d\x6a\x53\x06\x5e\xbd"
3843 "\xb7\xeb\xfa\xfd\x27\x51\xde\x85"
3844 "\x1e\x86\x53\x11\x53\x94\x00\xee"
3845 "\x2b\x8c\x08\x2a\xbf\xdd\xae\x11"
3846 "\xcb\x1e\xa2\x07\x9a\x80\xcf\x62"
3847 "\x9b\x09\xdc\x95\x3c\x96\x8e\xb1"
3848 "\x09\xbd\xe4\xeb\xdb\xca\x70\x7a"
3849 "\x9e\xfa\x31\x18\x45\x3c\x21\x33"
3850 "\xb0\xb3\x2b\xea\xf3\x71\x2d\xe1"
3851 "\x03\xad\x1b\x48\xd4\x67\x27\xf0"
3852 "\x62\xe4\x3d\xfb\x9b\x08\x76\xe7"
3853 "\xdd\x2b\x01\x39\x04\x5a\x58\x7a"
3854 "\xf7\x11\x90\xec\xbd\x51\x5c\x32"
3855 "\x6b\xd7\x35\x39\x02\x6b\xf2\xa6"
3856 "\xd0\x0d\x07\xe1\x06\xc4\x5b\x7d"
3857 "\xe4\x6a\xd7\xee\x15\x1f\x83\xb4"
3858 "\xa3\xa7\x5e\xc3\x90\xb7\xef\xd3"
3859 "\xb7\x4f\xf8\x92\x4c\xb7\x3c\x29"
3860 "\xcd\x7e\x2b\x5d\x43\xea\x42\xe7"
3861 "\x74\x3f\x7d\x58\x88\x75\xde\x3e",
3862 .rlen = 512,
3863 }
3864};
3865
3866static struct cipher_testvec aes_lrw_dec_tv_template[] = {
3867
3868
3869 {
3870 .key = "\x45\x62\xac\x25\xf8\x28\x17\x6d"
3871 "\x4c\x26\x84\x14\xb5\x68\x01\x85"
3872 "\x25\x8e\x2a\x05\xe7\x3e\x9d\x03"
3873 "\xee\x5a\x83\x0c\xcc\x09\x4c\x87",
3874 .klen = 32,
3875 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3876 "\x00\x00\x00\x00\x00\x00\x00\x01",
3877 .input = "\xf1\xb2\x73\xcd\x65\xa3\xdf\x5f"
3878 "\xe9\x5d\x48\x92\x54\x63\x4e\xb8",
3879 .ilen = 16,
3880 .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
3881 "\x38\x39\x41\x42\x43\x44\x45\x46",
3882 .rlen = 16,
3883 }, {
3884 .key = "\x59\x70\x47\x14\xf5\x57\x47\x8c"
3885 "\xd7\x79\xe8\x0f\x54\x88\x79\x44"
3886 "\x0d\x48\xf0\xb7\xb1\x5a\x53\xea"
3887 "\x1c\xaa\x6b\x29\xc2\xca\xfb\xaf",
3888 .klen = 32,
3889 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3890 "\x00\x00\x00\x00\x00\x00\x00\x02",
3891 .input = "\x00\xc8\x2b\xae\x95\xbb\xcd\xe5"
3892 "\x27\x4f\x07\x69\xb2\x60\xe1\x36",
3893 .ilen = 16,
3894 .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
3895 "\x38\x39\x41\x42\x43\x44\x45\x46",
3896 .rlen = 16,
3897 }, {
3898 .key = "\xd8\x2a\x91\x34\xb2\x6a\x56\x50"
3899 "\x30\xfe\x69\xe2\x37\x7f\x98\x47"
3900 "\xcd\xf9\x0b\x16\x0c\x64\x8f\xb6"
3901 "\xb0\x0d\x0d\x1b\xae\x85\x87\x1f",
3902 .klen = 32,
3903 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3904 "\x00\x00\x00\x02\x00\x00\x00\x00",
3905 .input = "\x76\x32\x21\x83\xed\x8f\xf1\x82"
3906 "\xf9\x59\x62\x03\x69\x0e\x5e\x01",
3907 .ilen = 16,
3908 .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
3909 "\x38\x39\x41\x42\x43\x44\x45\x46",
3910 .rlen = 16,
3911 }, {
3912 .key = "\x0f\x6a\xef\xf8\xd3\xd2\xbb\x15"
3913 "\x25\x83\xf7\x3c\x1f\x01\x28\x74"
3914 "\xca\xc6\xbc\x35\x4d\x4a\x65\x54"
3915 "\x90\xae\x61\xcf\x7b\xae\xbd\xcc"
3916 "\xad\xe4\x94\xc5\x4a\x29\xae\x70",
3917 .klen = 40,
3918 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3919 "\x00\x00\x00\x00\x00\x00\x00\x01",
3920 .input = "\x9c\x0f\x15\x2f\x55\xa2\xd8\xf0"
3921 "\xd6\x7b\x8f\x9e\x28\x22\xbc\x41",
3922 .ilen = 16,
3923 .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
3924 "\x38\x39\x41\x42\x43\x44\x45\x46",
3925 .rlen = 16,
3926 }, {
3927 .key = "\x8a\xd4\xee\x10\x2f\xbd\x81\xff"
3928 "\xf8\x86\xce\xac\x93\xc5\xad\xc6"
3929 "\xa0\x19\x07\xc0\x9d\xf7\xbb\xdd"
3930 "\x52\x13\xb2\xb7\xf0\xff\x11\xd8"
3931 "\xd6\x08\xd0\xcd\x2e\xb1\x17\x6f",
3932 .klen = 40,
3933 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3934 "\x00\x00\x00\x02\x00\x00\x00\x00",
3935 .input = "\xd4\x27\x6a\x7f\x14\x91\x3d\x65"
3936 "\xc8\x60\x48\x02\x87\xe3\x34\x06",
3937 .ilen = 16,
3938 .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
3939 "\x38\x39\x41\x42\x43\x44\x45\x46",
3940 .rlen = 16,
3941 }, {
3942 .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
3943 "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
3944 "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
3945 "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
3946 "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
3947 "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
3948 .klen = 48,
3949 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3950 "\x00\x00\x00\x00\x00\x00\x00\x01",
3951 .input = "\xbd\x06\xb8\xe1\xdb\x98\x89\x9e"
3952 "\xc4\x98\xe4\x91\xcf\x1c\x70\x2b",
3953 .ilen = 16,
3954 .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
3955 "\x38\x39\x41\x42\x43\x44\x45\x46",
3956 .rlen = 16,
3957 }, {
3958 .key = "\xfb\x76\x15\xb2\x3d\x80\x89\x1d"
3959 "\xd4\x70\x98\x0b\xc7\x95\x84\xc8"
3960 "\xb2\xfb\x64\xce\x60\x97\x87\x8d"
3961 "\x17\xfc\xe4\x5a\x49\xe8\x30\xb7"
3962 "\x6e\x78\x17\xe7\x2d\x5e\x12\xd4"
3963 "\x60\x64\x04\x7a\xf1\x2f\x9e\x0c",
3964 .klen = 48,
3965 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3966 "\x00\x00\x00\x02\x00\x00\x00\x00",
3967 .input = "\x5b\x90\x8e\xc1\xab\xdd\x67\x5f"
3968 "\x3d\x69\x8a\x95\x53\xc8\x9c\xe5",
3969 .ilen = 16,
3970 .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
3971 "\x38\x39\x41\x42\x43\x44\x45\x46",
3972 .rlen = 16,
3973 }, {
3974
3975 .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
3976 "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
3977 "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
3978 "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
3979 "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
3980 "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
3981 .klen = 48,
3982 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
3983 "\x00\x00\x00\x00\x00\x00\x00\x01",
3984 .input = "\x1a\x1d\xa9\x30\xad\xf9\x2f\x9b"
3985 "\xb6\x1d\xae\xef\xf0\x2f\xf8\x5a"
3986 "\x39\x3c\xbf\x2a\xb2\x45\xb2\x23"
3987 "\x1b\x63\x3c\xcf\xaa\xbe\xcf\x4e"
3988 "\xfa\xe8\x29\xc2\x20\x68\x2b\x3c"
3989 "\x2e\x8b\xf7\x6e\x25\xbd\xe3\x3d"
3990 "\x66\x27\xd6\xaf\xd6\x64\x3e\xe3"
3991 "\xe8\x58\x46\x97\x39\x51\x07\xde"
3992 "\xcb\x37\xbc\xa9\xc0\x5f\x75\xc3"
3993 "\x0e\x84\x23\x1d\x16\xd4\x1c\x59"
3994 "\x9c\x1a\x02\x55\xab\x3a\x97\x1d"
3995 "\xdf\xdd\xc7\x06\x51\xd7\x70\xae"
3996 "\x23\xc6\x8c\xf5\x1e\xa0\xe5\x82"
3997 "\xb8\xb2\xbf\x04\xa0\x32\x8e\x68"
3998 "\xeb\xaf\x6e\x2d\x94\x22\x2f\xce"
3999 "\x4c\xb5\x59\xe2\xa2\x2f\xa0\x98"
4000 "\x1a\x97\xc6\xd4\xb5\x00\x59\xf2"
4001 "\x84\x14\x72\xb1\x9a\x6e\xa3\x7f"
4002 "\xea\x20\xe7\xcb\x65\x77\x3a\xdf"
4003 "\xc8\x97\x67\x15\xc2\x2a\x27\xcc"
4004 "\x18\x55\xa1\x24\x0b\x24\x24\xaf"
4005 "\x5b\xec\x68\xb8\xc8\xf5\xba\x63"
4006 "\xff\xed\x89\xce\xd5\x3d\x88\xf3"
4007 "\x25\xef\x05\x7c\x3a\xef\xeb\xd8"
4008 "\x7a\x32\x0d\xd1\x1e\x58\x59\x99"
4009 "\x90\x25\xb5\x26\xb0\xe3\x2b\x6c"
4010 "\x4c\xa9\x8b\x84\x4f\x5e\x01\x50"
4011 "\x41\x30\x58\xc5\x62\x74\x52\x1d"
4012 "\x45\x24\x6a\x42\x64\x4f\x97\x1c"
4013 "\xa8\x66\xb5\x6d\x79\xd4\x0d\x48"
4014 "\xc5\x5f\xf3\x90\x32\xdd\xdd\xe1"
4015 "\xe4\xa9\x9f\xfc\xc3\x52\x5a\x46"
4016 "\xe4\x81\x84\x95\x36\x59\x7a\x6b"
4017 "\xaa\xb3\x60\xad\xce\x9f\x9f\x28"
4018 "\xe0\x01\x75\x22\xc4\x4e\xa9\x62"
4019 "\x5c\x62\x0d\x00\xcb\x13\xe8\x43"
4020 "\x72\xd4\x2d\x53\x46\xb5\xd1\x16"
4021 "\x22\x18\xdf\x34\x33\xf5\xd6\x1c"
4022 "\xb8\x79\x78\x97\x94\xff\x72\x13"
4023 "\x4c\x27\xfc\xcb\xbf\x01\x53\xa6"
4024 "\xb4\x50\x6e\xde\xdf\xb5\x43\xa4"
4025 "\x59\xdf\x52\xf9\x7c\xe0\x11\x6f"
4026 "\x2d\x14\x8e\x24\x61\x2c\xe1\x17"
4027 "\xcc\xce\x51\x0c\x19\x8a\x82\x30"
4028 "\x94\xd5\x3d\x6a\x53\x06\x5e\xbd"
4029 "\xb7\xeb\xfa\xfd\x27\x51\xde\x85"
4030 "\x1e\x86\x53\x11\x53\x94\x00\xee"
4031 "\x2b\x8c\x08\x2a\xbf\xdd\xae\x11"
4032 "\xcb\x1e\xa2\x07\x9a\x80\xcf\x62"
4033 "\x9b\x09\xdc\x95\x3c\x96\x8e\xb1"
4034 "\x09\xbd\xe4\xeb\xdb\xca\x70\x7a"
4035 "\x9e\xfa\x31\x18\x45\x3c\x21\x33"
4036 "\xb0\xb3\x2b\xea\xf3\x71\x2d\xe1"
4037 "\x03\xad\x1b\x48\xd4\x67\x27\xf0"
4038 "\x62\xe4\x3d\xfb\x9b\x08\x76\xe7"
4039 "\xdd\x2b\x01\x39\x04\x5a\x58\x7a"
4040 "\xf7\x11\x90\xec\xbd\x51\x5c\x32"
4041 "\x6b\xd7\x35\x39\x02\x6b\xf2\xa6"
4042 "\xd0\x0d\x07\xe1\x06\xc4\x5b\x7d"
4043 "\xe4\x6a\xd7\xee\x15\x1f\x83\xb4"
4044 "\xa3\xa7\x5e\xc3\x90\xb7\xef\xd3"
4045 "\xb7\x4f\xf8\x92\x4c\xb7\x3c\x29"
4046 "\xcd\x7e\x2b\x5d\x43\xea\x42\xe7"
4047 "\x74\x3f\x7d\x58\x88\x75\xde\x3e",
4048 .ilen = 512,
4049 .result = "\x05\x11\xb7\x18\xab\xc6\x2d\xac"
4050 "\x70\x5d\xf6\x22\x94\xcd\xe5\x6c"
4051 "\x17\x6b\xf6\x1c\xf0\xf3\x6e\xf8"
4052 "\x50\x38\x1f\x71\x49\xb6\x57\xd6"
4053 "\x8f\xcb\x8d\x6b\xe3\xa6\x29\x90"
4054 "\xfe\x2a\x62\x82\xae\x6d\x8b\xf6"
4055 "\xad\x1e\x9e\x20\x5f\x38\xbe\x04"
4056 "\xda\x10\x8e\xed\xa2\xa4\x87\xab"
4057 "\xda\x6b\xb4\x0c\x75\xba\xd3\x7c"
4058 "\xc9\xac\x42\x31\x95\x7c\xc9\x04"
4059 "\xeb\xd5\x6e\x32\x69\x8a\xdb\xa6"
4060 "\x15\xd7\x3f\x4f\x2f\x66\x69\x03"
4061 "\x9c\x1f\x54\x0f\xde\x1f\xf3\x65"
4062 "\x4c\x96\x12\xed\x7c\x92\x03\x01"
4063 "\x6f\xbc\x35\x93\xac\xf1\x27\xf1"
4064 "\xb4\x96\x82\x5a\x5f\xb0\xa0\x50"
4065 "\x89\xa4\x8e\x66\x44\x85\xcc\xfd"
4066 "\x33\x14\x70\xe3\x96\xb2\xc3\xd3"
4067 "\xbb\x54\x5a\x1a\xf9\x74\xa2\xc5"
4068 "\x2d\x64\x75\xdd\xb4\x54\xe6\x74"
4069 "\x8c\xd3\x9d\x9e\x86\xab\x51\x53"
4070 "\xb7\x93\x3e\x6f\xd0\x4e\x2c\x40"
4071 "\xf6\xa8\x2e\x3e\x9d\xf4\x66\xa5"
4072 "\x76\x12\x73\x44\x1a\x56\xd7\x72"
4073 "\x88\xcd\x21\x8c\x4c\x0f\xfe\xda"
4074 "\x95\xe0\x3a\xa6\xa5\x84\x46\xcd"
4075 "\xd5\x3e\x9d\x3a\xe2\x67\xe6\x60"
4076 "\x1a\xe2\x70\x85\x58\xc2\x1b\x09"
4077 "\xe1\xd7\x2c\xca\xad\xa8\x8f\xf9"
4078 "\xac\xb3\x0e\xdb\xca\x2e\xe2\xb8"
4079 "\x51\x71\xd9\x3c\x6c\xf1\x56\xf8"
4080 "\xea\x9c\xf1\xfb\x0c\xe6\xb7\x10"
4081 "\x1c\xf8\xa9\x7c\xe8\x53\x35\xc1"
4082 "\x90\x3e\x76\x4a\x74\xa4\x21\x2c"
4083 "\xf6\x2c\x4e\x0f\x94\x3a\x88\x2e"
4084 "\x41\x09\x6a\x33\x7d\xf6\xdd\x3f"
4085 "\x8d\x23\x31\x74\x84\xeb\x88\x6e"
4086 "\xcc\xb9\xbc\x22\x83\x19\x07\x22"
4087 "\xa5\x2d\xdf\xa5\xf3\x80\x85\x78"
4088 "\x84\x39\x6a\x6d\x6a\x99\x4f\xa5"
4089 "\x15\xfe\x46\xb0\xe4\x6c\xa5\x41"
4090 "\x3c\xce\x8f\x42\x60\x71\xa7\x75"
4091 "\x08\x40\x65\x8a\x82\xbf\xf5\x43"
4092 "\x71\x96\xa9\x4d\x44\x8a\x20\xbe"
4093 "\xfa\x4d\xbb\xc0\x7d\x31\x96\x65"
4094 "\xe7\x75\xe5\x3e\xfd\x92\x3b\xc9"
4095 "\x55\xbb\x16\x7e\xf7\xc2\x8c\xa4"
4096 "\x40\x1d\xe5\xef\x0e\xdf\xe4\x9a"
4097 "\x62\x73\x65\xfd\x46\x63\x25\x3d"
4098 "\x2b\xaf\xe5\x64\xfe\xa5\x5c\xcf"
4099 "\x24\xf3\xb4\xac\x64\xba\xdf\x4b"
4100 "\xc6\x96\x7d\x81\x2d\x8d\x97\xf7"
4101 "\xc5\x68\x77\x84\x32\x2b\xcc\x85"
4102 "\x74\x96\xf0\x12\x77\x61\xb9\xeb"
4103 "\x71\xaa\x82\xcb\x1c\xdb\x89\xc8"
4104 "\xc6\xb5\xe3\x5c\x7d\x39\x07\x24"
4105 "\xda\x39\x87\x45\xc0\x2b\xbb\x01"
4106 "\xac\xbc\x2a\x5c\x7f\xfc\xe8\xce"
4107 "\x6d\x9c\x6f\xed\xd3\xc1\xa1\xd6"
4108 "\xc5\x55\xa9\x66\x2f\xe1\xc8\x32"
4109 "\xa6\x5d\xa4\x3a\x98\x73\xe8\x45"
4110 "\xa4\xc7\xa8\xb4\xf6\x13\x03\xf6"
4111 "\xe9\x2e\xc4\x29\x0f\x84\xdb\xc4"
4112 "\x21\xc4\xc2\x75\x67\x89\x37\x0a",
4113 .rlen = 512,
4114 }
4115};
4116
4117static struct cipher_testvec aes_xts_enc_tv_template[] = {
4118
4119 {
4120 .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
4121 "\x00\x00\x00\x00\x00\x00\x00\x00"
4122 "\x00\x00\x00\x00\x00\x00\x00\x00"
4123 "\x00\x00\x00\x00\x00\x00\x00\x00",
4124 .klen = 32,
4125 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
4126 "\x00\x00\x00\x00\x00\x00\x00\x00",
4127 .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
4128 "\x00\x00\x00\x00\x00\x00\x00\x00"
4129 "\x00\x00\x00\x00\x00\x00\x00\x00"
4130 "\x00\x00\x00\x00\x00\x00\x00\x00",
4131 .ilen = 32,
4132 .result = "\x91\x7c\xf6\x9e\xbd\x68\xb2\xec"
4133 "\x9b\x9f\xe9\xa3\xea\xdd\xa6\x92"
4134 "\xcd\x43\xd2\xf5\x95\x98\xed\x85"
4135 "\x8c\x02\xc2\x65\x2f\xbf\x92\x2e",
4136 .rlen = 32,
4137 }, {
4138 .key = "\x11\x11\x11\x11\x11\x11\x11\x11"
4139 "\x11\x11\x11\x11\x11\x11\x11\x11"
4140 "\x22\x22\x22\x22\x22\x22\x22\x22"
4141 "\x22\x22\x22\x22\x22\x22\x22\x22",
4142 .klen = 32,
4143 .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
4144 "\x00\x00\x00\x00\x00\x00\x00\x00",
4145 .input = "\x44\x44\x44\x44\x44\x44\x44\x44"
4146 "\x44\x44\x44\x44\x44\x44\x44\x44"
4147 "\x44\x44\x44\x44\x44\x44\x44\x44"
4148 "\x44\x44\x44\x44\x44\x44\x44\x44",
4149 .ilen = 32,
4150 .result = "\xc4\x54\x18\x5e\x6a\x16\x93\x6e"
4151 "\x39\x33\x40\x38\xac\xef\x83\x8b"
4152 "\xfb\x18\x6f\xff\x74\x80\xad\xc4"
4153 "\x28\x93\x82\xec\xd6\xd3\x94\xf0",
4154 .rlen = 32,
4155 }, {
4156 .key = "\xff\xfe\xfd\xfc\xfb\xfa\xf9\xf8"
4157 "\xf7\xf6\xf5\xf4\xf3\xf2\xf1\xf0"
4158 "\x22\x22\x22\x22\x22\x22\x22\x22"
4159 "\x22\x22\x22\x22\x22\x22\x22\x22",
4160 .klen = 32,
4161 .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
4162 "\x00\x00\x00\x00\x00\x00\x00\x00",
4163 .input = "\x44\x44\x44\x44\x44\x44\x44\x44"
4164 "\x44\x44\x44\x44\x44\x44\x44\x44"
4165 "\x44\x44\x44\x44\x44\x44\x44\x44"
4166 "\x44\x44\x44\x44\x44\x44\x44\x44",
4167 .ilen = 32,
4168 .result = "\xaf\x85\x33\x6b\x59\x7a\xfc\x1a"
4169 "\x90\x0b\x2e\xb2\x1e\xc9\x49\xd2"
4170 "\x92\xdf\x4c\x04\x7e\x0b\x21\x53"
4171 "\x21\x86\xa5\x97\x1a\x22\x7a\x89",
4172 .rlen = 32,
4173 }, {
4174 .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
4175 "\x23\x53\x60\x28\x74\x71\x35\x26"
4176 "\x31\x41\x59\x26\x53\x58\x97\x93"
4177 "\x23\x84\x62\x64\x33\x83\x27\x95",
4178 .klen = 32,
4179 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
4180 "\x00\x00\x00\x00\x00\x00\x00\x00",
4181 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
4182 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4183 "\x10\x11\x12\x13\x14\x15\x16\x17"
4184 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
4185 "\x20\x21\x22\x23\x24\x25\x26\x27"
4186 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
4187 "\x30\x31\x32\x33\x34\x35\x36\x37"
4188 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
4189 "\x40\x41\x42\x43\x44\x45\x46\x47"
4190 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
4191 "\x50\x51\x52\x53\x54\x55\x56\x57"
4192 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
4193 "\x60\x61\x62\x63\x64\x65\x66\x67"
4194 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
4195 "\x70\x71\x72\x73\x74\x75\x76\x77"
4196 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
4197 "\x80\x81\x82\x83\x84\x85\x86\x87"
4198 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
4199 "\x90\x91\x92\x93\x94\x95\x96\x97"
4200 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
4201 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
4202 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
4203 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
4204 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
4205 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
4206 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
4207 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
4208 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
4209 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
4210 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
4211 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4212 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
4213 "\x00\x01\x02\x03\x04\x05\x06\x07"
4214 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4215 "\x10\x11\x12\x13\x14\x15\x16\x17"
4216 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
4217 "\x20\x21\x22\x23\x24\x25\x26\x27"
4218 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
4219 "\x30\x31\x32\x33\x34\x35\x36\x37"
4220 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
4221 "\x40\x41\x42\x43\x44\x45\x46\x47"
4222 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
4223 "\x50\x51\x52\x53\x54\x55\x56\x57"
4224 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
4225 "\x60\x61\x62\x63\x64\x65\x66\x67"
4226 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
4227 "\x70\x71\x72\x73\x74\x75\x76\x77"
4228 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
4229 "\x80\x81\x82\x83\x84\x85\x86\x87"
4230 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
4231 "\x90\x91\x92\x93\x94\x95\x96\x97"
4232 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
4233 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
4234 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
4235 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
4236 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
4237 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
4238 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
4239 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
4240 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
4241 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
4242 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
4243 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4244 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4245 .ilen = 512,
4246 .result = "\x27\xa7\x47\x9b\xef\xa1\xd4\x76"
4247 "\x48\x9f\x30\x8c\xd4\xcf\xa6\xe2"
4248 "\xa9\x6e\x4b\xbe\x32\x08\xff\x25"
4249 "\x28\x7d\xd3\x81\x96\x16\xe8\x9c"
4250 "\xc7\x8c\xf7\xf5\xe5\x43\x44\x5f"
4251 "\x83\x33\xd8\xfa\x7f\x56\x00\x00"
4252 "\x05\x27\x9f\xa5\xd8\xb5\xe4\xad"
4253 "\x40\xe7\x36\xdd\xb4\xd3\x54\x12"
4254 "\x32\x80\x63\xfd\x2a\xab\x53\xe5"
4255 "\xea\x1e\x0a\x9f\x33\x25\x00\xa5"
4256 "\xdf\x94\x87\xd0\x7a\x5c\x92\xcc"
4257 "\x51\x2c\x88\x66\xc7\xe8\x60\xce"
4258 "\x93\xfd\xf1\x66\xa2\x49\x12\xb4"
4259 "\x22\x97\x61\x46\xae\x20\xce\x84"
4260 "\x6b\xb7\xdc\x9b\xa9\x4a\x76\x7a"
4261 "\xae\xf2\x0c\x0d\x61\xad\x02\x65"
4262 "\x5e\xa9\x2d\xc4\xc4\xe4\x1a\x89"
4263 "\x52\xc6\x51\xd3\x31\x74\xbe\x51"
4264 "\xa1\x0c\x42\x11\x10\xe6\xd8\x15"
4265 "\x88\xed\xe8\x21\x03\xa2\x52\xd8"
4266 "\xa7\x50\xe8\x76\x8d\xef\xff\xed"
4267 "\x91\x22\x81\x0a\xae\xb9\x9f\x91"
4268 "\x72\xaf\x82\xb6\x04\xdc\x4b\x8e"
4269 "\x51\xbc\xb0\x82\x35\xa6\xf4\x34"
4270 "\x13\x32\xe4\xca\x60\x48\x2a\x4b"
4271 "\xa1\xa0\x3b\x3e\x65\x00\x8f\xc5"
4272 "\xda\x76\xb7\x0b\xf1\x69\x0d\xb4"
4273 "\xea\xe2\x9c\x5f\x1b\xad\xd0\x3c"
4274 "\x5c\xcf\x2a\x55\xd7\x05\xdd\xcd"
4275 "\x86\xd4\x49\x51\x1c\xeb\x7e\xc3"
4276 "\x0b\xf1\x2b\x1f\xa3\x5b\x91\x3f"
4277 "\x9f\x74\x7a\x8a\xfd\x1b\x13\x0e"
4278 "\x94\xbf\xf9\x4e\xff\xd0\x1a\x91"
4279 "\x73\x5c\xa1\x72\x6a\xcd\x0b\x19"
4280 "\x7c\x4e\x5b\x03\x39\x36\x97\xe1"
4281 "\x26\x82\x6f\xb6\xbb\xde\x8e\xcc"
4282 "\x1e\x08\x29\x85\x16\xe2\xc9\xed"
4283 "\x03\xff\x3c\x1b\x78\x60\xf6\xde"
4284 "\x76\xd4\xce\xcd\x94\xc8\x11\x98"
4285 "\x55\xef\x52\x97\xca\x67\xe9\xf3"
4286 "\xe7\xff\x72\xb1\xe9\x97\x85\xca"
4287 "\x0a\x7e\x77\x20\xc5\xb3\x6d\xc6"
4288 "\xd7\x2c\xac\x95\x74\xc8\xcb\xbc"
4289 "\x2f\x80\x1e\x23\xe5\x6f\xd3\x44"
4290 "\xb0\x7f\x22\x15\x4b\xeb\xa0\xf0"
4291 "\x8c\xe8\x89\x1e\x64\x3e\xd9\x95"
4292 "\xc9\x4d\x9a\x69\xc9\xf1\xb5\xf4"
4293 "\x99\x02\x7a\x78\x57\x2a\xee\xbd"
4294 "\x74\xd2\x0c\xc3\x98\x81\xc2\x13"
4295 "\xee\x77\x0b\x10\x10\xe4\xbe\xa7"
4296 "\x18\x84\x69\x77\xae\x11\x9f\x7a"
4297 "\x02\x3a\xb5\x8c\xca\x0a\xd7\x52"
4298 "\xaf\xe6\x56\xbb\x3c\x17\x25\x6a"
4299 "\x9f\x6e\x9b\xf1\x9f\xdd\x5a\x38"
4300 "\xfc\x82\xbb\xe8\x72\xc5\x53\x9e"
4301 "\xdb\x60\x9e\xf4\xf7\x9c\x20\x3e"
4302 "\xbb\x14\x0f\x2e\x58\x3c\xb2\xad"
4303 "\x15\xb4\xaa\x5b\x65\x50\x16\xa8"
4304 "\x44\x92\x77\xdb\xd4\x77\xef\x2c"
4305 "\x8d\x6c\x01\x7d\xb7\x38\xb1\x8d"
4306 "\xeb\x4a\x42\x7d\x19\x23\xce\x3f"
4307 "\xf2\x62\x73\x57\x79\xa4\x18\xf2"
4308 "\x0a\x28\x2d\xf9\x20\x14\x7b\xea"
4309 "\xbe\x42\x1e\xe5\x31\x9d\x05\x68",
4310 .rlen = 512,
4311 }, {
4312 .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
4313 "\x23\x53\x60\x28\x74\x71\x35\x26"
4314 "\x62\x49\x77\x57\x24\x70\x93\x69"
4315 "\x99\x59\x57\x49\x66\x96\x76\x27"
4316 "\x31\x41\x59\x26\x53\x58\x97\x93"
4317 "\x23\x84\x62\x64\x33\x83\x27\x95"
4318 "\x02\x88\x41\x97\x16\x93\x99\x37"
4319 "\x51\x05\x82\x09\x74\x94\x45\x92",
4320 .klen = 64,
4321 .iv = "\xff\x00\x00\x00\x00\x00\x00\x00"
4322 "\x00\x00\x00\x00\x00\x00\x00\x00",
4323 "\x00\x00\x00\x00\x00\x00\x00\x00",
4324 "\x00\x00\x00\x00\x00\x00\x00\x00",
4325 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
4326 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4327 "\x10\x11\x12\x13\x14\x15\x16\x17"
4328 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
4329 "\x20\x21\x22\x23\x24\x25\x26\x27"
4330 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
4331 "\x30\x31\x32\x33\x34\x35\x36\x37"
4332 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
4333 "\x40\x41\x42\x43\x44\x45\x46\x47"
4334 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
4335 "\x50\x51\x52\x53\x54\x55\x56\x57"
4336 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
4337 "\x60\x61\x62\x63\x64\x65\x66\x67"
4338 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
4339 "\x70\x71\x72\x73\x74\x75\x76\x77"
4340 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
4341 "\x80\x81\x82\x83\x84\x85\x86\x87"
4342 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
4343 "\x90\x91\x92\x93\x94\x95\x96\x97"
4344 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
4345 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
4346 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
4347 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
4348 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
4349 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
4350 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
4351 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
4352 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
4353 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
4354 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
4355 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4356 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
4357 "\x00\x01\x02\x03\x04\x05\x06\x07"
4358 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4359 "\x10\x11\x12\x13\x14\x15\x16\x17"
4360 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
4361 "\x20\x21\x22\x23\x24\x25\x26\x27"
4362 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
4363 "\x30\x31\x32\x33\x34\x35\x36\x37"
4364 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
4365 "\x40\x41\x42\x43\x44\x45\x46\x47"
4366 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
4367 "\x50\x51\x52\x53\x54\x55\x56\x57"
4368 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
4369 "\x60\x61\x62\x63\x64\x65\x66\x67"
4370 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
4371 "\x70\x71\x72\x73\x74\x75\x76\x77"
4372 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
4373 "\x80\x81\x82\x83\x84\x85\x86\x87"
4374 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
4375 "\x90\x91\x92\x93\x94\x95\x96\x97"
4376 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
4377 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
4378 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
4379 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
4380 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
4381 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
4382 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
4383 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
4384 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
4385 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
4386 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
4387 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4388 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4389 .ilen = 512,
4390 .result = "\x1c\x3b\x3a\x10\x2f\x77\x03\x86"
4391 "\xe4\x83\x6c\x99\xe3\x70\xcf\x9b"
4392 "\xea\x00\x80\x3f\x5e\x48\x23\x57"
4393 "\xa4\xae\x12\xd4\x14\xa3\xe6\x3b"
4394 "\x5d\x31\xe2\x76\xf8\xfe\x4a\x8d"
4395 "\x66\xb3\x17\xf9\xac\x68\x3f\x44"
4396 "\x68\x0a\x86\xac\x35\xad\xfc\x33"
4397 "\x45\xbe\xfe\xcb\x4b\xb1\x88\xfd"
4398 "\x57\x76\x92\x6c\x49\xa3\x09\x5e"
4399 "\xb1\x08\xfd\x10\x98\xba\xec\x70"
4400 "\xaa\xa6\x69\x99\xa7\x2a\x82\xf2"
4401 "\x7d\x84\x8b\x21\xd4\xa7\x41\xb0"
4402 "\xc5\xcd\x4d\x5f\xff\x9d\xac\x89"
4403 "\xae\xba\x12\x29\x61\xd0\x3a\x75"
4404 "\x71\x23\xe9\x87\x0f\x8a\xcf\x10"
4405 "\x00\x02\x08\x87\x89\x14\x29\xca"
4406 "\x2a\x3e\x7a\x7d\x7d\xf7\xb1\x03"
4407 "\x55\x16\x5c\x8b\x9a\x6d\x0a\x7d"
4408 "\xe8\xb0\x62\xc4\x50\x0d\xc4\xcd"
4409 "\x12\x0c\x0f\x74\x18\xda\xe3\xd0"
4410 "\xb5\x78\x1c\x34\x80\x3f\xa7\x54"
4411 "\x21\xc7\x90\xdf\xe1\xde\x18\x34"
4412 "\xf2\x80\xd7\x66\x7b\x32\x7f\x6c"
4413 "\x8c\xd7\x55\x7e\x12\xac\x3a\x0f"
4414 "\x93\xec\x05\xc5\x2e\x04\x93\xef"
4415 "\x31\xa1\x2d\x3d\x92\x60\xf7\x9a"
4416 "\x28\x9d\x6a\x37\x9b\xc7\x0c\x50"
4417 "\x84\x14\x73\xd1\xa8\xcc\x81\xec"
4418 "\x58\x3e\x96\x45\xe0\x7b\x8d\x96"
4419 "\x70\x65\x5b\xa5\xbb\xcf\xec\xc6"
4420 "\xdc\x39\x66\x38\x0a\xd8\xfe\xcb"
4421 "\x17\xb6\xba\x02\x46\x9a\x02\x0a"
4422 "\x84\xe1\x8e\x8f\x84\x25\x20\x70"
4423 "\xc1\x3e\x9f\x1f\x28\x9b\xe5\x4f"
4424 "\xbc\x48\x14\x57\x77\x8f\x61\x60"
4425 "\x15\xe1\x32\x7a\x02\xb1\x40\xf1"
4426 "\x50\x5e\xb3\x09\x32\x6d\x68\x37"
4427 "\x8f\x83\x74\x59\x5c\x84\x9d\x84"
4428 "\xf4\xc3\x33\xec\x44\x23\x88\x51"
4429 "\x43\xcb\x47\xbd\x71\xc5\xed\xae"
4430 "\x9b\xe6\x9a\x2f\xfe\xce\xb1\xbe"
4431 "\xc9\xde\x24\x4f\xbe\x15\x99\x2b"
4432 "\x11\xb7\x7c\x04\x0f\x12\xbd\x8f"
4433 "\x6a\x97\x5a\x44\xa0\xf9\x0c\x29"
4434 "\xa9\xab\xc3\xd4\xd8\x93\x92\x72"
4435 "\x84\xc5\x87\x54\xcc\xe2\x94\x52"
4436 "\x9f\x86\x14\xdc\xd2\xab\xa9\x91"
4437 "\x92\x5f\xed\xc4\xae\x74\xff\xac"
4438 "\x6e\x33\x3b\x93\xeb\x4a\xff\x04"
4439 "\x79\xda\x9a\x41\x0e\x44\x50\xe0"
4440 "\xdd\x7a\xe4\xc6\xe2\x91\x09\x00"
4441 "\x57\x5d\xa4\x01\xfc\x07\x05\x9f"
4442 "\x64\x5e\x8b\x7e\x9b\xfd\xef\x33"
4443 "\x94\x30\x54\xff\x84\x01\x14\x93"
4444 "\xc2\x7b\x34\x29\xea\xed\xb4\xed"
4445 "\x53\x76\x44\x1a\x77\xed\x43\x85"
4446 "\x1a\xd7\x7f\x16\xf5\x41\xdf\xd2"
4447 "\x69\xd5\x0d\x6a\x5f\x14\xfb\x0a"
4448 "\xab\x1c\xbb\x4c\x15\x50\xbe\x97"
4449 "\xf7\xab\x40\x66\x19\x3c\x4c\xaa"
4450 "\x77\x3d\xad\x38\x01\x4b\xd2\x09"
4451 "\x2f\xa7\x55\xc8\x24\xbb\x5e\x54"
4452 "\xc4\xf3\x6f\xfd\xa9\xfc\xea\x70"
4453 "\xb9\xc6\xe6\x93\xe1\x48\xc1\x51",
4454 .rlen = 512,
4455 }
4456};
4457
4458static struct cipher_testvec aes_xts_dec_tv_template[] = {
4459
4460 {
4461 .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
4462 "\x00\x00\x00\x00\x00\x00\x00\x00"
4463 "\x00\x00\x00\x00\x00\x00\x00\x00"
4464 "\x00\x00\x00\x00\x00\x00\x00\x00",
4465 .klen = 32,
4466 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
4467 "\x00\x00\x00\x00\x00\x00\x00\x00",
4468 .input = "\x91\x7c\xf6\x9e\xbd\x68\xb2\xec"
4469 "\x9b\x9f\xe9\xa3\xea\xdd\xa6\x92"
4470 "\xcd\x43\xd2\xf5\x95\x98\xed\x85"
4471 "\x8c\x02\xc2\x65\x2f\xbf\x92\x2e",
4472 .ilen = 32,
4473 .result = "\x00\x00\x00\x00\x00\x00\x00\x00"
4474 "\x00\x00\x00\x00\x00\x00\x00\x00"
4475 "\x00\x00\x00\x00\x00\x00\x00\x00"
4476 "\x00\x00\x00\x00\x00\x00\x00\x00",
4477 .rlen = 32,
4478 }, {
4479 .key = "\x11\x11\x11\x11\x11\x11\x11\x11"
4480 "\x11\x11\x11\x11\x11\x11\x11\x11"
4481 "\x22\x22\x22\x22\x22\x22\x22\x22"
4482 "\x22\x22\x22\x22\x22\x22\x22\x22",
4483 .klen = 32,
4484 .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
4485 "\x00\x00\x00\x00\x00\x00\x00\x00",
4486 .input = "\xc4\x54\x18\x5e\x6a\x16\x93\x6e"
4487 "\x39\x33\x40\x38\xac\xef\x83\x8b"
4488 "\xfb\x18\x6f\xff\x74\x80\xad\xc4"
4489 "\x28\x93\x82\xec\xd6\xd3\x94\xf0",
4490 .ilen = 32,
4491 .result = "\x44\x44\x44\x44\x44\x44\x44\x44"
4492 "\x44\x44\x44\x44\x44\x44\x44\x44"
4493 "\x44\x44\x44\x44\x44\x44\x44\x44"
4494 "\x44\x44\x44\x44\x44\x44\x44\x44",
4495 .rlen = 32,
4496 }, {
4497 .key = "\xff\xfe\xfd\xfc\xfb\xfa\xf9\xf8"
4498 "\xf7\xf6\xf5\xf4\xf3\xf2\xf1\xf0"
4499 "\x22\x22\x22\x22\x22\x22\x22\x22"
4500 "\x22\x22\x22\x22\x22\x22\x22\x22",
4501 .klen = 32,
4502 .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
4503 "\x00\x00\x00\x00\x00\x00\x00\x00",
4504 .input = "\xaf\x85\x33\x6b\x59\x7a\xfc\x1a"
4505 "\x90\x0b\x2e\xb2\x1e\xc9\x49\xd2"
4506 "\x92\xdf\x4c\x04\x7e\x0b\x21\x53"
4507 "\x21\x86\xa5\x97\x1a\x22\x7a\x89",
4508 .ilen = 32,
4509 .result = "\x44\x44\x44\x44\x44\x44\x44\x44"
4510 "\x44\x44\x44\x44\x44\x44\x44\x44"
4511 "\x44\x44\x44\x44\x44\x44\x44\x44"
4512 "\x44\x44\x44\x44\x44\x44\x44\x44",
4513 .rlen = 32,
4514 }, {
4515 .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
4516 "\x23\x53\x60\x28\x74\x71\x35\x26"
4517 "\x31\x41\x59\x26\x53\x58\x97\x93"
4518 "\x23\x84\x62\x64\x33\x83\x27\x95",
4519 .klen = 32,
4520 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
4521 "\x00\x00\x00\x00\x00\x00\x00\x00",
4522 .input = "\x27\xa7\x47\x9b\xef\xa1\xd4\x76"
4523 "\x48\x9f\x30\x8c\xd4\xcf\xa6\xe2"
4524 "\xa9\x6e\x4b\xbe\x32\x08\xff\x25"
4525 "\x28\x7d\xd3\x81\x96\x16\xe8\x9c"
4526 "\xc7\x8c\xf7\xf5\xe5\x43\x44\x5f"
4527 "\x83\x33\xd8\xfa\x7f\x56\x00\x00"
4528 "\x05\x27\x9f\xa5\xd8\xb5\xe4\xad"
4529 "\x40\xe7\x36\xdd\xb4\xd3\x54\x12"
4530 "\x32\x80\x63\xfd\x2a\xab\x53\xe5"
4531 "\xea\x1e\x0a\x9f\x33\x25\x00\xa5"
4532 "\xdf\x94\x87\xd0\x7a\x5c\x92\xcc"
4533 "\x51\x2c\x88\x66\xc7\xe8\x60\xce"
4534 "\x93\xfd\xf1\x66\xa2\x49\x12\xb4"
4535 "\x22\x97\x61\x46\xae\x20\xce\x84"
4536 "\x6b\xb7\xdc\x9b\xa9\x4a\x76\x7a"
4537 "\xae\xf2\x0c\x0d\x61\xad\x02\x65"
4538 "\x5e\xa9\x2d\xc4\xc4\xe4\x1a\x89"
4539 "\x52\xc6\x51\xd3\x31\x74\xbe\x51"
4540 "\xa1\x0c\x42\x11\x10\xe6\xd8\x15"
4541 "\x88\xed\xe8\x21\x03\xa2\x52\xd8"
4542 "\xa7\x50\xe8\x76\x8d\xef\xff\xed"
4543 "\x91\x22\x81\x0a\xae\xb9\x9f\x91"
4544 "\x72\xaf\x82\xb6\x04\xdc\x4b\x8e"
4545 "\x51\xbc\xb0\x82\x35\xa6\xf4\x34"
4546 "\x13\x32\xe4\xca\x60\x48\x2a\x4b"
4547 "\xa1\xa0\x3b\x3e\x65\x00\x8f\xc5"
4548 "\xda\x76\xb7\x0b\xf1\x69\x0d\xb4"
4549 "\xea\xe2\x9c\x5f\x1b\xad\xd0\x3c"
4550 "\x5c\xcf\x2a\x55\xd7\x05\xdd\xcd"
4551 "\x86\xd4\x49\x51\x1c\xeb\x7e\xc3"
4552 "\x0b\xf1\x2b\x1f\xa3\x5b\x91\x3f"
4553 "\x9f\x74\x7a\x8a\xfd\x1b\x13\x0e"
4554 "\x94\xbf\xf9\x4e\xff\xd0\x1a\x91"
4555 "\x73\x5c\xa1\x72\x6a\xcd\x0b\x19"
4556 "\x7c\x4e\x5b\x03\x39\x36\x97\xe1"
4557 "\x26\x82\x6f\xb6\xbb\xde\x8e\xcc"
4558 "\x1e\x08\x29\x85\x16\xe2\xc9\xed"
4559 "\x03\xff\x3c\x1b\x78\x60\xf6\xde"
4560 "\x76\xd4\xce\xcd\x94\xc8\x11\x98"
4561 "\x55\xef\x52\x97\xca\x67\xe9\xf3"
4562 "\xe7\xff\x72\xb1\xe9\x97\x85\xca"
4563 "\x0a\x7e\x77\x20\xc5\xb3\x6d\xc6"
4564 "\xd7\x2c\xac\x95\x74\xc8\xcb\xbc"
4565 "\x2f\x80\x1e\x23\xe5\x6f\xd3\x44"
4566 "\xb0\x7f\x22\x15\x4b\xeb\xa0\xf0"
4567 "\x8c\xe8\x89\x1e\x64\x3e\xd9\x95"
4568 "\xc9\x4d\x9a\x69\xc9\xf1\xb5\xf4"
4569 "\x99\x02\x7a\x78\x57\x2a\xee\xbd"
4570 "\x74\xd2\x0c\xc3\x98\x81\xc2\x13"
4571 "\xee\x77\x0b\x10\x10\xe4\xbe\xa7"
4572 "\x18\x84\x69\x77\xae\x11\x9f\x7a"
4573 "\x02\x3a\xb5\x8c\xca\x0a\xd7\x52"
4574 "\xaf\xe6\x56\xbb\x3c\x17\x25\x6a"
4575 "\x9f\x6e\x9b\xf1\x9f\xdd\x5a\x38"
4576 "\xfc\x82\xbb\xe8\x72\xc5\x53\x9e"
4577 "\xdb\x60\x9e\xf4\xf7\x9c\x20\x3e"
4578 "\xbb\x14\x0f\x2e\x58\x3c\xb2\xad"
4579 "\x15\xb4\xaa\x5b\x65\x50\x16\xa8"
4580 "\x44\x92\x77\xdb\xd4\x77\xef\x2c"
4581 "\x8d\x6c\x01\x7d\xb7\x38\xb1\x8d"
4582 "\xeb\x4a\x42\x7d\x19\x23\xce\x3f"
4583 "\xf2\x62\x73\x57\x79\xa4\x18\xf2"
4584 "\x0a\x28\x2d\xf9\x20\x14\x7b\xea"
4585 "\xbe\x42\x1e\xe5\x31\x9d\x05\x68",
4586 .ilen = 512,
4587 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
4588 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4589 "\x10\x11\x12\x13\x14\x15\x16\x17"
4590 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
4591 "\x20\x21\x22\x23\x24\x25\x26\x27"
4592 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
4593 "\x30\x31\x32\x33\x34\x35\x36\x37"
4594 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
4595 "\x40\x41\x42\x43\x44\x45\x46\x47"
4596 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
4597 "\x50\x51\x52\x53\x54\x55\x56\x57"
4598 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
4599 "\x60\x61\x62\x63\x64\x65\x66\x67"
4600 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
4601 "\x70\x71\x72\x73\x74\x75\x76\x77"
4602 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
4603 "\x80\x81\x82\x83\x84\x85\x86\x87"
4604 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
4605 "\x90\x91\x92\x93\x94\x95\x96\x97"
4606 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
4607 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
4608 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
4609 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
4610 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
4611 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
4612 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
4613 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
4614 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
4615 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
4616 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
4617 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4618 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
4619 "\x00\x01\x02\x03\x04\x05\x06\x07"
4620 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4621 "\x10\x11\x12\x13\x14\x15\x16\x17"
4622 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
4623 "\x20\x21\x22\x23\x24\x25\x26\x27"
4624 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
4625 "\x30\x31\x32\x33\x34\x35\x36\x37"
4626 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
4627 "\x40\x41\x42\x43\x44\x45\x46\x47"
4628 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
4629 "\x50\x51\x52\x53\x54\x55\x56\x57"
4630 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
4631 "\x60\x61\x62\x63\x64\x65\x66\x67"
4632 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
4633 "\x70\x71\x72\x73\x74\x75\x76\x77"
4634 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
4635 "\x80\x81\x82\x83\x84\x85\x86\x87"
4636 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
4637 "\x90\x91\x92\x93\x94\x95\x96\x97"
4638 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
4639 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
4640 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
4641 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
4642 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
4643 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
4644 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
4645 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
4646 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
4647 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
4648 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
4649 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4650 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4651 .rlen = 512,
4652 }, {
4653 .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
4654 "\x23\x53\x60\x28\x74\x71\x35\x26"
4655 "\x62\x49\x77\x57\x24\x70\x93\x69"
4656 "\x99\x59\x57\x49\x66\x96\x76\x27"
4657 "\x31\x41\x59\x26\x53\x58\x97\x93"
4658 "\x23\x84\x62\x64\x33\x83\x27\x95"
4659 "\x02\x88\x41\x97\x16\x93\x99\x37"
4660 "\x51\x05\x82\x09\x74\x94\x45\x92",
4661 .klen = 64,
4662 .iv = "\xff\x00\x00\x00\x00\x00\x00\x00"
4663 "\x00\x00\x00\x00\x00\x00\x00\x00",
4664 "\x00\x00\x00\x00\x00\x00\x00\x00",
4665 "\x00\x00\x00\x00\x00\x00\x00\x00",
4666 .input = "\x1c\x3b\x3a\x10\x2f\x77\x03\x86"
4667 "\xe4\x83\x6c\x99\xe3\x70\xcf\x9b"
4668 "\xea\x00\x80\x3f\x5e\x48\x23\x57"
4669 "\xa4\xae\x12\xd4\x14\xa3\xe6\x3b"
4670 "\x5d\x31\xe2\x76\xf8\xfe\x4a\x8d"
4671 "\x66\xb3\x17\xf9\xac\x68\x3f\x44"
4672 "\x68\x0a\x86\xac\x35\xad\xfc\x33"
4673 "\x45\xbe\xfe\xcb\x4b\xb1\x88\xfd"
4674 "\x57\x76\x92\x6c\x49\xa3\x09\x5e"
4675 "\xb1\x08\xfd\x10\x98\xba\xec\x70"
4676 "\xaa\xa6\x69\x99\xa7\x2a\x82\xf2"
4677 "\x7d\x84\x8b\x21\xd4\xa7\x41\xb0"
4678 "\xc5\xcd\x4d\x5f\xff\x9d\xac\x89"
4679 "\xae\xba\x12\x29\x61\xd0\x3a\x75"
4680 "\x71\x23\xe9\x87\x0f\x8a\xcf\x10"
4681 "\x00\x02\x08\x87\x89\x14\x29\xca"
4682 "\x2a\x3e\x7a\x7d\x7d\xf7\xb1\x03"
4683 "\x55\x16\x5c\x8b\x9a\x6d\x0a\x7d"
4684 "\xe8\xb0\x62\xc4\x50\x0d\xc4\xcd"
4685 "\x12\x0c\x0f\x74\x18\xda\xe3\xd0"
4686 "\xb5\x78\x1c\x34\x80\x3f\xa7\x54"
4687 "\x21\xc7\x90\xdf\xe1\xde\x18\x34"
4688 "\xf2\x80\xd7\x66\x7b\x32\x7f\x6c"
4689 "\x8c\xd7\x55\x7e\x12\xac\x3a\x0f"
4690 "\x93\xec\x05\xc5\x2e\x04\x93\xef"
4691 "\x31\xa1\x2d\x3d\x92\x60\xf7\x9a"
4692 "\x28\x9d\x6a\x37\x9b\xc7\x0c\x50"
4693 "\x84\x14\x73\xd1\xa8\xcc\x81\xec"
4694 "\x58\x3e\x96\x45\xe0\x7b\x8d\x96"
4695 "\x70\x65\x5b\xa5\xbb\xcf\xec\xc6"
4696 "\xdc\x39\x66\x38\x0a\xd8\xfe\xcb"
4697 "\x17\xb6\xba\x02\x46\x9a\x02\x0a"
4698 "\x84\xe1\x8e\x8f\x84\x25\x20\x70"
4699 "\xc1\x3e\x9f\x1f\x28\x9b\xe5\x4f"
4700 "\xbc\x48\x14\x57\x77\x8f\x61\x60"
4701 "\x15\xe1\x32\x7a\x02\xb1\x40\xf1"
4702 "\x50\x5e\xb3\x09\x32\x6d\x68\x37"
4703 "\x8f\x83\x74\x59\x5c\x84\x9d\x84"
4704 "\xf4\xc3\x33\xec\x44\x23\x88\x51"
4705 "\x43\xcb\x47\xbd\x71\xc5\xed\xae"
4706 "\x9b\xe6\x9a\x2f\xfe\xce\xb1\xbe"
4707 "\xc9\xde\x24\x4f\xbe\x15\x99\x2b"
4708 "\x11\xb7\x7c\x04\x0f\x12\xbd\x8f"
4709 "\x6a\x97\x5a\x44\xa0\xf9\x0c\x29"
4710 "\xa9\xab\xc3\xd4\xd8\x93\x92\x72"
4711 "\x84\xc5\x87\x54\xcc\xe2\x94\x52"
4712 "\x9f\x86\x14\xdc\xd2\xab\xa9\x91"
4713 "\x92\x5f\xed\xc4\xae\x74\xff\xac"
4714 "\x6e\x33\x3b\x93\xeb\x4a\xff\x04"
4715 "\x79\xda\x9a\x41\x0e\x44\x50\xe0"
4716 "\xdd\x7a\xe4\xc6\xe2\x91\x09\x00"
4717 "\x57\x5d\xa4\x01\xfc\x07\x05\x9f"
4718 "\x64\x5e\x8b\x7e\x9b\xfd\xef\x33"
4719 "\x94\x30\x54\xff\x84\x01\x14\x93"
4720 "\xc2\x7b\x34\x29\xea\xed\xb4\xed"
4721 "\x53\x76\x44\x1a\x77\xed\x43\x85"
4722 "\x1a\xd7\x7f\x16\xf5\x41\xdf\xd2"
4723 "\x69\xd5\x0d\x6a\x5f\x14\xfb\x0a"
4724 "\xab\x1c\xbb\x4c\x15\x50\xbe\x97"
4725 "\xf7\xab\x40\x66\x19\x3c\x4c\xaa"
4726 "\x77\x3d\xad\x38\x01\x4b\xd2\x09"
4727 "\x2f\xa7\x55\xc8\x24\xbb\x5e\x54"
4728 "\xc4\xf3\x6f\xfd\xa9\xfc\xea\x70"
4729 "\xb9\xc6\xe6\x93\xe1\x48\xc1\x51",
4730 .ilen = 512,
4731 .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
4732 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4733 "\x10\x11\x12\x13\x14\x15\x16\x17"
4734 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
4735 "\x20\x21\x22\x23\x24\x25\x26\x27"
4736 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
4737 "\x30\x31\x32\x33\x34\x35\x36\x37"
4738 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
4739 "\x40\x41\x42\x43\x44\x45\x46\x47"
4740 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
4741 "\x50\x51\x52\x53\x54\x55\x56\x57"
4742 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
4743 "\x60\x61\x62\x63\x64\x65\x66\x67"
4744 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
4745 "\x70\x71\x72\x73\x74\x75\x76\x77"
4746 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
4747 "\x80\x81\x82\x83\x84\x85\x86\x87"
4748 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
4749 "\x90\x91\x92\x93\x94\x95\x96\x97"
4750 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
4751 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
4752 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
4753 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
4754 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
4755 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
4756 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
4757 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
4758 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
4759 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
4760 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
4761 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4762 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
4763 "\x00\x01\x02\x03\x04\x05\x06\x07"
4764 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4765 "\x10\x11\x12\x13\x14\x15\x16\x17"
4766 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
4767 "\x20\x21\x22\x23\x24\x25\x26\x27"
4768 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
4769 "\x30\x31\x32\x33\x34\x35\x36\x37"
4770 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
4771 "\x40\x41\x42\x43\x44\x45\x46\x47"
4772 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
4773 "\x50\x51\x52\x53\x54\x55\x56\x57"
4774 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
4775 "\x60\x61\x62\x63\x64\x65\x66\x67"
4776 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
4777 "\x70\x71\x72\x73\x74\x75\x76\x77"
4778 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
4779 "\x80\x81\x82\x83\x84\x85\x86\x87"
4780 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
4781 "\x90\x91\x92\x93\x94\x95\x96\x97"
4782 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
4783 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
4784 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
4785 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
4786 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
4787 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
4788 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
4789 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
4790 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
4791 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
4792 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
4793 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4794 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4795 .rlen = 512,
4796
4797 }
4798};
4799
4800
4801static struct cipher_testvec aes_ctr_enc_tv_template[] = {
4802 {
4803 .key = "\x2b\x7e\x15\x16\x28\xae\xd2\xa6"
4804 "\xab\xf7\x15\x88\x09\xcf\x4f\x3c",
4805 .klen = 16,
4806 .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4807 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4808 .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
4809 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
4810 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
4811 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
4812 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
4813 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
4814 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
4815 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
4816 .ilen = 64,
4817 .result = "\x87\x4d\x61\x91\xb6\x20\xe3\x26"
4818 "\x1b\xef\x68\x64\x99\x0d\xb6\xce"
4819 "\x98\x06\xf6\x6b\x79\x70\xfd\xff"
4820 "\x86\x17\x18\x7b\xb9\xff\xfd\xff"
4821 "\x5a\xe4\xdf\x3e\xdb\xd5\xd3\x5e"
4822 "\x5b\x4f\x09\x02\x0d\xb0\x3e\xab"
4823 "\x1e\x03\x1d\xda\x2f\xbe\x03\xd1"
4824 "\x79\x21\x70\xa0\xf3\x00\x9c\xee",
4825 .rlen = 64,
4826 }, {
4827 .key = "\x8e\x73\xb0\xf7\xda\x0e\x64\x52"
4828 "\xc8\x10\xf3\x2b\x80\x90\x79\xe5"
4829 "\x62\xf8\xea\xd2\x52\x2c\x6b\x7b",
4830 .klen = 24,
4831 .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4832 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4833 .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
4834 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
4835 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
4836 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
4837 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
4838 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
4839 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
4840 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
4841 .ilen = 64,
4842 .result = "\x1a\xbc\x93\x24\x17\x52\x1c\xa2"
4843 "\x4f\x2b\x04\x59\xfe\x7e\x6e\x0b"
4844 "\x09\x03\x39\xec\x0a\xa6\xfa\xef"
4845 "\xd5\xcc\xc2\xc6\xf4\xce\x8e\x94"
4846 "\x1e\x36\xb2\x6b\xd1\xeb\xc6\x70"
4847 "\xd1\xbd\x1d\x66\x56\x20\xab\xf7"
4848 "\x4f\x78\xa7\xf6\xd2\x98\x09\x58"
4849 "\x5a\x97\xda\xec\x58\xc6\xb0\x50",
4850 .rlen = 64,
4851 }, {
4852 .key = "\x60\x3d\xeb\x10\x15\xca\x71\xbe"
4853 "\x2b\x73\xae\xf0\x85\x7d\x77\x81"
4854 "\x1f\x35\x2c\x07\x3b\x61\x08\xd7"
4855 "\x2d\x98\x10\xa3\x09\x14\xdf\xf4",
4856 .klen = 32,
4857 .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4858 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4859 .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
4860 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
4861 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
4862 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
4863 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
4864 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
4865 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
4866 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
4867 .ilen = 64,
4868 .result = "\x60\x1e\xc3\x13\x77\x57\x89\xa5"
4869 "\xb7\xa7\xf5\x04\xbb\xf3\xd2\x28"
4870 "\xf4\x43\xe3\xca\x4d\x62\xb5\x9a"
4871 "\xca\x84\xe9\x90\xca\xca\xf5\xc5"
4872 "\x2b\x09\x30\xda\xa2\x3d\xe9\x4c"
4873 "\xe8\x70\x17\xba\x2d\x84\x98\x8d"
4874 "\xdf\xc9\xc5\x8d\xb6\x7a\xad\xa6"
4875 "\x13\xc2\xdd\x08\x45\x79\x41\xa6",
4876 .rlen = 64,
4877 }
4878};
4879
4880static struct cipher_testvec aes_ctr_dec_tv_template[] = {
4881 {
4882 .key = "\x2b\x7e\x15\x16\x28\xae\xd2\xa6"
4883 "\xab\xf7\x15\x88\x09\xcf\x4f\x3c",
4884 .klen = 16,
4885 .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4886 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4887 .input = "\x87\x4d\x61\x91\xb6\x20\xe3\x26"
4888 "\x1b\xef\x68\x64\x99\x0d\xb6\xce"
4889 "\x98\x06\xf6\x6b\x79\x70\xfd\xff"
4890 "\x86\x17\x18\x7b\xb9\xff\xfd\xff"
4891 "\x5a\xe4\xdf\x3e\xdb\xd5\xd3\x5e"
4892 "\x5b\x4f\x09\x02\x0d\xb0\x3e\xab"
4893 "\x1e\x03\x1d\xda\x2f\xbe\x03\xd1"
4894 "\x79\x21\x70\xa0\xf3\x00\x9c\xee",
4895 .ilen = 64,
4896 .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
4897 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
4898 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
4899 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
4900 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
4901 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
4902 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
4903 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
4904 .rlen = 64,
4905 }, {
4906 .key = "\x8e\x73\xb0\xf7\xda\x0e\x64\x52"
4907 "\xc8\x10\xf3\x2b\x80\x90\x79\xe5"
4908 "\x62\xf8\xea\xd2\x52\x2c\x6b\x7b",
4909 .klen = 24,
4910 .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4911 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4912 .input = "\x1a\xbc\x93\x24\x17\x52\x1c\xa2"
4913 "\x4f\x2b\x04\x59\xfe\x7e\x6e\x0b"
4914 "\x09\x03\x39\xec\x0a\xa6\xfa\xef"
4915 "\xd5\xcc\xc2\xc6\xf4\xce\x8e\x94"
4916 "\x1e\x36\xb2\x6b\xd1\xeb\xc6\x70"
4917 "\xd1\xbd\x1d\x66\x56\x20\xab\xf7"
4918 "\x4f\x78\xa7\xf6\xd2\x98\x09\x58"
4919 "\x5a\x97\xda\xec\x58\xc6\xb0\x50",
4920 .ilen = 64,
4921 .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
4922 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
4923 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
4924 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
4925 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
4926 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
4927 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
4928 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
4929 .rlen = 64,
4930 }, {
4931 .key = "\x60\x3d\xeb\x10\x15\xca\x71\xbe"
4932 "\x2b\x73\xae\xf0\x85\x7d\x77\x81"
4933 "\x1f\x35\x2c\x07\x3b\x61\x08\xd7"
4934 "\x2d\x98\x10\xa3\x09\x14\xdf\xf4",
4935 .klen = 32,
4936 .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
4937 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
4938 .input = "\x60\x1e\xc3\x13\x77\x57\x89\xa5"
4939 "\xb7\xa7\xf5\x04\xbb\xf3\xd2\x28"
4940 "\xf4\x43\xe3\xca\x4d\x62\xb5\x9a"
4941 "\xca\x84\xe9\x90\xca\xca\xf5\xc5"
4942 "\x2b\x09\x30\xda\xa2\x3d\xe9\x4c"
4943 "\xe8\x70\x17\xba\x2d\x84\x98\x8d"
4944 "\xdf\xc9\xc5\x8d\xb6\x7a\xad\xa6"
4945 "\x13\xc2\xdd\x08\x45\x79\x41\xa6",
4946 .ilen = 64,
4947 .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
4948 "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
4949 "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
4950 "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
4951 "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
4952 "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
4953 "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
4954 "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
4955 .rlen = 64,
4956 }
4957};
4958
4959static struct cipher_testvec aes_ctr_rfc3686_enc_tv_template[] = {
4960 {
4961 .key = "\xae\x68\x52\xf8\x12\x10\x67\xcc"
4962 "\x4b\xf7\xa5\x76\x55\x77\xf3\x9e"
4963 "\x00\x00\x00\x30",
4964 .klen = 20,
4965 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
4966 .input = "Single block msg",
4967 .ilen = 16,
4968 .result = "\xe4\x09\x5d\x4f\xb7\xa7\xb3\x79"
4969 "\x2d\x61\x75\xa3\x26\x13\x11\xb8",
4970 .rlen = 16,
4971 }, {
4972 .key = "\x7e\x24\x06\x78\x17\xfa\xe0\xd7"
4973 "\x43\xd6\xce\x1f\x32\x53\x91\x63"
4974 "\x00\x6c\xb6\xdb",
4975 .klen = 20,
4976 .iv = "\xc0\x54\x3b\x59\xda\x48\xd9\x0b",
4977 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
4978 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
4979 "\x10\x11\x12\x13\x14\x15\x16\x17"
4980 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
4981 .ilen = 32,
4982 .result = "\x51\x04\xa1\x06\x16\x8a\x72\xd9"
4983 "\x79\x0d\x41\xee\x8e\xda\xd3\x88"
4984 "\xeb\x2e\x1e\xfc\x46\xda\x57\xc8"
4985 "\xfc\xe6\x30\xdf\x91\x41\xbe\x28",
4986 .rlen = 32,
4987 }, {
4988 .key = "\x16\xaf\x5b\x14\x5f\xc9\xf5\x79"
4989 "\xc1\x75\xf9\x3e\x3b\xfb\x0e\xed"
4990 "\x86\x3d\x06\xcc\xfd\xb7\x85\x15"
4991 "\x00\x00\x00\x48",
4992 .klen = 28,
4993 .iv = "\x36\x73\x3c\x14\x7d\x6d\x93\xcb",
4994 .input = "Single block msg",
4995 .ilen = 16,
4996 .result = "\x4b\x55\x38\x4f\xe2\x59\xc9\xc8"
4997 "\x4e\x79\x35\xa0\x03\xcb\xe9\x28",
4998 .rlen = 16,
4999 }, {
5000 .key = "\x7c\x5c\xb2\x40\x1b\x3d\xc3\x3c"
5001 "\x19\xe7\x34\x08\x19\xe0\xf6\x9c"
5002 "\x67\x8c\x3d\xb8\xe6\xf6\xa9\x1a"
5003 "\x00\x96\xb0\x3b",
5004 .klen = 28,
5005 .iv = "\x02\x0c\x6e\xad\xc2\xcb\x50\x0d",
5006 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
5007 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
5008 "\x10\x11\x12\x13\x14\x15\x16\x17"
5009 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
5010 .ilen = 32,
5011 .result = "\x45\x32\x43\xfc\x60\x9b\x23\x32"
5012 "\x7e\xdf\xaa\xfa\x71\x31\xcd\x9f"
5013 "\x84\x90\x70\x1c\x5a\xd4\xa7\x9c"
5014 "\xfc\x1f\xe0\xff\x42\xf4\xfb\x00",
5015 .rlen = 32,
5016 }, {
5017 .key = "\x77\x6b\xef\xf2\x85\x1d\xb0\x6f"
5018 "\x4c\x8a\x05\x42\xc8\x69\x6f\x6c"
5019 "\x6a\x81\xaf\x1e\xec\x96\xb4\xd3"
5020 "\x7f\xc1\xd6\x89\xe6\xc1\xc1\x04"
5021 "\x00\x00\x00\x60",
5022 .klen = 36,
5023 .iv = "\xdb\x56\x72\xc9\x7a\xa8\xf0\xb2",
5024 .input = "Single block msg",
5025 .ilen = 16,
5026 .result = "\x14\x5a\xd0\x1d\xbf\x82\x4e\xc7"
5027 "\x56\x08\x63\xdc\x71\xe3\xe0\xc0",
5028 .rlen = 16,
5029 }, {
5030 .key = "\xf6\xd6\x6d\x6b\xd5\x2d\x59\xbb"
5031 "\x07\x96\x36\x58\x79\xef\xf8\x86"
5032 "\xc6\x6d\xd5\x1a\x5b\x6a\x99\x74"
5033 "\x4b\x50\x59\x0c\x87\xa2\x38\x84"
5034 "\x00\xfa\xac\x24",
5035 .klen = 36,
5036 .iv = "\xc1\x58\x5e\xf1\x5a\x43\xd8\x75",
5037 .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
5038 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
5039 "\x10\x11\x12\x13\x14\x15\x16\x17"
5040 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
5041 .ilen = 32,
5042 .result = "\xf0\x5e\x23\x1b\x38\x94\x61\x2c"
5043 "\x49\xee\x00\x0b\x80\x4e\xb2\xa9"
5044 "\xb8\x30\x6b\x50\x8f\x83\x9d\x6a"
5045 "\x55\x30\x83\x1d\x93\x44\xaf\x1c",
5046 .rlen = 32,
5047 }, {
5048
5049 .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
5050 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
5051 "\x10\x11\x12\x13\x14\x15\x16\x17"
5052 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
5053 "\x00\x00\x00\x00",
5054 .klen = 32 + 4,
5055 .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
5056 .input =
5057 "\x00\x01\x02\x03\x04\x05\x06\x07"
5058 "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
5059 "\x10\x11\x12\x13\x14\x15\x16\x17"
5060 "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
5061 "\x20\x21\x22\x23\x24\x25\x26\x27"
5062 "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
5063 "\x30\x31\x32\x33\x34\x35\x36\x37"
5064 "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
5065 "\x40\x41\x42\x43\x44\x45\x46\x47"
5066 "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
5067 "\x50\x51\x52\x53\x54\x55\x56\x57"
5068 "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
5069 "\x60\x61\x62\x63\x64\x65\x66\x67"
5070 "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
5071 "\x70\x71\x72\x73\x74\x75\x76\x77"
5072 "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
5073 "\x80\x81\x82\x83\x84\x85\x86\x87"
5074 "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
5075 "\x90\x91\x92\x93\x94\x95\x96\x97"
5076 "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
5077 "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
5078 "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
5079 "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
5080 "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
5081 "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
5082 "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
5083 "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
5084 "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
5085 "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
5086 "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
5087 "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
5088 "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
5089 "\x00\x03\x06\x09\x0c\x0f\x12\x15"
5090 "\x18\x1b\x1e\x21\x24\x27\x2a\x2d"
5091 "\x30\x33\x36\x39\x3c\x3f\x42\x45"
5092 "\x48\x4b\x4e\x51\x54\x57\x5a\x5d"
5093 "\x60\x63\x66\x69\x6c\x6f\x72\x75"
5094 "\x78\x7b\x7e\x81\x84\x87\x8a\x8d"
5095 "\x90\x93\x96\x99\x9c\x9f\xa2\xa5"
5096 "\xa8\xab\xae\xb1\xb4\xb7\xba\xbd"
5097 "\xc0\xc3\xc6\xc9\xcc\xcf\xd2\xd5"
5098 "\xd8\xdb\xde\xe1\xe4\xe7\xea\xed"
5099 "\xf0\xf3\xf6\xf9\xfc\xff\x02\x05"
5100 "\x08\x0b\x0e\x11\x14\x17\x1a\x1d"
5101 "\x20\x23\x26\x29\x2c\x2f\x32\x35"
5102 "\x38\x3b\x3e\x41\x44\x47\x4a\x4d"
5103 "\x50\x53\x56\x59\x5c\x5f\x62\x65"
5104 "\x68\x6b\x6e\x71\x74\x77\x7a\x7d"
5105 "\x80\x83\x86\x89\x8c\x8f\x92\x95"
5106 "\x98\x9b\x9e\xa1\xa4\xa7\xaa\xad"
5107 "\xb0\xb3\xb6\xb9\xbc\xbf\xc2\xc5"
5108 "\xc8\xcb\xce\xd1\xd4\xd7\xda\xdd"
5109 "\xe0\xe3\xe6\xe9\xec\xef\xf2\xf5"
5110 "\xf8\xfb\xfe\x01\x04\x07\x0a\x0d"
5111 "\x10\x13\x16\x19\x1c\x1f\x22\x25"
5112 "\x28\x2b\x2e\x31\x34\x37\x3a\x3d"
5113 "\x40\x43\x46\x49\x4c\x4f\x52\x55"
5114 "\x58\x5b\x5e\x61\x64\x67\x6a\x6d"
5115 "\x70\x73\x76\x79\x7c\x7f\x82\x85"
5116 "\x88\x8b\x8e\x91\x94\x97\x9a\x9d"
5117 "\xa0\xa3\xa6\xa9\xac\xaf\xb2\xb5"
5118 "\xb8\xbb\xbe\xc1\xc4\xc7\xca\xcd"
5119 "\xd0\xd3\xd6\xd9\xdc\xdf\xe2\xe5"
5120 "\xe8\xeb\xee\xf1\xf4\xf7\xfa\xfd"
5121 "\x00\x05\x0a\x0f\x14\x19\x1e\x23"
5122 "\x28\x2d\x32\x37\x3c\x41\x46\x4b"
5123 "\x50\x55\x5a\x5f\x64\x69\x6e\x73"
5124 "\x78\x7d\x82\x87\x8c\x91\x96\x9b"
5125 "\xa0\xa5\xaa\xaf\xb4\xb9\xbe\xc3"
5126 "\xc8\xcd\xd2\xd7\xdc\xe1\xe6\xeb"
5127 "\xf0\xf5\xfa\xff\x04\x09\x0e\x13"
5128 "\x18\x1d\x22\x27\x2c\x31\x36\x3b"
5129 "\x40\x45\x4a\x4f\x54\x59\x5e\x63"
5130 "\x68\x6d\x72\x77\x7c\x81\x86\x8b"
5131 "\x90\x95\x9a\x9f\xa4\xa9\xae\xb3"
5132 "\xb8\xbd\xc2\xc7\xcc\xd1\xd6\xdb"
5133 "\xe0\xe5\xea\xef\xf4\xf9\xfe\x03"
5134 "\x08\x0d\x12\x17\x1c\x21\x26\x2b"
5135 "\x30\x35\x3a\x3f\x44\x49\x4e\x53"
5136 "\x58\x5d\x62\x67\x6c\x71\x76\x7b"
5137 "\x80\x85\x8a\x8f\x94\x99\x9e\xa3"
5138 "\xa8\xad\xb2\xb7\xbc\xc1\xc6\xcb"
5139 "\xd0\xd5\xda\xdf\xe4\xe9\xee\xf3"
5140 "\xf8\xfd\x02\x07\x0c\x11\x16\x1b"
5141 "\x20\x25\x2a\x2f\x34\x39\x3e\x43"
5142 "\x48\x4d\x52\x57\x5c\x61\x66\x6b"
5143 "\x70\x75\x7a\x7f\x84\x89\x8e\x93"
5144 "\x98\x9d\xa2\xa7\xac\xb1\xb6\xbb"
5145 "\xc0\xc5\xca\xcf\xd4\xd9\xde\xe3"
5146 "\xe8\xed\xf2\xf7\xfc\x01\x06\x0b"
5147 "\x10\x15\x1a\x1f\x24\x29\x2e\x33"
5148 "\x38\x3d\x42\x47\x4c\x51\x56\x5b"
5149 "\x60\x65\x6a\x6f\x74\x79\x7e\x83"
5150 "\x88\x8d\x92\x97\x9c\xa1\xa6\xab"
5151 "\xb0\xb5\xba\xbf\xc4\xc9\xce\xd3"
5152 "\xd8\xdd\xe2\xe7\xec\xf1\xf6\xfb"
5153 "\x00\x07\x0e\x15\x1c\x23\x2a\x31"
5154 "\x38\x3f\x46\x4d\x54\x5b\x62\x69"
5155 "\x70\x77\x7e\x85\x8c\x93\x9a\xa1"
5156 "\xa8\xaf\xb6\xbd\xc4\xcb\xd2\xd9"
5157 "\xe0\xe7\xee\xf5\xfc\x03\x0a\x11"
5158 "\x18\x1f\x26\x2d\x34\x3b\x42\x49"
5159 "\x50\x57\x5e\x65\x6c\x73\x7a\x81"
5160 "\x88\x8f\x96\x9d\xa4\xab\xb2\xb9"
5161 "\xc0\xc7\xce\xd5\xdc\xe3\xea\xf1"
5162 "\xf8\xff\x06\x0d\x14\x1b\x22\x29"
5163 "\x30\x37\x3e\x45\x4c\x53\x5a\x61"
5164 "\x68\x6f\x76\x7d\x84\x8b\x92\x99"
5165 "\xa0\xa7\xae\xb5\xbc\xc3\xca\xd1"
5166 "\xd8\xdf\xe6\xed\xf4\xfb\x02\x09"
5167 "\x10\x17\x1e\x25\x2c\x33\x3a\x41"
5168 "\x48\x4f\x56\x5d\x64\x6b\x72\x79"
5169 "\x80\x87\x8e\x95\x9c\xa3\xaa\xb1"
5170 "\xb8\xbf\xc6\xcd\xd4\xdb\xe2\xe9"
5171 "\xf0\xf7\xfe\x05\x0c\x13\x1a\x21"
5172 "\x28\x2f\x36\x3d\x44\x4b\x52\x59"
5173 "\x60\x67\x6e\x75\x7c\x83\x8a\x91"
5174 "\x98\x9f\xa6\xad\xb4\xbb\xc2\xc9"
5175 "\xd0\xd7\xde\xe5\xec\xf3\xfa\x01"
5176 "\x08\x0f\x16\x1d\x24\x2b\x32\x39"
5177 "\x40\x47\x4e\x55\x5c\x63\x6a\x71"
5178 "\x78\x7f\x86\x8d\x94\x9b\xa2\xa9"
5179 "\xb0\xb7\xbe\xc5\xcc\xd3\xda\xe1"
5180 "\xe8\xef\xf6\xfd\x04\x0b\x12\x19"
5181 "\x20\x27\x2e\x35\x3c\x43\x4a\x51"
5182 "\x58\x5f\x66\x6d\x74\x7b\x82\x89"
5183 "\x90\x97\x9e\xa5\xac\xb3\xba\xc1"
5184 "\xc8\xcf\xd6\xdd\xe4\xeb\xf2\xf9"
5185 "\x00\x09\x12\x1b\x24\x2d\x36\x3f"
5186 "\x48\x51\x5a\x63\x6c\x75\x7e\x87"
5187 "\x90\x99\xa2\xab\xb4\xbd\xc6\xcf"
5188 "\xd8\xe1\xea\xf3\xfc\x05\x0e\x17"
5189 "\x20\x29\x32\x3b\x44\x4d\x56\x5f"
5190 "\x68\x71\x7a\x83\x8c\x95\x9e\xa7"
5191 "\xb0\xb9\xc2\xcb\xd4\xdd\xe6\xef"
5192 "\xf8\x01\x0a\x13\x1c\x25\x2e\x37"
5193 "\x40\x49\x52\x5b\x64\x6d\x76\x7f"
5194 "\x88\x91\x9a\xa3\xac\xb5\xbe\xc7"
5195 "\xd0\xd9\xe2\xeb\xf4\xfd\x06\x0f"
5196 "\x18\x21\x2a\x33\x3c\x45\x4e\x57"
5197 "\x60\x69\x72\x7b\x84\x8d\x96\x9f"
5198 "\xa8\xb1\xba\xc3\xcc\xd5\xde\xe7"
5199 "\xf0\xf9\x02\x0b\x14\x1d\x26\x2f"
5200 "\x38\x41\x4a\x53\x5c\x65\x6e\x77"
5201 "\x80\x89\x92\x9b\xa4\xad\xb6\xbf"
5202 "\xc8\xd1\xda\xe3\xec\xf5\xfe\x07"
5203 "\x10\x19\x22\x2b\x34\x3d\x46\x4f"
5204 "\x58\x61\x6a\x73\x7c\x85\x8e\x97"
5205 "\xa0\xa9\xb2\xbb\xc4\xcd\xd6\xdf"
5206 "\xe8\xf1\xfa\x03\x0c\x15\x1e\x27"
5207 "\x30\x39\x42\x4b\x54\x5d\x66\x6f"
5208 "\x78\x81\x8a\x93\x9c\xa5\xae\xb7"
5209 "\xc0\xc9\xd2\xdb\xe4\xed\xf6\xff"
5210 "\x08\x11\x1a\x23\x2c\x35\x3e\x47"
5211 "\x50\x59\x62\x6b\x74\x7d\x86\x8f"
5212 "\x98\xa1\xaa\xb3\xbc\xc5\xce\xd7"
5213 "\xe0\xe9\xf2\xfb\x04\x0d\x16\x1f"
5214 "\x28\x31\x3a\x43\x4c\x55\x5e\x67"
5215 "\x70\x79\x82\x8b\x94\x9d\xa6\xaf"
5216 "\xb8\xc1\xca\xd3\xdc\xe5\xee\xf7"
5217 "\x00\x0b\x16\x21\x2c\x37\x42\x4d"
5218 "\x58\x63\x6e\x79\x84\x8f\x9a\xa5"
5219 "\xb0\xbb\xc6\xd1\xdc\xe7\xf2\xfd"
5220 "\x08\x13\x1e\x29\x34\x3f\x4a\x55"
5221 "\x60\x6b\x76\x81\x8c\x97\xa2\xad"
5222 "\xb8\xc3\xce\xd9\xe4\xef\xfa\x05"
5223 "\x10\x1b\x26\x31\x3c\x47\x52\x5d"
5224 "\x68\x73\x7e\x89\x94\x9f\xaa\xb5"
5225 "\xc0\xcb\xd6\xe1\xec\xf7\x02\x0d"
5226 "\x18\x23\x2e\x39\x44\x4f\x5a\x65"
5227 "\x70\x7b\x86\x91\x9c\xa7\xb2\xbd"
5228 "\xc8\xd3\xde\xe9\xf4\xff\x0a\x15"
5229 "\x20\x2b\x36\x41\x4c\x57\x62\x6d"
5230 "\x78\x83\x8e\x99\xa4\xaf\xba\xc5"
5231 "\xd0\xdb\xe6\xf1\xfc\x07\x12\x1d"
5232 "\x28\x33\x3e\x49\x54\x5f\x6a\x75"
5233 "\x80\x8b\x96\xa1\xac\xb7\xc2\xcd"
5234 "\xd8\xe3\xee\xf9\x04\x0f\x1a\x25"
5235 "\x30\x3b\x46\x51\x5c\x67\x72\x7d"
5236 "\x88\x93\x9e\xa9\xb4\xbf\xca\xd5"
5237 "\xe0\xeb\xf6\x01\x0c\x17\x22\x2d"
5238 "\x38\x43\x4e\x59\x64\x6f\x7a\x85"
5239 "\x90\x9b\xa6\xb1\xbc\xc7\xd2\xdd"
5240 "\xe8\xf3\xfe\x09\x14\x1f\x2a\x35"
5241 "\x40\x4b\x56\x61\x6c\x77\x82\x8d"
5242 "\x98\xa3\xae\xb9\xc4\xcf\xda\xe5"
5243 "\xf0\xfb\x06\x11\x1c\x27\x32\x3d"
5244 "\x48\x53\x5e\x69\x74\x7f\x8a\x95"
5245 "\xa0\xab\xb6\xc1\xcc\xd7\xe2\xed"
5246 "\xf8\x03\x0e\x19\x24\x2f\x3a\x45"
5247 "\x50\x5b\x66\x71\x7c\x87\x92\x9d"
5248 "\xa8\xb3\xbe\xc9\xd4\xdf\xea\xf5"
5249 "\x00\x0d\x1a\x27\x34\x41\x4e\x5b"
5250 "\x68\x75\x82\x8f\x9c\xa9\xb6\xc3"
5251 "\xd0\xdd\xea\xf7\x04\x11\x1e\x2b"
5252 "\x38\x45\x52\x5f\x6c\x79\x86\x93"
5253 "\xa0\xad\xba\xc7\xd4\xe1\xee\xfb"
5254 "\x08\x15\x22\x2f\x3c\x49\x56\x63"
5255 "\x70\x7d\x8a\x97\xa4\xb1\xbe\xcb"
5256 "\xd8\xe5\xf2\xff\x0c\x19\x26\x33"
5257 "\x40\x4d\x5a\x67\x74\x81\x8e\x9b"
5258 "\xa8\xb5\xc2\xcf\xdc\xe9\xf6\x03"
5259 "\x10\x1d\x2a\x37\x44\x51\x5e\x6b"
5260 "\x78\x85\x92\x9f\xac\xb9\xc6\xd3"
5261 "\xe0\xed\xfa\x07\x14\x21\x2e\x3b"
5262 "\x48\x55\x62\x6f\x7c\x89\x96\xa3"
5263 "\xb0\xbd\xca\xd7\xe4\xf1\xfe\x0b"
5264 "\x18\x25\x32\x3f\x4c\x59\x66\x73"
5265 "\x80\x8d\x9a\xa7\xb4\xc1\xce\xdb"
5266 "\xe8\xf5\x02\x0f\x1c\x29\x36\x43"
5267 "\x50\x5d\x6a\x77\x84\x91\x9e\xab"
5268 "\xb8\xc5\xd2\xdf\xec\xf9\x06\x13"
5269 "\x20\x2d\x3a\x47\x54\x61\x6e\x7b"
5270 "\x88\x95\xa2\xaf\xbc\xc9\xd6\xe3"
5271 "\xf0\xfd\x0a\x17\x24\x31\x3e\x4b"
5272 "\x58\x65\x72\x7f\x8c\x99\xa6\xb3"
5273 "\xc0\xcd\xda\xe7\xf4\x01\x0e\x1b"
5274 "\x28\x35\x42\x4f\x5c\x69\x76\x83"
5275 "\x90\x9d\xaa\xb7\xc4\xd1\xde\xeb"
5276 "\xf8\x05\x12\x1f\x2c\x39\x46\x53"
5277 "\x60\x6d\x7a\x87\x94\xa1\xae\xbb"
5278 "\xc8\xd5\xe2\xef\xfc\x09\x16\x23"
5279 "\x30\x3d\x4a\x57\x64\x71\x7e\x8b"
5280 "\x98\xa5\xb2\xbf\xcc\xd9\xe6\xf3"
5281 "\x00\x0f\x1e\x2d\x3c\x4b\x5a\x69"
5282 "\x78\x87\x96\xa5\xb4\xc3\xd2\xe1"
5283 "\xf0\xff\x0e\x1d\x2c\x3b\x4a\x59"
5284 "\x68\x77\x86\x95\xa4\xb3\xc2\xd1"
5285 "\xe0\xef\xfe\x0d\x1c\x2b\x3a\x49"
5286 "\x58\x67\x76\x85\x94\xa3\xb2\xc1"
5287 "\xd0\xdf\xee\xfd\x0c\x1b\x2a\x39"
5288 "\x48\x57\x66\x75\x84\x93\xa2\xb1"
5289 "\xc0\xcf\xde\xed\xfc\x0b\x1a\x29"
5290 "\x38\x47\x56\x65\x74\x83\x92\xa1"
5291 "\xb0\xbf\xce\xdd\xec\xfb\x0a\x19"
5292 "\x28\x37\x46\x55\x64\x73\x82\x91"
5293 "\xa0\xaf\xbe\xcd\xdc\xeb\xfa\x09"
5294 "\x18\x27\x36\x45\x54\x63\x72\x81"
5295 "\x90\x9f\xae\xbd\xcc\xdb\xea\xf9"
5296 "\x08\x17\x26\x35\x44\x53\x62\x71"
5297 "\x80\x8f\x9e\xad\xbc\xcb\xda\xe9"
5298 "\xf8\x07\x16\x25\x34\x43\x52\x61"
5299 "\x70\x7f\x8e\x9d\xac\xbb\xca\xd9"
5300 "\xe8\xf7\x06\x15\x24\x33\x42\x51"
5301 "\x60\x6f\x7e\x8d\x9c\xab\xba\xc9"
5302 "\xd8\xe7\xf6\x05\x14\x23\x32\x41"
5303 "\x50\x5f\x6e\x7d\x8c\x9b\xaa\xb9"
5304 "\xc8\xd7\xe6\xf5\x04\x13\x22\x31"
5305 "\x40\x4f\x5e\x6d\x7c\x8b\x9a\xa9"
5306 "\xb8\xc7\xd6\xe5\xf4\x03\x12\x21"
5307 "\x30\x3f\x4e\x5d\x6c\x7b\x8a\x99"
5308 "\xa8\xb7\xc6\xd5\xe4\xf3\x02\x11"
5309 "\x20\x2f\x3e\x4d\x5c\x6b\x7a\x89"
5310 "\x98\xa7\xb6\xc5\xd4\xe3\xf2\x01"
5311 "\x10\x1f\x2e\x3d\x4c\x5b\x6a\x79"
5312 "\x88\x97\xa6\xb5\xc4\xd3\xe2\xf1"
5313 "\x00\x11\x22\x33\x44\x55\x66\x77"
5314 "\x88\x99\xaa\xbb\xcc\xdd\xee\xff"
5315 "\x10\x21\x32\x43\x54\x65\x76\x87"
5316 "\x98\xa9\xba\xcb\xdc\xed\xfe\x0f"
5317 "\x20\x31\x42\x53\x64\x75\x86\x97"
5318 "\xa8\xb9\xca\xdb\xec\xfd\x0e\x1f"
5319 "\x30\x41\x52\x63\x74\x85\x96\xa7"
5320 "\xb8\xc9\xda\xeb\xfc\x0d\x1e\x2f"
5321 "\x40\x51\x62\x73\x84\x95\xa6\xb7"
5322 "\xc8\xd9\xea\xfb\x0c\x1d\x2e\x3f"
5323 "\x50\x61\x72\x83\x94\xa5\xb6\xc7"
5324 "\xd8\xe9\xfa\x0b\x1c\x2d\x3e\x4f"
5325 "\x60\x71\x82\x93\xa4\xb5\xc6\xd7"
5326 "\xe8\xf9\x0a\x1b\x2c\x3d\x4e\x5f"
5327 "\x70\x81\x92\xa3\xb4\xc5\xd6\xe7"
5328 "\xf8\x09\x1a\x2b\x3c\x4d\x5e\x6f"
5329 "\x80\x91\xa2\xb3\xc4\xd5\xe6\xf7"
5330 "\x08\x19\x2a\x3b\x4c\x5d\x6e\x7f"
5331 "\x90\xa1\xb2\xc3\xd4\xe5\xf6\x07"
5332 "\x18\x29\x3a\x4b\x5c\x6d\x7e\x8f"
5333 "\xa0\xb1\xc2\xd3\xe4\xf5\x06\x17"
5334 "\x28\x39\x4a\x5b\x6c\x7d\x8e\x9f"
5335 "\xb0\xc1\xd2\xe3\xf4\x05\x16\x27"
5336 "\x38\x49\x5a\x6b\x7c\x8d\x9e\xaf"
5337 "\xc0\xd1\xe2\xf3\x04\x15\x26\x37"
5338 "\x48\x59\x6a\x7b\x8c\x9d\xae\xbf"
5339 "\xd0\xe1\xf2\x03\x14\x25\x36\x47"
5340 "\x58\x69\x7a\x8b\x9c\xad\xbe\xcf"
5341 "\xe0\xf1\x02\x13\x24\x35\x46\x57"
5342 "\x68\x79\x8a\x9b\xac\xbd\xce\xdf"
5343 "\xf0\x01\x12\x23\x34\x45\x56\x67"
5344 "\x78\x89\x9a\xab\xbc\xcd\xde\xef"
5345 "\x00\x13\x26\x39\x4c\x5f\x72\x85"
5346 "\x98\xab\xbe\xd1\xe4\xf7\x0a\x1d"
5347 "\x30\x43\x56\x69\x7c\x8f\xa2\xb5"
5348 "\xc8\xdb\xee\x01\x14\x27\x3a\x4d"
5349 "\x60\x73\x86\x99\xac\xbf\xd2\xe5"
5350 "\xf8\x0b\x1e\x31\x44\x57\x6a\x7d"
5351 "\x90\xa3\xb6\xc9\xdc\xef\x02\x15"
5352 "\x28\x3b\x4e\x61\x74\x87\x9a\xad"
5353 "\xc0\xd3\xe6\xf9\x0c\x1f\x32\x45"
5354 "\x58\x6b\x7e\x91\xa4\xb7\xca\xdd"
5355 "\xf0\x03\x16\x29\x3c\x4f\x62\x75"
5356 "\x88\x9b\xae\xc1\xd4\xe7\xfa\x0d"
5357 "\x20\x33\x46\x59\x6c\x7f\x92\xa5"
5358 "\xb8\xcb\xde\xf1\x04\x17\x2a\x3d"
5359 "\x50\x63\x76\x89\x9c\xaf\xc2\xd5"
5360 "\xe8\xfb\x0e\x21\x34\x47\x5a\x6d"
5361 "\x80\x93\xa6\xb9\xcc\xdf\xf2\x05"
5362 "\x18\x2b\x3e\x51\x64\x77\x8a\x9d"
5363 "\xb0\xc3\xd6\xe9\xfc\x0f\x22\x35"
5364 "\x48\x5b\x6e\x81\x94\xa7\xba\xcd"
5365 "\xe0\xf3\x06\x19\x2c\x3f\x52\x65"
5366 "\x78\x8b\x9e\xb1\xc4\xd7\xea\xfd"
5367 "\x10\x23\x36\x49\x5c\x6f\x82\x95"
5368 "\xa8\xbb\xce\xe1\xf4\x07\x1a\x2d"
5369 "\x40\x53\x66\x79\x8c\x9f\xb2\xc5"
5370 "\xd8\xeb\xfe\x11\x24\x37\x4a\x5d"
5371 "\x70\x83\x96\xa9\xbc\xcf\xe2\xf5"
5372 "\x08\x1b\x2e\x41\x54\x67\x7a\x8d"
5373 "\xa0\xb3\xc6\xd9\xec\xff\x12\x25"
5374 "\x38\x4b\x5e\x71\x84\x97\xaa\xbd"
5375 "\xd0\xe3\xf6\x09\x1c\x2f\x42\x55"
5376 "\x68\x7b\x8e\xa1\xb4\xc7\xda\xed"
5377 "\x00\x15\x2a\x3f\x54\x69\x7e\x93"
5378 "\xa8\xbd\xd2\xe7\xfc\x11\x26\x3b"
5379 "\x50\x65\x7a\x8f\xa4\xb9\xce\xe3"
5380 "\xf8\x0d\x22\x37\x4c\x61\x76\x8b"
5381 "\xa0\xb5\xca\xdf\xf4\x09\x1e\x33"
5382 "\x48\x5d\x72\x87\x9c\xb1\xc6\xdb"
5383 "\xf0\x05\x1a\x2f\x44\x59\x6e\x83"
5384 "\x98\xad\xc2\xd7\xec\x01\x16\x2b"
5385 "\x40\x55\x6a\x7f\x94\xa9\xbe\xd3"
5386 "\xe8\xfd\x12\x27\x3c\x51\x66\x7b"
5387 "\x90\xa5\xba\xcf\xe4\xf9\x0e\x23"
5388 "\x38\x4d\x62\x77\x8c\xa1\xb6\xcb"
5389 "\xe0\xf5\x0a\x1f\x34\x49\x5e\x73"
5390 "\x88\x9d\xb2\xc7\xdc\xf1\x06\x1b"
5391 "\x30\x45\x5a\x6f\x84\x99\xae\xc3"
5392 "\xd8\xed\x02\x17\x2c\x41\x56\x6b"
5393 "\x80\x95\xaa\xbf\xd4\xe9\xfe\x13"
5394 "\x28\x3d\x52\x67\x7c\x91\xa6\xbb"
5395 "\xd0\xe5\xfa\x0f\x24\x39\x4e\x63"
5396 "\x78\x8d\xa2\xb7\xcc\xe1\xf6\x0b"
5397 "\x20\x35\x4a\x5f\x74\x89\x9e\xb3"
5398 "\xc8\xdd\xf2\x07\x1c\x31\x46\x5b"
5399 "\x70\x85\x9a\xaf\xc4\xd9\xee\x03"
5400 "\x18\x2d\x42\x57\x6c\x81\x96\xab"
5401 "\xc0\xd5\xea\xff\x14\x29\x3e\x53"
5402 "\x68\x7d\x92\xa7\xbc\xd1\xe6\xfb"
5403 "\x10\x25\x3a\x4f\x64\x79\x8e\xa3"
5404 "\xb8\xcd\xe2\xf7\x0c\x21\x36\x4b"
5405 "\x60\x75\x8a\x9f\xb4\xc9\xde\xf3"
5406 "\x08\x1d\x32\x47\x5c\x71\x86\x9b"
5407 "\xb0\xc5\xda\xef\x04\x19\x2e\x43"
5408 "\x58\x6d\x82\x97\xac\xc1\xd6\xeb"
5409 "\x00\x17\x2e\x45\x5c\x73\x8a\xa1"
5410 "\xb8\xcf\xe6\xfd\x14\x2b\x42\x59"
5411 "\x70\x87\x9e\xb5\xcc\xe3\xfa\x11"
5412 "\x28\x3f\x56\x6d\x84\x9b\xb2\xc9"
5413 "\xe0\xf7\x0e\x25\x3c\x53\x6a\x81"
5414 "\x98\xaf\xc6\xdd\xf4\x0b\x22\x39"
5415 "\x50\x67\x7e\x95\xac\xc3\xda\xf1"
5416 "\x08\x1f\x36\x4d\x64\x7b\x92\xa9"
5417 "\xc0\xd7\xee\x05\x1c\x33\x4a\x61"
5418 "\x78\x8f\xa6\xbd\xd4\xeb\x02\x19"
5419 "\x30\x47\x5e\x75\x8c\xa3\xba\xd1"
5420 "\xe8\xff\x16\x2d\x44\x5b\x72\x89"
5421 "\xa0\xb7\xce\xe5\xfc\x13\x2a\x41"
5422 "\x58\x6f\x86\x9d\xb4\xcb\xe2\xf9"
5423 "\x10\x27\x3e\x55\x6c\x83\x9a\xb1"
5424 "\xc8\xdf\xf6\x0d\x24\x3b\x52\x69"
5425 "\x80\x97\xae\xc5\xdc\xf3\x0a\x21"
5426 "\x38\x4f\x66\x7d\x94\xab\xc2\xd9"
5427 "\xf0\x07\x1e\x35\x4c\x63\x7a\x91"
5428 "\xa8\xbf\xd6\xed\x04\x1b\x32\x49"
5429 "\x60\x77\x8e\xa5\xbc\xd3\xea\x01"
5430 "\x18\x2f\x46\x5d\x74\x8b\xa2\xb9"
5431 "\xd0\xe7\xfe\x15\x2c\x43\x5a\x71"
5432 "\x88\x9f\xb6\xcd\xe4\xfb\x12\x29"
5433 "\x40\x57\x6e\x85\x9c\xb3\xca\xe1"
5434 "\xf8\x0f\x26\x3d\x54\x6b\x82\x99"
5435 "\xb0\xc7\xde\xf5\x0c\x23\x3a\x51"
5436 "\x68\x7f\x96\xad\xc4\xdb\xf2\x09"
5437 "\x20\x37\x4e\x65\x7c\x93\xaa\xc1"
5438 "\xd8\xef\x06\x1d\x34\x4b\x62\x79"
5439 "\x90\xa7\xbe\xd5\xec\x03\x1a\x31"
5440 "\x48\x5f\x76\x8d\xa4\xbb\xd2\xe9"
5441 "\x00\x19\x32\x4b\x64\x7d\x96\xaf"
5442 "\xc8\xe1\xfa\x13\x2c\x45\x5e\x77"
5443 "\x90\xa9\xc2\xdb\xf4\x0d\x26\x3f"
5444 "\x58\x71\x8a\xa3\xbc\xd5\xee\x07"
5445 "\x20\x39\x52\x6b\x84\x9d\xb6\xcf"
5446 "\xe8\x01\x1a\x33\x4c\x65\x7e\x97"
5447 "\xb0\xc9\xe2\xfb\x14\x2d\x46\x5f"
5448 "\x78\x91\xaa\xc3\xdc\xf5\x0e\x27"
5449 "\x40\x59\x72\x8b\xa4\xbd\xd6\xef"
5450 "\x08\x21\x3a\x53\x6c\x85\x9e\xb7"
5451 "\xd0\xe9\x02\x1b\x34\x4d\x66\x7f"
5452 "\x98\xb1\xca\xe3\xfc\x15\x2e\x47"
5453 "\x60\x79\x92\xab\xc4\xdd\xf6\x0f"
5454 "\x28\x41\x5a\x73\x8c\xa5\xbe\xd7"
5455 "\xf0\x09\x22\x3b\x54\x6d\x86\x9f"
5456 "\xb8\xd1\xea\x03\x1c\x35\x4e\x67"
5457 "\x80\x99\xb2\xcb\xe4\xfd\x16\x2f"
5458 "\x48\x61\x7a\x93\xac\xc5\xde\xf7"
5459 "\x10\x29\x42\x5b\x74\x8d\xa6\xbf"
5460 "\xd8\xf1\x0a\x23\x3c\x55\x6e\x87"
5461 "\xa0\xb9\xd2\xeb\x04\x1d\x36\x4f"
5462 "\x68\x81\x9a\xb3\xcc\xe5\xfe\x17"
5463 "\x30\x49\x62\x7b\x94\xad\xc6\xdf"
5464 "\xf8\x11\x2a\x43\x5c\x75\x8e\xa7"
5465 "\xc0\xd9\xf2\x0b\x24\x3d\x56\x6f"
5466 "\x88\xa1\xba\xd3\xec\x05\x1e\x37"
5467 "\x50\x69\x82\x9b\xb4\xcd\xe6\xff"
5468 "\x18\x31\x4a\x63\x7c\x95\xae\xc7"
5469 "\xe0\xf9\x12\x2b\x44\x5d\x76\x8f"
5470 "\xa8\xc1\xda\xf3\x0c\x25\x3e\x57"
5471 "\x70\x89\xa2\xbb\xd4\xed\x06\x1f"
5472 "\x38\x51\x6a\x83\x9c\xb5\xce\xe7"
5473 "\x00\x1b\x36\x51\x6c\x87\xa2\xbd"
5474 "\xd8\xf3\x0e\x29\x44\x5f\x7a\x95"
5475 "\xb0\xcb\xe6\x01\x1c\x37\x52\x6d"
5476 "\x88\xa3\xbe\xd9\xf4\x0f\x2a\x45"
5477 "\x60\x7b\x96\xb1\xcc\xe7\x02\x1d"
5478 "\x38\x53\x6e\x89\xa4\xbf\xda\xf5"
5479 "\x10\x2b\x46\x61\x7c\x97\xb2\xcd"
5480 "\xe8\x03\x1e\x39\x54\x6f\x8a\xa5"
5481 "\xc0\xdb\xf6\x11\x2c\x47\x62\x7d"
5482 "\x98\xb3\xce\xe9\x04\x1f\x3a\x55"
5483 "\x70\x8b\xa6\xc1\xdc\xf7\x12\x2d"
5484 "\x48\x63\x7e\x99\xb4\xcf\xea\x05"
5485 "\x20\x3b\x56\x71\x8c\xa7\xc2\xdd"
5486 "\xf8\x13\x2e\x49\x64\x7f\x9a\xb5"
5487 "\xd0\xeb\x06\x21\x3c\x57\x72\x8d"
5488 "\xa8\xc3\xde\xf9\x14\x2f\x4a\x65"
5489 "\x80\x9b\xb6\xd1\xec\x07\x22\x3d"
5490 "\x58\x73\x8e\xa9\xc4\xdf\xfa\x15"
5491 "\x30\x4b\x66\x81\x9c\xb7\xd2\xed"
5492 "\x08\x23\x3e\x59\x74\x8f\xaa\xc5"
5493 "\xe0\xfb\x16\x31\x4c\x67\x82\x9d"
5494 "\xb8\xd3\xee\x09\x24\x3f\x5a\x75"
5495 "\x90\xab\xc6\xe1\xfc\x17\x32\x4d"
5496 "\x68\x83\x9e\xb9\xd4\xef\x0a\x25"
5497 "\x40\x5b\x76\x91\xac\xc7\xe2\xfd"
5498 "\x18\x33\x4e\x69\x84\x9f\xba\xd5"
5499 "\xf0\x0b\x26\x41\x5c\x77\x92\xad"
5500 "\xc8\xe3\xfe\x19\x34\x4f\x6a\x85"
5501 "\xa0\xbb\xd6\xf1\x0c\x27\x42\x5d"
5502 "\x78\x93\xae\xc9\xe4\xff\x1a\x35"
5503 "\x50\x6b\x86\xa1\xbc\xd7\xf2\x0d"
5504 "\x28\x43\x5e\x79\x94\xaf\xca\xe5"
5505 "\x00\x1d\x3a\x57\x74\x91\xae\xcb"
5506 "\xe8\x05\x22\x3f\x5c\x79\x96\xb3"
5507 "\xd0\xed\x0a\x27\x44\x61\x7e\x9b"
5508 "\xb8\xd5\xf2\x0f\x2c\x49\x66\x83"
5509 "\xa0\xbd\xda\xf7\x14\x31\x4e\x6b"
5510 "\x88\xa5\xc2\xdf\xfc\x19\x36\x53"
5511 "\x70\x8d\xaa\xc7\xe4\x01\x1e\x3b"
5512 "\x58\x75\x92\xaf\xcc\xe9\x06\x23"
5513 "\x40\x5d\x7a\x97\xb4\xd1\xee\x0b"
5514 "\x28\x45\x62\x7f\x9c\xb9\xd6\xf3"
5515 "\x10\x2d\x4a\x67\x84\xa1\xbe\xdb"
5516 "\xf8\x15\x32\x4f\x6c\x89\xa6\xc3"
5517 "\xe0\xfd\x1a\x37\x54\x71\x8e\xab"
5518 "\xc8\xe5\x02\x1f\x3c\x59\x76\x93"
5519 "\xb0\xcd\xea\x07\x24\x41\x5e\x7b"
5520 "\x98\xb5\xd2\xef\x0c\x29\x46\x63"
5521 "\x80\x9d\xba\xd7\xf4\x11\x2e\x4b"
5522 "\x68\x85\xa2\xbf\xdc\xf9\x16\x33"
5523 "\x50\x6d\x8a\xa7\xc4\xe1\xfe\x1b"
5524 "\x38\x55\x72\x8f\xac\xc9\xe6\x03"
5525 "\x20\x3d\x5a\x77\x94\xb1\xce\xeb"
5526 "\x08\x25\x42\x5f\x7c\x99\xb6\xd3"
5527 "\xf0\x0d\x2a\x47\x64\x81\x9e\xbb"
5528 "\xd8\xf5\x12\x2f\x4c\x69\x86\xa3"
5529 "\xc0\xdd\xfa\x17\x34\x51\x6e\x8b"
5530 "\xa8\xc5\xe2\xff\x1c\x39\x56\x73"
5531 "\x90\xad\xca\xe7\x04\x21\x3e\x5b"
5532 "\x78\x95\xb2\xcf\xec\x09\x26\x43"
5533 "\x60\x7d\x9a\xb7\xd4\xf1\x0e\x2b"
5534 "\x48\x65\x82\x9f\xbc\xd9\xf6\x13"
5535 "\x30\x4d\x6a\x87\xa4\xc1\xde\xfb"
5536 "\x18\x35\x52\x6f\x8c\xa9\xc6\xe3"
5537 "\x00\x1f\x3e\x5d\x7c\x9b\xba\xd9"
5538 "\xf8\x17\x36\x55\x74\x93\xb2\xd1"
5539 "\xf0\x0f\x2e\x4d\x6c\x8b\xaa\xc9"
5540 "\xe8\x07\x26\x45\x64\x83\xa2\xc1"
5541 "\xe0\xff\x1e\x3d\x5c\x7b\x9a\xb9"
5542 "\xd8\xf7\x16\x35\x54\x73\x92\xb1"
5543 "\xd0\xef\x0e\x2d\x4c\x6b\x8a\xa9"
5544 "\xc8\xe7\x06\x25\x44\x63\x82\xa1"
5545 "\xc0\xdf\xfe\x1d\x3c\x5b\x7a\x99"
5546 "\xb8\xd7\xf6\x15\x34\x53\x72\x91"
5547 "\xb0\xcf\xee\x0d\x2c\x4b\x6a\x89"
5548 "\xa8\xc7\xe6\x05\x24\x43\x62\x81"
5549 "\xa0\xbf\xde\xfd\x1c\x3b\x5a\x79"
5550 "\x98\xb7\xd6\xf5\x14\x33\x52\x71"
5551 "\x90\xaf\xce\xed\x0c\x2b\x4a\x69"
5552 "\x88\xa7\xc6\xe5\x04\x23\x42\x61"
5553 "\x80\x9f\xbe\xdd\xfc\x1b\x3a\x59"
5554 "\x78\x97\xb6\xd5\xf4\x13\x32\x51"
5555 "\x70\x8f\xae\xcd\xec\x0b\x2a\x49"
5556 "\x68\x87\xa6\xc5\xe4\x03\x22\x41"
5557 "\x60\x7f\x9e\xbd\xdc\xfb\x1a\x39"
5558 "\x58\x77\x96\xb5\xd4\xf3\x12\x31"
5559 "\x50\x6f\x8e\xad\xcc\xeb\x0a\x29"
5560 "\x48\x67\x86\xa5\xc4\xe3\x02\x21"
5561 "\x40\x5f\x7e\x9d\xbc\xdb\xfa\x19"
5562 "\x38\x57\x76\x95\xb4\xd3\xf2\x11"
5563 "\x30\x4f\x6e\x8d\xac\xcb\xea\x09"
5564 "\x28\x47\x66\x85\xa4\xc3\xe2\x01"
5565 "\x20\x3f\x5e\x7d\x9c\xbb\xda\xf9"
5566 "\x18\x37\x56\x75\x94\xb3\xd2\xf1"
5567 "\x10\x2f\x4e\x6d\x8c\xab\xca\xe9"
5568 "\x08\x27\x46\x65\x84\xa3\xc2\xe1"
5569 "\x00\x21\x42\x63",
5570 .ilen = 4100,
5571 .result =
5572 "\xf0\x5c\x74\xad\x4e\xbc\x99\xe2"
5573 "\xae\xff\x91\x3a\x44\xcf\x38\x32"
5574 "\x1e\xad\xa7\xcd\xa1\x39\x95\xaa"
5575 "\x10\xb1\xb3\x2e\x04\x31\x8f\x86"
5576 "\xf2\x62\x74\x70\x0c\xa4\x46\x08"
5577 "\xa8\xb7\x99\xa8\xe9\xd2\x73\x79"
5578 "\x7e\x6e\xd4\x8f\x1e\xc7\x8e\x31"
5579 "\x0b\xfa\x4b\xce\xfd\xf3\x57\x71"
5580 "\xe9\x46\x03\xa5\x3d\x34\x00\xe2"
5581 "\x18\xff\x75\x6d\x06\x2d\x00\xab"
5582 "\xb9\x3e\x6c\x59\xc5\x84\x06\xb5"
5583 "\x8b\xd0\x89\x9c\x4a\x79\x16\xc6"
5584 "\x3d\x74\x54\xfa\x44\xcd\x23\x26"
5585 "\x5c\xcf\x7e\x28\x92\x32\xbf\xdf"
5586 "\xa7\x20\x3c\x74\x58\x2a\x9a\xde"
5587 "\x61\x00\x1c\x4f\xff\x59\xc4\x22"
5588 "\xac\x3c\xd0\xe8\x6c\xf9\x97\x1b"
5589 "\x58\x9b\xad\x71\xe8\xa9\xb5\x0d"
5590 "\xee\x2f\x04\x1f\x7f\xbc\x99\xee"
5591 "\x84\xff\x42\x60\xdc\x3a\x18\xa5"
5592 "\x81\xf9\xef\xdc\x7a\x0f\x65\x41"
5593 "\x2f\xa3\xd3\xf9\xc2\xcb\xc0\x4d"
5594 "\x8f\xd3\x76\x96\xad\x49\x6d\x38"
5595 "\x3d\x39\x0b\x6c\x80\xb7\x54\x69"
5596 "\xf0\x2c\x90\x02\x29\x0d\x1c\x12"
5597 "\xad\x55\xc3\x8b\x68\xd9\xcc\xb3"
5598 "\xb2\x64\x33\x90\x5e\xca\x4b\xe2"
5599 "\xfb\x75\xdc\x63\xf7\x9f\x82\x74"
5600 "\xf0\xc9\xaa\x7f\xe9\x2a\x9b\x33"
5601 "\xbc\x88\x00\x7f\xca\xb2\x1f\x14"
5602 "\xdb\xc5\x8e\x7b\x11\x3c\x3e\x08"
5603 "\xf3\x83\xe8\xe0\x94\x86\x2e\x92"
5604 "\x78\x6b\x01\xc9\xc7\x83\xba\x21"
5605 "\x6a\x25\x15\x33\x4e\x45\x08\xec"
5606 "\x35\xdb\xe0\x6e\x31\x51\x79\xa9"
5607 "\x42\x44\x65\xc1\xa0\xf1\xf9\x2a"
5608 "\x70\xd5\xb6\xc6\xc1\x8c\x39\xfc"
5609 "\x25\xa6\x55\xd9\xdd\x2d\x4c\xec"
5610 "\x49\xc6\xeb\x0e\xa8\x25\x2a\x16"
5611 "\x1b\x66\x84\xda\xe2\x92\xe5\xc0"
5612 "\xc8\x53\x07\xaf\x80\x84\xec\xfd"
5613 "\xcd\xd1\x6e\xcd\x6f\x6a\xf5\x36"
5614 "\xc5\x15\xe5\x25\x7d\x77\xd1\x1a"
5615 "\x93\x36\xa9\xcf\x7c\xa4\x54\x4a"
5616 "\x06\x51\x48\x4e\xf6\x59\x87\xd2"
5617 "\x04\x02\xef\xd3\x44\xde\x76\x31"
5618 "\xb3\x34\x17\x1b\x9d\x66\x11\x9f"
5619 "\x1e\xcc\x17\xe9\xc7\x3c\x1b\xe7"
5620 "\xcb\x50\x08\xfc\xdc\x2b\x24\xdb"
5621 "\x65\x83\xd0\x3b\xe3\x30\xea\x94"
5622 "\x6c\xe7\xe8\x35\x32\xc7\xdb\x64"
5623 "\xb4\x01\xab\x36\x2c\x77\x13\xaf"
5624 "\xf8\x2b\x88\x3f\x54\x39\xc4\x44"
5625 "\xfe\xef\x6f\x68\x34\xbe\x0f\x05"
5626 "\x16\x6d\xf6\x0a\x30\xe7\xe3\xed"
5627 "\xc4\xde\x3c\x1b\x13\xd8\xdb\xfe"
5628 "\x41\x62\xe5\x28\xd4\x8d\xa3\xc7"
5629 "\x93\x97\xc6\x48\x45\x1d\x9f\x83"
5630 "\xdf\x4b\x40\x3e\x42\x25\x87\x80"
5631 "\x4c\x7d\xa8\xd4\x98\x23\x95\x75"
5632 "\x41\x8c\xda\x41\x9b\xd4\xa7\x06"
5633 "\xb5\xf1\x71\x09\x53\xbe\xca\xbf"
5634 "\x32\x03\xed\xf0\x50\x1c\x56\x39"
5635 "\x5b\xa4\x75\x18\xf7\x9b\x58\xef"
5636 "\x53\xfc\x2a\x38\x23\x15\x75\xcd"
5637 "\x45\xe5\x5a\x82\x55\xba\x21\xfa"
5638 "\xd4\xbd\xc6\x94\x7c\xc5\x80\x12"
5639 "\xf7\x4b\x32\xc4\x9a\x82\xd8\x28"
5640 "\x8f\xd9\xc2\x0f\x60\x03\xbe\x5e"
5641 "\x21\xd6\x5f\x58\xbf\x5c\xb1\x32"
5642 "\x82\x8d\xa9\xe5\xf2\x66\x1a\xc0"
5643 "\xa0\xbc\x58\x2f\x71\xf5\x2f\xed"
5644 "\xd1\x26\xb9\xd8\x49\x5a\x07\x19"
5645 "\x01\x7c\x59\xb0\xf8\xa4\xb7\xd3"
5646 "\x7b\x1a\x8c\x38\xf4\x50\xa4\x59"
5647 "\xb0\xcc\x41\x0b\x88\x7f\xe5\x31"
5648 "\xb3\x42\xba\xa2\x7e\xd4\x32\x71"
5649 "\x45\x87\x48\xa9\xc2\xf2\x89\xb3"
5650 "\xe4\xa7\x7e\x52\x15\x61\xfa\xfe"
5651 "\xc9\xdd\x81\xeb\x13\xab\xab\xc3"
5652 "\x98\x59\xd8\x16\x3d\x14\x7a\x1c"
5653 "\x3c\x41\x9a\x16\x16\x9b\xd2\xd2"
5654 "\x69\x3a\x29\x23\xac\x86\x32\xa5"
5655 "\x48\x9c\x9e\xf3\x47\x77\x81\x70"
5656 "\x24\xe8\x85\xd2\xf5\xb5\xfa\xff"
5657 "\x59\x6a\xd3\x50\x59\x43\x59\xde"
5658 "\xd9\xf1\x55\xa5\x0c\xc3\x1a\x1a"
5659 "\x18\x34\x0d\x1a\x63\x33\xed\x10"
5660 "\xe0\x1d\x2a\x18\xd2\xc0\x54\xa8"
5661 "\xca\xb5\x9a\xd3\xdd\xca\x45\x84"
5662 "\x50\xe7\x0f\xfe\xa4\x99\x5a\xbe"
5663 "\x43\x2d\x9a\xcb\x92\x3f\x5a\x1d"
5664 "\x85\xd8\xc9\xdf\x68\xc9\x12\x80"
5665 "\x56\x0c\xdc\x00\xdc\x3a\x7d\x9d"
5666 "\xa3\xa2\xe8\x4d\xbf\xf9\x70\xa0"
5667 "\xa4\x13\x4f\x6b\xaf\x0a\x89\x7f"
5668 "\xda\xf0\xbf\x9b\xc8\x1d\xe5\xf8"
5669 "\x2e\x8b\x07\xb5\x73\x1b\xcc\xa2"
5670 "\xa6\xad\x30\xbc\x78\x3c\x5b\x10"
5671 "\xfa\x5e\x62\x2d\x9e\x64\xb3\x33"
5672 "\xce\xf9\x1f\x86\xe7\x8b\xa2\xb8"
5673 "\xe8\x99\x57\x8c\x11\xed\x66\xd9"
5674 "\x3c\x72\xb9\xc3\xe6\x4e\x17\x3a"
5675 "\x6a\xcb\x42\x24\x06\xed\x3e\x4e"
5676 "\xa3\xe8\x6a\x94\xda\x0d\x4e\xd5"
5677 "\x14\x19\xcf\xb6\x26\xd8\x2e\xcc"
5678 "\x64\x76\x38\x49\x4d\xfe\x30\x6d"
5679 "\xe4\xc8\x8c\x7b\xc4\xe0\x35\xba"
5680 "\x22\x6e\x76\xe1\x1a\xf2\x53\xc3"
5681 "\x28\xa2\x82\x1f\x61\x69\xad\xc1"
5682 "\x7b\x28\x4b\x1e\x6c\x85\x95\x9b"
5683 "\x51\xb5\x17\x7f\x12\x69\x8c\x24"
5684 "\xd5\xc7\x5a\x5a\x11\x54\xff\x5a"
5685 "\xf7\x16\xc3\x91\xa6\xf0\xdc\x0a"
5686 "\xb6\xa7\x4a\x0d\x7a\x58\xfe\xa5"
5687 "\xf5\xcb\x8f\x7b\x0e\xea\x57\xe7"
5688 "\xbd\x79\xd6\x1c\x88\x23\x6c\xf2"
5689 "\x4d\x29\x77\x53\x35\x6a\x00\x8d"
5690 "\xcd\xa3\x58\xbe\x77\x99\x18\xf8"
5691 "\xe6\xe1\x8f\xe9\x37\x8f\xe3\xe2"
5692 "\x5a\x8a\x93\x25\xaf\xf3\x78\x80"
5693 "\xbe\xa6\x1b\xc6\xac\x8b\x1c\x91"
5694 "\x58\xe1\x9f\x89\x35\x9d\x1d\x21"
5695 "\x29\x9f\xf4\x99\x02\x27\x0f\xa8"
5696 "\x4f\x79\x94\x2b\x33\x2c\xda\xa2"
5697 "\x26\x39\x83\x94\xef\x27\xd8\x53"
5698 "\x8f\x66\x0d\xe4\x41\x7d\x34\xcd"
5699 "\x43\x7c\x95\x0a\x53\xef\x66\xda"
5700 "\x7e\x9b\xf3\x93\xaf\xd0\x73\x71"
5701 "\xba\x40\x9b\x74\xf8\xd7\xd7\x41"
5702 "\x6d\xaf\x72\x9c\x8d\x21\x87\x3c"
5703 "\xfd\x0a\x90\xa9\x47\x96\x9e\xd3"
5704 "\x88\xee\x73\xcf\x66\x2f\x52\x56"
5705 "\x6d\xa9\x80\x4c\xe2\x6f\x62\x88"
5706 "\x3f\x0e\x54\x17\x48\x80\x5d\xd3"
5707 "\xc3\xda\x25\x3d\xa1\xc8\xcb\x9f"
5708 "\x9b\x70\xb3\xa1\xeb\x04\x52\xa1"
5709 "\xf2\x22\x0f\xfc\xc8\x18\xfa\xf9"
5710 "\x85\x9c\xf1\xac\xeb\x0c\x02\x46"
5711 "\x75\xd2\xf5\x2c\xe3\xd2\x59\x94"
5712 "\x12\xf3\x3c\xfc\xd7\x92\xfa\x36"
5713 "\xba\x61\x34\x38\x7c\xda\x48\x3e"
5714 "\x08\xc9\x39\x23\x5e\x02\x2c\x1a"
5715 "\x18\x7e\xb4\xd9\xfd\x9e\x40\x02"
5716 "\xb1\x33\x37\x32\xe7\xde\xd6\xd0"
5717 "\x7c\x58\x65\x4b\xf8\x34\x27\x9c"
5718 "\x44\xb4\xbd\xe9\xe9\x4c\x78\x7d"
5719 "\x4b\x9f\xce\xb1\xcd\x47\xa5\x37"
5720 "\xe5\x6d\xbd\xb9\x43\x94\x0a\xd4"
5721 "\xd6\xf9\x04\x5f\xb5\x66\x6c\x1a"
5722 "\x35\x12\xe3\x36\x28\x27\x36\x58"
5723 "\x01\x2b\x79\xe4\xba\x6d\x10\x7d"
5724 "\x65\xdf\x84\x95\xf4\xd5\xb6\x8f"
5725 "\x2b\x9f\x96\x00\x86\x60\xf0\x21"
5726 "\x76\xa8\x6a\x8c\x28\x1c\xb3\x6b"
5727 "\x97\xd7\xb6\x53\x2a\xcc\xab\x40"
5728 "\x9d\x62\x79\x58\x52\xe6\x65\xb7"
5729 "\xab\x55\x67\x9c\x89\x7c\x03\xb0"
5730 "\x73\x59\xc5\x81\xf5\x18\x17\x5c"
5731 "\x89\xf3\x78\x35\x44\x62\x78\x72"
5732 "\xd0\x96\xeb\x31\xe7\x87\x77\x14"
5733 "\x99\x51\xf2\x59\x26\x9e\xb5\xa6"
5734 "\x45\xfe\x6e\xbd\x07\x4c\x94\x5a"
5735 "\xa5\x7d\xfc\xf1\x2b\x77\xe2\xfe"
5736 "\x17\xd4\x84\xa0\xac\xb5\xc7\xda"
5737 "\xa9\x1a\xb6\xf3\x74\x11\xb4\x9d"
5738 "\xfb\x79\x2e\x04\x2d\x50\x28\x83"
5739 "\xbf\xc6\x52\xd3\x34\xd6\xe8\x7a"
5740 "\xb6\xea\xe7\xa8\x6c\x15\x1e\x2c"
5741 "\x57\xbc\x48\x4e\x5f\x5c\xb6\x92"
5742 "\xd2\x49\x77\x81\x6d\x90\x70\xae"
5743 "\x98\xa1\x03\x0d\x6b\xb9\x77\x14"
5744 "\xf1\x4e\x23\xd3\xf8\x68\xbd\xc2"
5745 "\xfe\x04\xb7\x5c\xc5\x17\x60\x8f"
5746 "\x65\x54\xa4\x7a\x42\xdc\x18\x0d"
5747 "\xb5\xcf\x0f\xd3\xc7\x91\x66\x1b"
5748 "\x45\x42\x27\x75\x50\xe5\xee\xb8"
5749 "\x7f\x33\x2c\xba\x4a\x92\x4d\x2c"
5750 "\x3c\xe3\x0d\x80\x01\xba\x0d\x29"
5751 "\xd8\x3c\xe9\x13\x16\x57\xe6\xea"
5752 "\x94\x52\xe7\x00\x4d\x30\xb0\x0f"
5753 "\x35\xb8\xb8\xa7\xb1\xb5\x3b\x44"
5754 "\xe1\x2f\xfd\x88\xed\x43\xe7\x52"
5755 "\x10\x93\xb3\x8a\x30\x6b\x0a\xf7"
5756 "\x23\xc6\x50\x9d\x4a\xb0\xde\xc3"
5757 "\xdc\x9b\x2f\x01\x56\x36\x09\xc5"
5758 "\x2f\x6b\xfe\xf1\xd8\x27\x45\x03"
5759 "\x30\x5e\x5c\x5b\xb4\x62\x0e\x1a"
5760 "\xa9\x21\x2b\x92\x94\x87\x62\x57"
5761 "\x4c\x10\x74\x1a\xf1\x0a\xc5\x84"
5762 "\x3b\x9e\x72\x02\xd7\xcc\x09\x56"
5763 "\xbd\x54\xc1\xf0\xc3\xe3\xb3\xf8"
5764 "\xd2\x0d\x61\xcb\xef\xce\x0d\x05"
5765 "\xb0\x98\xd9\x8e\x4f\xf9\xbc\x93"
5766 "\xa6\xea\xc8\xcf\x10\x53\x4b\xf1"
5767 "\xec\xfc\x89\xf9\x64\xb0\x22\xbf"
5768 "\x9e\x55\x46\x9f\x7c\x50\x8e\x84"
5769 "\x54\x20\x98\xd7\x6c\x40\x1e\xdb"
5770 "\x69\x34\x78\x61\x24\x21\x9c\x8a"
5771 "\xb3\x62\x31\x8b\x6e\xf5\x2a\x35"
5772 "\x86\x13\xb1\x6c\x64\x2e\x41\xa5"
5773 "\x05\xf2\x42\xba\xd2\x3a\x0d\x8e"
5774 "\x8a\x59\x94\x3c\xcf\x36\x27\x82"
5775 "\xc2\x45\xee\x58\xcd\x88\xb4\xec"
5776 "\xde\xb2\x96\x0a\xaf\x38\x6f\x88"
5777 "\xd7\xd8\xe1\xdf\xb9\x96\xa9\x0a"
5778 "\xb1\x95\x28\x86\x20\xe9\x17\x49"
5779 "\xa2\x29\x38\xaa\xa5\xe9\x6e\xf1"
5780 "\x19\x27\xc0\xd5\x2a\x22\xc3\x0b"
5781 "\xdb\x7c\x73\x10\xb9\xba\x89\x76"
5782 "\x54\xae\x7d\x71\xb3\x93\xf6\x32"
5783 "\xe6\x47\x43\x55\xac\xa0\x0d\xc2"
5784 "\x93\x27\x4a\x8e\x0e\x74\x15\xc7"
5785 "\x0b\x85\xd9\x0c\xa9\x30\x7a\x3e"
5786 "\xea\x8f\x85\x6d\x3a\x12\x4f\x72"
5787 "\x69\x58\x7a\x80\xbb\xb5\x97\xf3"
5788 "\xcf\x70\xd2\x5d\xdd\x4d\x21\x79"
5789 "\x54\x4d\xe4\x05\xe8\xbd\xc2\x62"
5790 "\xb1\x3b\x77\x1c\xd6\x5c\xf3\xa0"
5791 "\x79\x00\xa8\x6c\x29\xd9\x18\x24"
5792 "\x36\xa2\x46\xc0\x96\x65\x7f\xbd"
5793 "\x2a\xed\x36\x16\x0c\xaa\x9f\xf4"
5794 "\xc5\xb4\xe2\x12\xed\x69\xed\x4f"
5795 "\x26\x2c\x39\x52\x89\x98\xe7\x2c"
5796 "\x99\xa4\x9e\xa3\x9b\x99\x46\x7a"
5797 "\x3a\xdc\xa8\x59\xa3\xdb\xc3\x3b"
5798 "\x95\x0d\x3b\x09\x6e\xee\x83\x5d"
5799 "\x32\x4d\xed\xab\xfa\x98\x14\x4e"
5800 "\xc3\x15\x45\x53\x61\xc4\x93\xbd"
5801 "\x90\xf4\x99\x95\x4c\xe6\x76\x92"
5802 "\x29\x90\x46\x30\x92\x69\x7d\x13"
5803 "\xf2\xa5\xcd\x69\x49\x44\xb2\x0f"
5804 "\x63\x40\x36\x5f\x09\xe2\x78\xf8"
5805 "\x91\xe3\xe2\xfa\x10\xf7\xc8\x24"
5806 "\xa8\x89\x32\x5c\x37\x25\x1d\xb2"
5807 "\xea\x17\x8a\x0a\xa9\x64\xc3\x7c"
5808 "\x3c\x7c\xbd\xc6\x79\x34\xe7\xe2"
5809 "\x85\x8e\xbf\xf8\xde\x92\xa0\xae"
5810 "\x20\xc4\xf6\xbb\x1f\x38\x19\x0e"
5811 "\xe8\x79\x9c\xa1\x23\xe9\x54\x7e"
5812 "\x37\x2f\xe2\x94\x32\xaf\xa0\x23"
5813 "\x49\xe4\xc0\xb3\xac\x00\x8f\x36"
5814 "\x05\xc4\xa6\x96\xec\x05\x98\x4f"
5815 "\x96\x67\x57\x1f\x20\x86\x1b\x2d"
5816 "\x69\xe4\x29\x93\x66\x5f\xaf\x6b"
5817 "\x88\x26\x2c\x67\x02\x4b\x52\xd0"
5818 "\x83\x7a\x43\x1f\xc0\x71\x15\x25"
5819 "\x77\x65\x08\x60\x11\x76\x4c\x8d"
5820 "\xed\xa9\x27\xc6\xb1\x2a\x2c\x6a"
5821 "\x4a\x97\xf5\xc6\xb7\x70\x42\xd3"
5822 "\x03\xd1\x24\x95\xec\x6d\xab\x38"
5823 "\x72\xce\xe2\x8b\x33\xd7\x51\x09"
5824 "\xdc\x45\xe0\x09\x96\x32\xf3\xc4"
5825 "\x84\xdc\x73\x73\x2d\x1b\x11\x98"
5826 "\xc5\x0e\x69\x28\x94\xc7\xb5\x4d"
5827 "\xc8\x8a\xd0\xaa\x13\x2e\x18\x74"
5828 "\xdd\xd1\x1e\xf3\x90\xe8\xfc\x9a"
5829 "\x72\x4a\x0e\xd1\xe4\xfb\x0d\x96"
5830 "\xd1\x0c\x79\x85\x1b\x1c\xfe\xe1"
5831 "\x62\x8f\x7a\x73\x32\xab\xc8\x18"
5832 "\x69\xe3\x34\x30\xdf\x13\xa6\xe5"
5833 "\xe8\x0e\x67\x7f\x81\x11\xb4\x60"
5834 "\xc7\xbd\x79\x65\x50\xdc\xc4\x5b"
5835 "\xde\x39\xa4\x01\x72\x63\xf3\xd1"
5836 "\x64\x4e\xdf\xfc\x27\x92\x37\x0d"
5837 "\x57\xcd\x11\x4f\x11\x04\x8e\x1d"
5838 "\x16\xf7\xcd\x92\x9a\x99\x30\x14"
5839 "\xf1\x7c\x67\x1b\x1f\x41\x0b\xe8"
5840 "\x32\xe8\xb8\xc1\x4f\x54\x86\x4f"
5841 "\xe5\x79\x81\x73\xcd\x43\x59\x68"
5842 "\x73\x02\x3b\x78\x21\x72\x43\x00"
5843 "\x49\x17\xf7\x00\xaf\x68\x24\x53"
5844 "\x05\x0a\xc3\x33\xe0\x33\x3f\x69"
5845 "\xd2\x84\x2f\x0b\xed\xde\x04\xf4"
5846 "\x11\x94\x13\x69\x51\x09\x28\xde"
5847 "\x57\x5c\xef\xdc\x9a\x49\x1c\x17"
5848 "\x97\xf3\x96\xc1\x7f\x5d\x2e\x7d"
5849 "\x55\xb8\xb3\x02\x09\xb3\x1f\xe7"
5850 "\xc9\x8d\xa3\x36\x34\x8a\x77\x13"
5851 "\x30\x63\x4c\xa5\xcd\xc3\xe0\x7e"
5852 "\x05\xa1\x7b\x0c\xcb\x74\x47\x31"
5853 "\x62\x03\x43\xf1\x87\xb4\xb0\x85"
5854 "\x87\x8e\x4b\x25\xc7\xcf\xae\x4b"
5855 "\x36\x46\x3e\x62\xbc\x6f\xeb\x5f"
5856 "\x73\xac\xe6\x07\xee\xc1\xa1\xd6"
5857 "\xc4\xab\xc9\xd6\x89\x45\xe1\xf1"
5858 "\x04\x4e\x1a\x6f\xbb\x4f\x3a\xa3"
5859 "\xa0\xcb\xa3\x0a\xd8\x71\x35\x55"