xref: /linux/lib/crypto/fips-aes.h (revision fbdb43c0007b37e574fa0ca76afd13bed96db8f6)
160e9a0f5SEric Biggers /* SPDX-License-Identifier: GPL-2.0-or-later */
260e9a0f5SEric Biggers /* This file was generated by: gen-fips-testvecs.py */
360e9a0f5SEric Biggers /* clang-format off */
460e9a0f5SEric Biggers 
560e9a0f5SEric Biggers #include <linux/fips.h>
660e9a0f5SEric Biggers 
760e9a0f5SEric Biggers static const u8 fips_test_data[] __initconst __maybe_unused = {
860e9a0f5SEric Biggers 	0x66, 0x69, 0x70, 0x73, 0x20, 0x74, 0x65, 0x73,
960e9a0f5SEric Biggers 	0x74, 0x20, 0x64, 0x61, 0x74, 0x61, 0x00, 0x00,
1060e9a0f5SEric Biggers };
1160e9a0f5SEric Biggers 
12*fbdb43c0SEric Biggers static const u8 fips_test_ad[] __initconst __maybe_unused = {
13*fbdb43c0SEric Biggers 	0x66, 0x69, 0x70, 0x73, 0x20, 0x74, 0x65, 0x73,
14*fbdb43c0SEric Biggers 	0x74, 0x20, 0x61, 0x64, 0x00, 0x00, 0x00, 0x00,
15*fbdb43c0SEric Biggers };
16*fbdb43c0SEric Biggers 
17e967fa98SEric Biggers static const u8 fips_test_iv[] __initconst __maybe_unused = {
18e967fa98SEric Biggers 	0x66, 0x69, 0x70, 0x73, 0x20, 0x74, 0x65, 0x73,
19e967fa98SEric Biggers 	0x74, 0x20, 0x69, 0x76, 0x00, 0x00, 0x00, 0x00,
20e967fa98SEric Biggers };
21e967fa98SEric Biggers 
2260e9a0f5SEric Biggers static const u8 fips_test_key[] __initconst __maybe_unused = {
2360e9a0f5SEric Biggers 	0x66, 0x69, 0x70, 0x73, 0x20, 0x74, 0x65, 0x73,
2460e9a0f5SEric Biggers 	0x74, 0x20, 0x6b, 0x65, 0x79, 0x00, 0x00, 0x00,
2560e9a0f5SEric Biggers };
2660e9a0f5SEric Biggers 
27e967fa98SEric Biggers static const u8 fips_test_xts_key[] __initconst __maybe_unused = {
28e967fa98SEric Biggers 	0x6b, 0x65, 0x79, 0x31, 0x00, 0x00, 0x00, 0x00,
29e967fa98SEric Biggers 	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
30e967fa98SEric Biggers 	0x6b, 0x65, 0x79, 0x32, 0x00, 0x00, 0x00, 0x00,
31e967fa98SEric Biggers 	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
32e967fa98SEric Biggers };
33e967fa98SEric Biggers 
3460e9a0f5SEric Biggers static const u8 fips_test_aes_cmac_value[] __initconst __maybe_unused = {
3560e9a0f5SEric Biggers 	0xc5, 0x88, 0x28, 0x55, 0xd7, 0x2c, 0x00, 0xb6,
3660e9a0f5SEric Biggers 	0x6a, 0xa7, 0xfc, 0x82, 0x90, 0x81, 0xcf, 0x18,
3760e9a0f5SEric Biggers };
38e967fa98SEric Biggers 
39e967fa98SEric Biggers static const u8 fips_test_aes_ecb_ctext[] __initconst __maybe_unused = {
40e967fa98SEric Biggers 	0x47, 0x76, 0x48, 0xaf, 0x1b, 0xd8, 0x4c, 0xe6,
41e967fa98SEric Biggers 	0xb5, 0xa7, 0x20, 0x8d, 0x64, 0x88, 0xbc, 0x3f,
42e967fa98SEric Biggers };
43e967fa98SEric Biggers 
44e967fa98SEric Biggers static const u8 fips_test_aes_cbc_ctext[] __initconst __maybe_unused = {
45e967fa98SEric Biggers 	0xc8, 0x7d, 0x7c, 0x25, 0xba, 0x15, 0xf7, 0xe1,
46e967fa98SEric Biggers 	0x08, 0xa0, 0xd0, 0x7a, 0x20, 0x37, 0xaf, 0x5e,
47e967fa98SEric Biggers };
48e967fa98SEric Biggers 
49e967fa98SEric Biggers static const u8 fips_test_aes_cbc_cts_ctext[] __initconst __maybe_unused = {
50e967fa98SEric Biggers 	0x36, 0x8e, 0x37, 0xb4, 0x78, 0xe2, 0x88, 0x59,
51e967fa98SEric Biggers 	0xd5, 0xe8, 0x17, 0x65, 0x5c, 0xa1, 0x25, 0xe6,
52e967fa98SEric Biggers 	0xc8, 0x7d, 0x7c, 0x25, 0xba, 0x15, 0xf7, 0xe1,
53e967fa98SEric Biggers 	0x08, 0xa0, 0xd0, 0x7a, 0x20, 0x37, 0xaf, 0x5e,
54e967fa98SEric Biggers };
55e967fa98SEric Biggers 
56e967fa98SEric Biggers static const u8 fips_test_aes_ctr_ctext[] __initconst __maybe_unused = {
57e967fa98SEric Biggers 	0x95, 0xf4, 0xf4, 0x7a, 0xc8, 0xa2, 0x53, 0x73,
58e967fa98SEric Biggers 	0x53, 0x8f, 0x95, 0xfc, 0x18, 0xfe, 0x58, 0x2f,
59e967fa98SEric Biggers };
60e967fa98SEric Biggers 
61e967fa98SEric Biggers static const u8 fips_test_aes_xts_ctext[] __initconst __maybe_unused = {
62e967fa98SEric Biggers 	0xd4, 0x51, 0x7f, 0x01, 0x14, 0x91, 0x16, 0x29,
63e967fa98SEric Biggers 	0x26, 0xbe, 0xec, 0x9b, 0x90, 0xed, 0x59, 0x30,
64e967fa98SEric Biggers };
65*fbdb43c0SEric Biggers 
66*fbdb43c0SEric Biggers static const u8 fips_test_aes_gcm_ctext_and_tag[] __initconst __maybe_unused = {
67*fbdb43c0SEric Biggers 	0x12, 0x0c, 0x5d, 0x03, 0x32, 0x93, 0x13, 0x44,
68*fbdb43c0SEric Biggers 	0x06, 0x35, 0x26, 0x9d, 0xe0, 0xea, 0xbc, 0xe2,
69*fbdb43c0SEric Biggers 	0x30, 0xa9, 0xa4, 0x15, 0xc5, 0x3d, 0xb3, 0xf9,
70*fbdb43c0SEric Biggers 	0x30, 0x82, 0xdf, 0x9c, 0xd8, 0xc4, 0x3f, 0x2f,
71*fbdb43c0SEric Biggers };
72*fbdb43c0SEric Biggers 
73*fbdb43c0SEric Biggers static const u8 fips_test_aes_ccm_ctext_and_tag[] __initconst __maybe_unused = {
74*fbdb43c0SEric Biggers 	0x11, 0x8e, 0x01, 0xcb, 0xb5, 0x22, 0x6d, 0xb4,
75*fbdb43c0SEric Biggers 	0x66, 0x98, 0x97, 0x1d, 0x35, 0x53, 0x78, 0xdd,
76*fbdb43c0SEric Biggers 	0xd1, 0xc5, 0xff, 0xb6, 0x90, 0xcf, 0xb1, 0xf2,
77*fbdb43c0SEric Biggers 	0x87, 0x99, 0xd6, 0x1e, 0xd5, 0xd1, 0xed, 0x63,
78*fbdb43c0SEric Biggers };
79