Chapter 7 of the Handbook of Applied Cryptography by Alfred J. Menezes, Paul C. van Oorschot, and Scott A. Vanstone Highlights by James Pate Williams, Jr. BA, BS, MSwE, PhD

From a software engineer and computer scientist’s point of view, the key sections on block ciphers in this chapter of the Handbook are 7.4 DES, 7.5 FEAL, 7.6 IDEA, and 7.7 SAFER, RC5, … My original C implementations are probably from the era 1996 to 1998 of my life. In January and February of 2017 I translated the C code to C#. The results below are from the test application. I added some code on the triple-DES algorithm.

DES3 Chapter 7

Here are the numbers from the triple DES test.

NIST Incorrect Test String
Test String: The qufck brown fox jump

Encryption

5468652071756663 a826fd8ce53b855f
6b2062726f776e20 cce21c8112256fe6
666f78206a756d70 68d5c05dd9b6b900

Decryption

a826fd8ce53b855f 5468652071756663
cce21c8112256fe6 6b2062726f776e20
68d5c05dd9b6b900 666f78206a756d70

CBC Mode

Encryption

5468652071756663 38413d4ba2325cf1
6b2062726f776e20 141f707471ac2ced
666f78206a756d70 57db530f0123b5ac

Decryption

38413d4ba2325cf1 5468652071756663
141f707471ac2ced 6b2062726f776e20
57db530f0123b5ac 666f78206a756d70




My Correction Test String
Test String: The quick brown fox jump

Encryption

5468652071756963 1ccf23869d09333e
6b2062726f776e20 cce21c8112256fe6
666f78206a756d70 68d5c05dd9b6b900

Decryption

1ccf23869d09333e 5468652071756963
cce21c8112256fe6 6b2062726f776e20
68d5c05dd9b6b900 666f78206a756d70

CBC Mode

Encryption

5468652071756963 5ba523a59a510971
6b2062726f776e20 0da06400f058192a
666f78206a756d70 743dc4df1c592655

Decryption

5ba523a59a510971 5468652071756963
0da06400f058192a 6b2062726f776e20
743dc4df1c592655 666f78206a756d70

The DES test output is illustrated as follows:

DES Chapter 7

All of the numbers from DES (Date Encryption Standard) test are given below:

ECB Mode

Encryption

4e6f772069732074 3fa40e8a984d4815
68652074696d6520 6a271787ab8883f9
666f7220616c6c20 893d51ec4b563b53

Decryption

3fa40e8a984d4815 4e6f772069732074
6a271787ab8883f9 68652074696d6520
893d51ec4b563b53 666f7220616c6c20

CBC Mode

Encryption

4e6f772069732074 e5c7cdde872bf27c
68652074696d6520 43e934008c389c0f
666f7220616c6c20 683788499a7c05f6

Decryption

e5c7cdde872bf27c 4e6f772069732074
43e934008c389c0f 68652074696d6520
683788499a7c05f6 666f7220616c6c20

CFB 1-Bit Mode

Encryption

1234567890abcdef bd661569ae874e25 1
2468acf121579bdf 48b3169c1fac7a10 1
48d159e242af37bf 0a0143394c9959fe 0
91a2b3c4855e6f7e 6d52f55fd8b02711 0
234567890abcdefc 3a38debb3a2fa892 1
468acf121579bdf9 719b70bd3dce7acc 1
8d159e242af37bf3 81809c230adc0d23 0
1a2b3c4855e6f7e6 83d14a6da6926604 1
34567890abcdefcd 311e9dc8d6d52d8a 0
68acf121579bdf9a db47c7feb6fc4272 0
d159e242af37bf34 b73850afa3b8ed89 0
a2b3c4855e6f7e68 f5fb19dd00590800 1
4567890abcdefcd1 0f4351a9bbffe5a5 1
8acf121579bdf9a3 769593c58e20d41b 1
159e242af37bf347 0e949d3f3a293d64 1
2b3c4855e6f7e68f 921eb7ffeacd0db9 0
567890abcdefcd1e d2ad109c8895fb95 1
acf121579bdf9a3d 3c36317828a9bd04 1
59e242af37bf347b e7248586e7e4ecac 0
b3c4855e6f7e68f6 f9a58e16a7597c5e 0
67890abcdefcd1ec e939fdf63d177946 1
cf121579bdf9a3d9 f325eac046bad58d 0
9e242af37bf347b2 8385a6d975ffdbba 0
3c4855e6f7e68f64 70a54baceae7ba6b 1

Decryption

1234567890abcdef bd661569ae874e25 0
2468acf121579bdf 48b3169c1fac7a10 1
48d159e242af37bf 0a0143394c9959fe 0
91a2b3c4855e6f7e 6d52f55fd8b02711 0
234567890abcdefc 3a38debb3a2fa892 1
468acf121579bdf9 719b70bd3dce7acc 1
8d159e242af37bf3 81809c230adc0d23 1
1a2b3c4855e6f7e6 83d14a6da6926604 0
34567890abcdefcd 311e9dc8d6d52d8a 0
68acf121579bdf9a db47c7feb6fc4272 1
d159e242af37bf34 b73850afa3b8ed89 1
a2b3c4855e6f7e68 f5fb19dd00590800 0
4567890abcdefcd1 0f4351a9bbffe5a5 1
8acf121579bdf9a3 769593c58e20d41b 1
159e242af37bf347 0e949d3f3a293d64 1
2b3c4855e6f7e68f 921eb7ffeacd0db9 1
567890abcdefcd1e d2ad109c8895fb95 0
acf121579bdf9a3d 3c36317828a9bd04 1
59e242af37bf347b e7248586e7e4ecac 1
b3c4855e6f7e68f6 f9a58e16a7597c5e 1
67890abcdefcd1ec e939fdf63d177946 0
cf121579bdf9a3d9 f325eac046bad58d 1
9e242af37bf347b2 8385a6d975ffdbba 1
3c4855e6f7e68f64 70a54baceae7ba6b 1

CFB 8-Bit Mode

Encryption

1234567890abcdef bd661569ae874e25 f3
34567890abcdeff3 7039546f9a0f6330 1f
567890abcdeff31f ad1b78b0bb371be7 da
7890abcdeff31fda 27350b01d5ca31f7 07
90abcdeff31fda07 68863426e397685d 01
abcdeff31fda0701 6798240e8c6b685f 14
cdeff31fda070114 421feefb3f8ca64f 62
eff31fda07011462 9a169a9b50666575 ee
f31fda07011462ee 703b1799be9a5748 18
1fda07011462ee18 1a4aee195be70077 7f

Decryption

1234567890abcdef bd661569ae874e25 4e
34567890abcdeff3 7039546f9a0f6330 6f
567890abcdeff31f ad1b78b0bb371be7 77
7890abcdeff31fda 27350b01d5ca31f7 20
90abcdeff31fda07 68863426e397685d 69
abcdeff31fda0701 6798240e8c6b685f 73
cdeff31fda070114 421feefb3f8ca64f 20
eff31fda07011462 9a169a9b50666575 74
f31fda07011462ee 703b1799be9a5748 68
1fda07011462ee18 1a4aee195be70077 65

CFB 64-Bit Mode

Encryption

1234567890abcdef bd661569ae874e25 f3096249c7f46e51
f3096249c7f46e51 cefba3ef73ff92a4 a69e839b1a92f784
a69e839b1a92f784 65290313e8e2ca02 03467133898ea622

Decryption

1234567890abcdef bd661569ae874e25 4e6f772069732074
f3096249c7f46e51 cefba3ef73ff92a4 68652074696d6520
a69e839b1a92f784 65290313e8e2ca02 666f7220616c6c20

OFB ISO 10116 64-Bit Mode

Encryption

1234567890abcdef bd661569ae874e25 f3096249c7f46e51
bd661569ae874e25 5d976a504786581f 35f24a242eeb3d3f
5d976a504786581f 5b0229c3443694e3 3d6d5be3255af8c3

Decryption

1234567890abcdef bd661569ae874e25 4e6f772069732074
bd661569ae874e25 5d976a504786581f 68652074696d6520
5d976a504786581f 5b0229c3443694e3 666f7220616c6c20

OFB FIPS-81 1-Bit Mode

Encryption

1234567890abcdef bd661569ae874e25 1
2468acf121579bdf 48b3169c1fac7a10 1
48d159e242af37be 8879ea93c63d77a5 1
91a2b3c4855e6f7d 0d36e16101e86d61 0
234567890abcdefa e9eab8cfc00f4ac3 0
468acf121579bdf5 9d41640f97df7904 0
8d159e242af37beb 32f72fd1899eda45 1
1a2b3c4855e6f7d6 ca2a095d20f4e769 1
34567890abcdefad de869588355e1041 1
68acf121579bdf5b 11245e6a8720ddce 1
d159e242af37beb6 836b0be324094a97 0
a2b3c4855e6f7d6d c07714703b296a5a 1
4567890abcdefadb bf6380ecc196d599 0
8acf121579bdf5b7 96ed6856969aef13 0
159e242af37beb6f 3823feaa3d170085 1
2b3c4855e6f7d6de 2d57dc0c899d6700 1
567890abcdefadbc 2fe1c261c0e1a302 0
acf121579bdf5b78 778ad641faa047d0 1
59e242af37beb6f0 f66ae4359eec3755 0
b3c4855e6f7d6de1 cd0bda27e32a13da 0
67890abcdefadbc3 9f71f74488551801 1
cf121579bdf5b787 a62e89aa6b85be74 0
9e242af37beb6f0f 7b0b2e1de987b804 1
3c4855e6f7d6de1e 7f41b5ef07c3ea29 1

Decryption

1234567890abcdef bd661569ae874e25 0
2468acf121579bdf 48b3169c1fac7a10 1
48d159e242af37be 8879ea93c63d77a5 0
91a2b3c4855e6f7d 0d36e16101e86d61 0
234567890abcdefa e9eab8cfc00f4ac3 1
468acf121579bdf5 9d41640f97df7904 1
8d159e242af37beb 32f72fd1899eda45 1
1a2b3c4855e6f7d6 ca2a095d20f4e769 0
34567890abcdefad de869588355e1041 0
68acf121579bdf5b 11245e6a8720ddce 1
d159e242af37beb6 836b0be324094a97 1
a2b3c4855e6f7d6d c07714703b296a5a 0
4567890abcdefadb bf6380ecc196d599 1
8acf121579bdf5b7 96ed6856969aef13 1
159e242af37beb6f 3823feaa3d170085 1
2b3c4855e6f7d6de 2d57dc0c899d6700 1
567890abcdefadbc 2fe1c261c0e1a302 0
acf121579bdf5b78 778ad641faa047d0 1
59e242af37beb6f0 f66ae4359eec3755 1
b3c4855e6f7d6de1 cd0bda27e32a13da 1
67890abcdefadbc3 9f71f74488551801 0
cf121579bdf5b787 a62e89aa6b85be74 1
9e242af37beb6f0f 7b0b2e1de987b804 1
3c4855e6f7d6de1e 7f41b5ef07c3ea29 1

OFB 8-Bit FIPS-81 Mode

Encryption

1234567890abcdef bd661569ae874e25 f3
34567890abcdefbd 25e73b5d4cbd2359 4a
567890abcdefbd25 5f970070553623d0 28
7890abcdefbd255f 704ad48bf9eec8fa 50
90abcdefbd255f70 a0b1a091bb787553 c9
abcdefbd255f70a0 b58127681139ee7f c6
cdefbd255f70a0b5 694d556ef5806a65 49
efbd255f70a0b569 f1885324299132a2 85
bd255f70a0b569f1 be639ff6d7b74b04 d6
255f70a0b569f1be e17b6ae22b4bad65 84

Decryption

1234567890abcdef bd661569ae874e25 4e
34567890abcdefbd 25e73b5d4cbd2359 6f
567890abcdefbd25 5f970070553623d0 77
7890abcdefbd255f 704ad48bf9eec8fa 20
90abcdefbd255f70 a0b1a091bb787553 69
abcdefbd255f70a0 b58127681139ee7f 73
cdefbd255f70a0b5 694d556ef5806a65 20
efbd255f70a0b569 f1885324299132a2 74
bd255f70a0b569f1 be639ff6d7b74b04 68
255f70a0b569f1be e17b6ae22b4bad65 65

The results of Section 7.5 FEAL (Fast Data Encipherment Algorithm) in particular 7.99 Example page 262 are shown below:

FEAL Chapter 7

Here are the numbers of the 7.99 Example copied from the preceding application’s text box:

0xDF3B
0xCA36
0xF17C
0x1AEC
0x45A5
0xB9C7
0x26EB
0xAD25
0x8B2A
0xECB7
0xAC50
0x9D4C
0x22CD
0x479B
0xA8D5
0x0CB5
0xCEEF2C86 0xF2490752
0x00000000 0x00000000

Moving on to Section 7.6 IDEA (International Data Encryption Algorithm) a 64-bit block cipher:

IDEA Chapter 7

Again for clarity we reproduce the preceding numbers below see Table 7.12 page 265 and Table 7.13 page 266\:

1 0x0001 0x0002 0x0003 0x0004 0x0005 0x0006 0x00F0 0x00F5 0x010A 0x0105
2 0x0007 0x0008 0x0400 0x0600 0x0800 0x0A00 0x222F 0x21B5 0xF45E 0xE959
3 0x0C00 0x0E00 0x1000 0x0200 0x0010 0x0014 0x0F86 0x39BE 0x8EE8 0x1173
4 0x0018 0x001C 0x0020 0x0004 0x0008 0x000C 0x57DF 0xAC58 0xC65B 0xBA4D
5 0x2800 0x3000 0x3800 0x4000 0x0800 0x1000 0x8E81 0xBA9C 0xF77F 0x3A4A
6 0x1800 0x2000 0x0070 0x0080 0x0010 0x0020 0x6942 0x9409 0xE21B 0x1C64
7 0x0030 0x0040 0x0050 0x0060 0x0000 0x2000 0x99D0 0xC7F6 0x5331 0x620E
8 0x4000 0x6000 0x8000 0xA000 0xC000 0xE001 0xD98D 0xD331 0xD002 0x754C
9 0x0080 0x00C0 0x0100 0x0140 0x0000 0x0000 0xC614 0xD0C2 0xD431 0x9E6E
1 0xFE01 0xFF40 0xFF00 0x659A 0xC000 0xE001 0x0000 0xD331 0xD002 0x754C
2 0xFFFD 0x8000 0xA000 0xCCCC 0x0000 0x2000 0x0ECF 0x7ECD 0xCDFF 0x3475
3 0xA556 0xFFB0 0xFFC0 0x52AB 0x0010 0x0020 0x68EA 0xFFAF 0xD82A 0xD560
4 0x554B 0xFF90 0xE000 0xFE01 0x0800 0x1000 0x531C 0xA0AC 0x6FD6 0x90E9
5 0x332D 0xC800 0xD000 0xFFFD 0x0008 0x000C 0x3E10 0x1E89 0x4E8A 0x2626
6 0x4AAB 0xFFE0 0xFFE4 0xC001 0x0010 0x0014 0x11F2 0x5D0A 0xFC89 0x6B6A
7 0xAA96 0xF000 0xF200 0xFF81 0x0800 0x0A00 0x8177 0x4429 0xD97C 0xDF40
8 0x4925 0xFC00 0xFFF8 0x552B 0x0005 0x0006 0x35AB 0x6CE9 0x33CF 0x069D
9 0x0001 0xFFFE 0xFFFD 0xC001 0x0000 0x0000 0x35AB 0x33CD 0x6CE6 0xC1A8

Finally the results from Section 7.7 on SAFER, RC5, etc.

SAFER Chapter 7

See 7.114 Example page 269.

Encryption results
200 242 156 221 135 120 62 217 
Decryption results
 1 2 3 4 5 6 7 8

RC5 application results:

RC5 Chapter 7

See 7.118 Example page 270:

0x15E444EB 0x249831DA
0xB278C165 0xCC97D18

 

Chapter 6 of the Handbook of Applied Cryptography by Alfred J. Menezes, Paul C. van Oorschot, and Scott A. Vanstone Highlights by James Pate Williams, Jr. BA, BS, MSwE, PhD

In my opinion the key section of Chapter 6 of the Handbook is 6.4.1 that covers the SEAL (Software-optimized Encryption Algorithm) stream cipher. My original C implementation of SEAL was probably created in period 1996 to 1998. In February 2017, I created a C# implementation of the algorithm. Below is the output from the SEAL test.

SEAL Test

For clarity I reproduce the numbers above text box in the text area that follows:

0x5021758d 0xce577c11 0xfa5bd5dd 0x366d1b93 0x182cff72 0xac06d7c6 
0x2683ead8 0xfabe3573 0x82a10c96 0x48c483bd 0xca92285c 0x71fe84c0 
0xbd76b700 0x6fdcc20c 0x8dada151 0x4506dd64

0x92b404e5 0x56588ced 0x6c1acd4e 0xbf053f68 0x09f73a93 0xcd5f176a 
0xb863f14e 0x2b014a2f 0x4407e646 0x38665610 0x222d2f91 0x4d941a21 
0x3af3a4bf 0x021e4080 0x2a677d95 0x405c7db0 0x338e4b1e 0x19ccf158

0x907c1e3d 0xce71ef0a 0x48f559ef 0x2b7ab8bc 0x4557f4b8 0x033e9b05 
0x4fde0efa 0x1a845f94 0x38512c3b 0xd4b44591 0x53765dce 0x469efa02 
0xbd7dea87 0xfd036d87 0x53aa3013 0xec60e282 0x1eaef8f9 0x0b5a0949

0x37a00595 0x9b84c49c 0xa4be1e05 0x0673530f 0x0ac8389d 0xc5878ec8 
0xda6666d0 0x6da71328 0x1419bdf2 0xd258bebb 0xb6a42a4d 0x8a311a72 
0x547dfde9 0x668d50b5 0xba9e2567 0x413403c5 0x43120b5a 0xecf9d062

0x098045fc

The preceding numbers reproduce the 6.70 Example on pages 215-216 of the Handbook. The first block of hex digits is the R table. The second set of hex digits is the T table. The third set of hex digits is the word S[0], S[1], …, S[255]. The penultimate set of hex digits is  the part of the 1024 words of the y output vector. The last hex encoded number is the XOR of the 1024 y output vector numbers.

 

Advanced Encryption Standard and FIPS 197 by James Pate Williams, Jr. BA, BS, MSwE, PhD

Way back in the relative day of 2009 to 2010, I implemented and tested a rudimentary implementation in C# of the Advanced Encryption Standard (AES) using the document FIPS 197. Below are some screen shots and data from the test application.

AES Test 128 Bit Key Expansion

NIST Standard Test Data
Expansion of a 128-Bit Cipher Key

Cipher Key:
2b 7e 15 16 28 ae d2 a6 ab f7 15 88 9 cf 4f 3c

w[0] = 2b7e1516
w[1] = 28aed2a6
w[2] = abf71588
w[3] = 09cf4f3c

04 09cf4f3c cf4f3c09 8a84eb01 01000000 8b84eb01 2b7e1516 a0fafe17 
05 a0fafe17 28aed2a6 88542cb1 
06 88542cb1 abf71588 23a33939 
07 23a33939 09cf4f3c 2a6c7605 
08 2a6c7605 6c76052a 50386be5 02000000 52386be5 a0fafe17 f2c295f2 
09 f2c295f2 88542cb1 7a96b943 
10 7a96b943 23a33939 5935807a 
11 5935807a 2a6c7605 7359f67f 
12 7359f67f 59f67f73 cb42d28f 04000000 cf42d28f f2c295f2 3d80477d 
13 3d80477d 7a96b943 4716fe3e 
14 4716fe3e 5935807a 1e237e44 
15 1e237e44 7359f67f 6d7a883b 
16 6d7a883b 7a883b6d dac4e23c 08000000 d2c4e23c 3d80477d ef44a541 
17 ef44a541 4716fe3e a8525b7f 
18 a8525b7f 1e237e44 b671253b 
19 b671253b 6d7a883b db0bad00 
20 db0bad00 0bad00db 2b9563b9 10000000 3b9563b9 ef44a541 d4d1c6f8 
21 d4d1c6f8 a8525b7f 7c839d87 
22 7c839d87 b671253b caf2b8bc 
23 caf2b8bc db0bad00 11f915bc 
24 11f915bc f915bc11 99596582 20000000 b9596582 d4d1c6f8 6d88a37a 
25 6d88a37a 7c839d87 110b3efd 
26 110b3efd caf2b8bc dbf98641 
27 dbf98641 11f915bc ca0093fd 
28 ca0093fd 0093fdca 63dc5474 40000000 23dc5474 6d88a37a 4e54f70e 
29 4e54f70e 110b3efd 5f5fc9f3 
30 5f5fc9f3 dbf98641 84a64fb2 
31 84a64fb2 ca0093fd 4ea6dc4f 
32 4ea6dc4f a6dc4f4e 2486842f 80000000 a486842f 4e54f70e ead27321 
33 ead27321 5f5fc9f3 b58dbad2 
34 b58dbad2 84a64fb2 312bf560 
35 312bf560 4ea6dc4f 7f8d292f 
36 7f8d292f 8d292f7f 5da515d2 1b000000 46a515d2 ead27321 ac7766f3 
37 ac7766f3 b58dbad2 19fadc21 
38 19fadc21 312bf560 28d12941 
39 28d12941 7f8d292f 575c006e 
40 575c006e 5c006e57 4a639f5b 36000000 7c639f5b ac7766f3 d014f9a8 
41 d014f9a8 19fadc21 c9ee2589 
42 c9ee2589 28d12941 e13f0cc8 
43 e13f0cc8 575c006e b6630ca6

 

AES Test 192 Bit Key Expansion

NIST Standard Test Data
Expansion of a 192-Bit Cipher Key

Cipher Key:
8e 73 b0 f7 da 0e 64 52 c8 10 f3 2b 
80 90 79 e5 62 f8 ea d2 52 2c 6b 7b

w[0] = 8e73b0f7
w[1] = da0e6452
w[2] = c810f32b
w[3] = 809079e5
w[4] = 62f8ead2
w[5] = 522c6b7b

06 522c6b7b 2c6b7b52 717f2100 01000000 707f2100 8e73b0f7 fe0c91f7 
07 fe0c91f7 da0e6452 2402f5a5 
08 2402f5a5 c810f32b ec12068e 
09 ec12068e 809079e5 6c827f6b 
10 6c827f6b 62f8ead2 0e7a95b9 
11 0e7a95b9 522c6b7b 5c56fec2 
12 5c56fec2 56fec25c b1bb254a 02000000 b3bb254a fe0c91f7 4db7b4bd 
13 4db7b4bd 2402f5a5 69b54118 
14 69b54118 ec12068e 85a74796 
15 85a74796 6c827f6b e92538fd 
16 e92538fd 0e7a95b9 e75fad44 
17 e75fad44 5c56fec2 bb095386 
18 bb095386 095386bb 01ed44ea 04000000 05ed44ea 4db7b4bd 485af057 
19 485af057 69b54118 21efb14f 
20 21efb14f 85a74796 a448f6d9 
21 a448f6d9 e92538fd 4d6dce24 
22 4d6dce24 e75fad44 aa326360 
23 aa326360 bb095386 113b30e6 
24 113b30e6 3b30e611 e2048e82 08000000 ea048e82 485af057 a25e7ed5 
25 a25e7ed5 21efb14f 83b1cf9a 
26 83b1cf9a a448f6d9 27f93943 
27 27f93943 4d6dce24 6a94f767 
28 6a94f767 aa326360 c0a69407 
29 c0a69407 113b30e6 d19da4e1 
30 d19da4e1 9da4e1d1 5e49f83e 10000000 4e49f83e a25e7ed5 ec1786eb 
31 ec1786eb 83b1cf9a 6fa64971 
32 6fa64971 27f93943 485f7032 
33 485f7032 6a94f767 22cb8755 
34 22cb8755 c0a69407 e26d1352 
35 e26d1352 d19da4e1 33f0b7b3 
36 33f0b7b3 f0b7b333 8ca96dc3 20000000 aca96dc3 ec1786eb 40beeb28 
37 40beeb28 6fa64971 2f18a259 
38 2f18a259 485f7032 6747d26b 
39 6747d26b 22cb8755 458c553e 
40 458c553e e26d1352 a7e1466c 
41 a7e1466c 33f0b7b3 9411f1df 
42 9411f1df 11f1df94 82a19e22 40000000 c2a19e22 40beeb28 821f750a 
43 821f750a 2f18a259 ad07d753 
44 ad07d753 6747d26b ca400538 
45 ca400538 458c553e 8fcc5006 
46 8fcc5006 a7e1466c 282d166a 
47 282d166a 9411f1df bc3ce7b5 
48 bc3ce7b5 3ce7b5bc eb94d565 80000000 6b94d565 821f750a e98ba06f 
49 e98ba06f ad07d753 448c773c 
50 448c773c ca400538 8ecc7204 
51 8ecc7204 8fcc5006 01002202

AES Test 256 Bit Key Expansion

NIST Standard Test Data
Expansion of a 256-Bit Cipher Key

Cipher Key:
60 3d eb 10 15 ca 71 be 2b 73 ae f0 85 7d 77 81 
1f 35 2c 07 3b 61 08 d7 2d 98 10 a3 09 14 df f4

w[0] = 603deb10
w[1] = 15ca71be
w[2] = 2b73aef0
w[3] = 857d7781
w[4] = 1f352c07
w[5] = 3b6108d7
w[6] = 2d9810a3
w[7] = 0914dff4

08 0914dff4 14dff409 fa9ebf01 01000000 fb9ebf01 603deb10 9ba35411 
09 9ba35411 15ca71be 8e6925af 
10 8e6925af 2b73aef0 a51a8b5f 
11 a51a8b5f 857d7781 2067fcde 
12 2067fcde b785b01d 1f352c07 a8b09c1a 
13 a8b09c1a 3b6108d7 93d194cd 
14 93d194cd 2d9810a3 be49846e 
15 be49846e 0914dff4 b75d5b9a 
16 b75d5b9a 5d5b9ab7 4c39b8a9 02000000 4e39b8a9 9ba35411 d59aecb8 
17 d59aecb8 8e6925af 5bf3c917 
18 5bf3c917 a51a8b5f fee94248 
19 fee94248 2067fcde de8ebe96 
20 de8ebe96 1d19ae90 a8b09c1a b5a9328a 
21 b5a9328a 93d194cd 2678a647 
22 2678a647 be49846e 98312229 
23 98312229 b75d5b9a 2f6c79b3 
24 2f6c79b3 6c79b32f 50b66d15 04000000 54b66d15 d59aecb8 812c81ad 
25 812c81ad 5bf3c917 dadf48ba 
26 dadf48ba fee94248 24360af2 
27 24360af2 de8ebe96 fab8b464 
28 fab8b464 2d6c8d43 b5a9328a 98c5bfc9 
29 98c5bfc9 2678a647 bebd198e 
30 bebd198e 98312229 268c3ba7 
31 268c3ba7 2f6c79b3 09e04214 
32 09e04214 e0421409 e12cfa01 08000000 e92cfa01 812c81ad 68007bac 
33 68007bac dadf48ba b2df3316 
34 b2df3316 24360af2 96e939e4 
35 96e939e4 fab8b464 6c518d80 
36 6c518d80 50d15dcd 98c5bfc9 c814e204 
37 c814e204 bebd198e 76a9fb8a 
38 76a9fb8a 268c3ba7 5025c02d 
39 5025c02d 09e04214 59c58239 
40 59c58239 c5823959 a61312cb 10000000 b61312cb 68007bac de136967 
41 de136967 b2df3316 6ccc5a71 
42 6ccc5a71 96e939e4 fa256395 
43 fa256395 6c518d80 9674ee15 
44 9674ee15 90922859 c814e204 5886ca5d 
45 5886ca5d 76a9fb8a 2e2f31d7 
46 2e2f31d7 5025c02d 7e0af1fa 
47 7e0af1fa 59c58239 27cf73c3 
48 27cf73c3 cf73c327 8a8f2ecc 20000000 aa8f2ecc de136967 749c47ab 
49 749c47ab 6ccc5a71 18501dda 
50 18501dda fa256395 e2757e4f 
51 e2757e4f 9674ee15 7401905a 
52 7401905a 927c60be 5886ca5d cafaaae3 
53 cafaaae3 2e2f31d7 e4d59b34 
54 e4d59b34 7e0af1fa 9adf6ace 
55 9adf6ace 27cf73c3 bd10190d 
56 bd10190d 10190dbd cad4d77a 40000000 8ad4d77a 749c47ab fe4890d1 
57 fe4890d1 18501dda e6188d0b 
58 e6188d0b e2757e4f 046df344 
59 046df344 7401905a 706c631e

AES Test 128 Bit Detailed Example

NIST Standard Test Data
Cipher Detailed Example
FIPS 197 Pages 33 to 34

Input into Cipher
32 88 31 e0 
43 5a 31 37 
f6 30 98 07 
a8 8d a2 34

After AddRoundKey
19 a0 9a e9 
3d f4 c6 f8 
e3 e2 8d 48 
be 2b 2a 08

After SubBytes
d4 e0 b8 1e 
27 bf b4 41 
11 98 5d 52 
ae f1 e5 30

After ShiftRows
d4 e0 b8 1e 
bf b4 41 27 
5d 52 11 98 
30 ae f1 e5

After MixColumns
04 e0 48 28 
66 cb f8 06 
81 19 d3 26 
e5 9a 7a 4c

After AddRoundKey
a4 68 6b 02 
9c 9f 5b 6a 
7f 35 ea 50 
f2 2b 43 49

After SubBytes
49 45 7f 77 
de db 39 02 
d2 96 87 53 
89 f1 1a 3b

After ShiftRows
49 45 7f 77 
db 39 02 de 
87 53 d2 96 
3b 89 f1 1a

After MixColumns
58 1b db 1b 
4d 4b e7 6b 
ca 5a ca b0 
f1 ac a8 e5

After AddRoundKey
aa 61 82 68 
8f dd d2 32 
5f e3 4a 46 
03 ef d2 9a

After SubBytes
ac ef 13 45 
73 c1 b5 23 
cf 11 d6 5a 
7b df b5 b8

After ShiftRows
ac ef 13 45 
c1 b5 23 73 
d6 5a cf 11 
b8 7b df b5

After MixColumns
75 20 53 bb 
ec 0b c0 25 
09 63 cf d0 
93 33 7c dc

After AddRoundKey
48 67 4d d6 
6c 1d e3 5f 
4e 9d b1 58 
ee 0d 38 e7

After SubBytes
52 85 e3 f6 
50 a4 11 cf 
2f 5e c8 6a 
28 d7 07 94

After ShiftRows
52 85 e3 f6 
a4 11 cf 50 
c8 6a 2f 5e 
94 28 d7 07

After MixColumns
0f 60 6f 5e 
d6 31 c0 b3 
da 38 10 13 
a9 bf 6b 01

After AddRoundKey
e0 c8 d9 85 
92 63 b1 b8 
7f 63 35 be 
e8 c0 50 01

After SubBytes
e1 e8 35 97 
4f fb c8 6c 
d2 fb 96 ae 
9b ba 53 7c

After ShiftRows
e1 e8 35 97 
fb c8 6c 4f 
96 ae d2 fb 
7c 9b ba 53

After MixColumns
25 bd b6 4c 
d1 11 3a 4c 
a9 d1 33 c0 
ad 68 8e b0

After AddRoundKey
f1 c1 7c 5d 
00 92 c8 b5 
6f 4c 8b d5 
55 ef 32 0c

After SubBytes
a1 78 10 4c 
63 4f e8 d5 
a8 29 3d 03 
fc df 23 fe

After ShiftRows
a1 78 10 4c 
4f e8 d5 63 
3d 03 a8 29 
fe fc df 23

After MixColumns
4b 2c 33 37 
86 4a 9d d2 
8d 89 f4 18 
6d 80 e8 d8

After AddRoundKey
26 3d e8 fd 
0e 41 64 d2 
2e b7 72 8b 
17 7d a9 25

After SubBytes
f7 27 9b 54 
ab 83 43 b5 
31 a9 40 3d 
f0 ff d3 3f

After ShiftRows
f7 27 9b 54 
83 43 b5 ab 
40 3d 31 a9 
3f f0 ff d3

After MixColumns
14 46 27 34 
15 16 46 2a 
b5 15 56 d8 
bf ec d7 43

After AddRoundKey
5a 19 a3 7a 
41 49 e0 8c 
42 dc 19 04 
b1 1f 65 0c

After SubBytes
be d4 0a da 
83 3b e1 64 
2c 86 d4 f2 
c8 c0 4d fe

After ShiftRows
be d4 0a da 
3b e1 64 83 
d4 f2 2c 86 
fe c8 c0 4d

After MixColumns
00 b1 54 fa 
51 c8 76 1b 
2f 89 6d 99 
d1 ff cd ea

After AddRoundKey
ea 04 65 85 
83 45 5d 96 
5c 33 98 b0 
f0 2d ad c5

After SubBytes
87 f2 4d 97 
ec 6e 4c 90 
4a c3 46 e7 
8c d8 95 a6

After ShiftRows
87 f2 4d 97 
6e 4c 90 ec 
46 e7 4a c3 
a6 8c d8 95

After MixColumns
47 40 a3 4c 
37 d4 70 9f 
94 e4 3a 42 
ed a5 a6 bc

After AddRoundKey
eb 59 8b 1b 
40 2e a1 c3 
f2 38 13 42 
1e 84 e7 d2

After SubBytes
e9 cb 3d af 
09 31 32 2e 
89 07 7d 2c 
72 5f 94 b5

After ShiftRows
e9 cb 3d af 
31 32 2e 09 
7d 2c 89 07 
b5 72 5f 94

After AddRoundKey
39 02 dc 19 
25 dc 11 6a 
84 09 85 0b 
1d fb 97 32

NIST Standard Test Data
Inverse Cipher Detailed Example
FIPS 197 Pages 33 to 34

Input to Inverse Cipher
39 02 dc 19 
25 dc 11 6a 
84 09 85 0b 
1d fb 97 32

After AddRoundKey
e9 cb 3d af 
31 32 2e 09 
7d 2c 89 07 
b5 72 5f 94

After InvShiftRows
e9 cb 3d af 
09 31 32 2e 
89 07 7d 2c 
72 5f 94 b5

After InvSubBytes
eb 59 8b 1b 
40 2e a1 c3 
f2 38 13 42 
1e 84 e7 d2

After AddRoundKey
47 40 a3 4c 
37 d4 70 9f 
94 e4 3a 42 
ed a5 a6 bc

After InvMixColumns
87 f2 4d 97 
6e 4c 90 ec 
46 e7 4a c3 
a6 8c d8 95

After InvShiftRows
87 f2 4d 97 
ec 6e 4c 90 
4a c3 46 e7 
8c d8 95 a6

After InvSubBytes
ea 04 65 85 
83 45 5d 96 
5c 33 98 b0 
f0 2d ad c5

After AddRoundKey
00 b1 54 fa 
51 c8 76 1b 
2f 89 6d 99 
d1 ff cd ea

After InvMixColumns
be d4 0a da 
3b e1 64 83 
d4 f2 2c 86 
fe c8 c0 4d

After InvShiftRows
be d4 0a da 
83 3b e1 64 
2c 86 d4 f2 
c8 c0 4d fe

After InvSubBytes
5a 19 a3 7a 
41 49 e0 8c 
42 dc 19 04 
b1 1f 65 0c

After AddRoundKey
14 46 27 34 
15 16 46 2a 
b5 15 56 d8 
bf ec d7 43

After InvMixColumns
f7 27 9b 54 
83 43 b5 ab 
40 3d 31 a9 
3f f0 ff d3

After InvShiftRows
f7 27 9b 54 
ab 83 43 b5 
31 a9 40 3d 
f0 ff d3 3f

After InvSubBytes
26 3d e8 fd 
0e 41 64 d2 
2e b7 72 8b 
17 7d a9 25

After AddRoundKey
4b 2c 33 37 
86 4a 9d d2 
8d 89 f4 18 
6d 80 e8 d8

After InvMixColumns
a1 78 10 4c 
4f e8 d5 63 
3d 03 a8 29 
fe fc df 23

After InvShiftRows
a1 78 10 4c 
63 4f e8 d5 
a8 29 3d 03 
fc df 23 fe

After InvSubBytes
f1 c1 7c 5d 
00 92 c8 b5 
6f 4c 8b d5 
55 ef 32 0c

After AddRoundKey
25 bd b6 4c 
d1 11 3a 4c 
a9 d1 33 c0 
ad 68 8e b0

After InvMixColumns
e1 e8 35 97 
fb c8 6c 4f 
96 ae d2 fb 
7c 9b ba 53

After InvShiftRows
e1 e8 35 97 
4f fb c8 6c 
d2 fb 96 ae 
9b ba 53 7c

After InvSubBytes
e0 c8 d9 85 
92 63 b1 b8 
7f 63 35 be 
e8 c0 50 01

After AddRoundKey
0f 60 6f 5e 
d6 31 c0 b3 
da 38 10 13 
a9 bf 6b 01

After InvMixColumns
52 85 e3 f6 
a4 11 cf 50 
c8 6a 2f 5e 
94 28 d7 07

After InvShiftRows
52 85 e3 f6 
50 a4 11 cf 
2f 5e c8 6a 
28 d7 07 94

After InvSubBytes
48 67 4d d6 
6c 1d e3 5f 
4e 9d b1 58 
ee 0d 38 e7

After AddRoundKey
75 20 53 bb 
ec 0b c0 25 
09 63 cf d0 
93 33 7c dc

After InvMixColumns
ac ef 13 45 
c1 b5 23 73 
d6 5a cf 11 
b8 7b df b5

After InvShiftRows
ac ef 13 45 
73 c1 b5 23 
cf 11 d6 5a 
7b df b5 b8

After InvSubBytes
aa 61 82 68 
8f dd d2 32 
5f e3 4a 46 
03 ef d2 9a

After AddRoundKey
58 1b db 1b 
4d 4b e7 6b 
ca 5a ca b0 
f1 ac a8 e5

After InvMixColumns
49 45 7f 77 
db 39 02 de 
87 53 d2 96 
3b 89 f1 1a

After InvShiftRows
49 45 7f 77 
de db 39 02 
d2 96 87 53 
89 f1 1a 3b

After InvSubBytes
a4 68 6b 02 
9c 9f 5b 6a 
7f 35 ea 50 
f2 2b 43 49

After AddRoundKey
04 e0 48 28 
66 cb f8 06 
81 19 d3 26 
e5 9a 7a 4c

After InvMixColumns
d4 e0 b8 1e 
bf b4 41 27 
5d 52 11 98 
30 ae f1 e5

After InvShiftRows
d4 e0 b8 1e 
27 bf b4 41 
11 98 5d 52 
ae f1 e5 30

After InvSubBytes
19 a0 9a e9 
3d f4 c6 f8 
e3 e2 8d 48 
be 2b 2a 08

After AddRoundKey
32 88 31 e0 
43 5a 31 37 
f6 30 98 07 
a8 8d a2 34

AES Test 128 Bit Test Vector

NIST Standard Test Data
AES-128 (Nk = 4, Nr = 10)
Test Vector
FIPS 197 Pages 35 to 36

Cipher (Encrypt)

round[00].input: 00112233445566778899aabbccddeeff
round[00].k_sch: 000102030405060708090a0b0c0d0e0f
round[00].start: 00102030405060708090a0b0c0d0e0f0
round[01].s_box: 63cab7040953d051cd60e0e7ba70e18c
round[01].s_row: 6353e08c0960e104cd70b751bacad0e7
round[01].m_col: 5f72641557f5bc92f7be3b291db9f91a
round[01].k_sch: d6aa74fdd2af72fadaa678f1d6ab76fe
round[01].start: 89d810e8855ace682d1843d8cb128fe4
round[02].s_box: a761ca9b97be8b45d8ad1a611fc97369
round[02].s_row: a7be1a6997ad739bd8c9ca451f618b61
round[02].m_col: ff87968431d86a51645151fa773ad009
round[02].k_sch: b692cf0b643dbdf1be9bc5006830b3fe
round[02].start: 4915598f55e5d7a0daca94fa1f0a63f7
round[03].s_box: 3b59cb73fcd90ee05774222dc067fb68
round[03].s_row: 3bd92268fc74fb735767cbe0c0590e2d
round[03].m_col: 4c9c1e66f771f0762c3f868e534df256
round[03].k_sch: b6ff744ed2c2c9bf6c590cbf0469bf41
round[03].start: fa636a2825b339c940668a3157244d17
round[04].s_box: 2dfb02343f6d12dd09337ec75b36e3f0
round[04].s_row: 2d6d7ef03f33e334093602dd5bfb12c7
round[04].m_col: 6385b79ffc538df997be478e7547d691
round[04].k_sch: 47f7f7bc95353e03f96c32bcfd058dfd
round[04].start: 247240236966b3fa6ed2753288425b6c
round[05].s_box: 36400926f9336d2d9fb59d23c42c3950
round[05].s_row: 36339d50f9b539269f2c092dc4406d23
round[05].m_col: f4bcd45432e554d075f1d6c51dd03b3c
round[05].k_sch: 3caaa3e8a99f9deb50f3af57adf622aa
round[05].start: c81677bc9b7ac93b25027992b0261996
round[06].s_box: e847f56514dadde23f77b64fe7f7d490
round[06].s_row: e8dab6901477d4653ff7f5e2e747dd4f
round[06].m_col: 9816ee7400f87f556b2c049c8e5ad036
round[06].k_sch: 5e390f7df7a69296a7553dc10aa31f6b
round[06].start: c62fe109f75eedc3cc79395d84f9cf5d
round[07].s_box: b415f8016858552e4bb6124c5f998a4c
round[07].s_row: b458124c68b68a014b99f82e5f15554c
round[07].m_col: c57e1c159a9bd286f05f4be098c63439
round[07].k_sch: 14f9701ae35fe28c440adf4d4ea9c026
round[07].start: d1876c0f79c4300ab45594add66ff41f
round[08].s_box: 3e175076b61c04678dfc2295f6a8bfc0
round[08].s_row: 3e1c22c0b6fcbf768da85067f6170495
round[08].m_col: baa03de7a1f9b56ed5512cba5f414d23
round[08].k_sch: 47438735a41c65b9e016baf4aebf7ad2
round[08].start: fde3bad205e5d0d73547964ef1fe37f1
round[09].s_box: 5411f4b56bd9700e96a0902fa1bb9aa1
round[09].s_row: 54d990a16ba09ab596bbf40ea111702f
round[09].m_col: e9f74eec023020f61bf2ccf2353c21c7
round[09].k_sch: 549932d1f08557681093ed9cbe2c974e
round[09].start: bd6e7c3df2b5779e0b61216e8b10b689
round[10].s_box: 7a9f102789d5f50b2beffd9f3dca4ea7
round[10].s_row: 7ad5fda789ef4e272bca100b3d9ff59f
round[10].k_sch: 13111d7fe3944a17f307a78b4d2b30c5
round[10].output: 69c4e0d86a7b0430d8cdb78070b4c55a

AES-128 (Nk = 4, Nr = 10)
Test Vector
FIPS 197 Pages 36 to 37

Cipher (Decrypt)

round[10].start: 69c4e0d86a7b0430d8cdb78070b4c55a
round[10].k_sch: 13111d7fe3944a17f307a78b4d2b30c5
round[09].s_row: 7a9f102789d5f50b2beffd9f3dca4ea7
round[09].s_box: bd6e7c3df2b5779e0b61216e8b10b689
round[09].k_sch: 549932d1f08557681093ed9cbe2c974e
round[09].start: 54d990a16ba09ab596bbf40ea111702f
round[08].s_row: 5411f4b56bd9700e96a0902fa1bb9aa1
round[08].s_box: fde3bad205e5d0d73547964ef1fe37f1
round[08].k_sch: 47438735a41c65b9e016baf4aebf7ad2
round[08].start: 3e1c22c0b6fcbf768da85067f6170495
round[07].s_row: 3e175076b61c04678dfc2295f6a8bfc0
round[07].s_box: d1876c0f79c4300ab45594add66ff41f
round[07].k_sch: 14f9701ae35fe28c440adf4d4ea9c026
round[07].start: b458124c68b68a014b99f82e5f15554c
round[06].s_row: b415f8016858552e4bb6124c5f998a4c
round[06].s_box: c62fe109f75eedc3cc79395d84f9cf5d
round[06].k_sch: 5e390f7df7a69296a7553dc10aa31f6b
round[06].start: e8dab6901477d4653ff7f5e2e747dd4f
round[05].s_row: e847f56514dadde23f77b64fe7f7d490
round[05].s_box: c81677bc9b7ac93b25027992b0261996
round[05].k_sch: 3caaa3e8a99f9deb50f3af57adf622aa
round[05].start: 36339d50f9b539269f2c092dc4406d23
round[04].s_row: 36400926f9336d2d9fb59d23c42c3950
round[04].s_box: 247240236966b3fa6ed2753288425b6c
round[04].k_sch: 47f7f7bc95353e03f96c32bcfd058dfd
round[04].start: 2d6d7ef03f33e334093602dd5bfb12c7
round[03].s_row: 2dfb02343f6d12dd09337ec75b36e3f0
round[03].s_box: fa636a2825b339c940668a3157244d17
round[03].k_sch: b6ff744ed2c2c9bf6c590cbf0469bf41
round[03].start: 3bd92268fc74fb735767cbe0c0590e2d
round[02].s_row: 3b59cb73fcd90ee05774222dc067fb68
round[02].s_box: 4915598f55e5d7a0daca94fa1f0a63f7
round[02].k_sch: b692cf0b643dbdf1be9bc5006830b3fe
round[02].start: a7be1a6997ad739bd8c9ca451f618b61
round[01].s_row: a761ca9b97be8b45d8ad1a611fc97369
round[01].s_box: 89d810e8855ace682d1843d8cb128fe4
round[01].k_sch: d6aa74fdd2af72fadaa678f1d6ab76fe
round[01].start: 6353e08c0960e104cd70b751bacad0e7
round[00].s_row: 63cab7040953d051cd60e0e7ba70e18c
round[00].s_box: 00102030405060708090a0b0c0d0e0f0
round[00].k_sch: 000102030405060708090a0b0c0d0e0f
round[00].output: 00112233445566778899aabbccddeeff

AES Test 192 Bit Test Vector.JPG

NIST Standard Test Data
AES-192 (Nk = 6, Nr = 12)
Test Vector
FIPS 197 Pages 38 to 39

Cipher (Encrypt)

round[00].input: 00112233445566778899aabbccddeeff
round[00].k_sch: 000102030405060708090a0b0c0d0e0f
round[00].start: 00102030405060708090a0b0c0d0e0f0
round[01].s_box: 63cab7040953d051cd60e0e7ba70e18c
round[01].s_row: 6353e08c0960e104cd70b751bacad0e7
round[01].m_col: 5f72641557f5bc92f7be3b291db9f91a
round[01].k_sch: 10111213141516175846f2f95c43f4fe
round[01].start: 4f63760643e0aa85aff8c9d041fa0de4
round[02].s_box: 84fb386f1ae1ac977941dd70832dd769
round[02].s_row: 84e1dd691a41d76f792d389783fbac70
round[02].m_col: 9f487f794f955f662afc86abd7f1ab29
round[02].k_sch: 544afef55847f0fa4856e2e95c43f4fe
round[02].start: cb02818c17d2af9c62aa64428bb25fd7
round[03].s_box: 1f770c64f0b579deaaac432c3d37cf0e
round[03].s_row: 1fb5430ef0accf64aa370cde3d77792c
round[03].m_col: b7a53ecbbf9d75a0c40efc79b674cc11
round[03].k_sch: 40f949b31cbabd4d48f043b810b7b342
round[03].start: f75c7778a327c8ed8cfebfc1a6c37f53
round[04].s_box: 684af5bc0acce85564bb0878242ed2ed
round[04].s_row: 68cc08ed0abbd2bc642ef555244ae878
round[04].m_col: 7a1e98bdacb6d1141a6944dd06eb2d3e
round[04].k_sch: 58e151ab04a2a5557effb5416245080c
round[04].start: 22ffc916a81474416496f19c64ae2532
round[05].s_box: 9316dd47c2fa92834390a1de43e43f23
round[05].s_row: 93faa123c2903f4743e4dd83431692de
round[05].m_col: aaa755b34cffe57cef6f98e1f01c13e6
round[05].k_sch: 2ab54bb43a02f8f662e3a95d66410c08
round[05].start: 80121e0776fd1d8a8d8c31bc965d1fee
round[06].s_box: cdc972c53854a47e5d64c765904cc028
round[06].s_row: cd54c7283864c0c55d4c727e90c9a465
round[06].m_col: 921f748fd96e937d622d7725ba8ba50c
round[06].k_sch: f501857297448d7ebdf1c6ca87f33e3c
round[06].start: 671ef1fd4e2a1e03dfdcb1ef3d789b30
round[07].s_box: 8572a1542fe5727b9e86c8df27bc1404
round[07].s_row: 85e5c8042f8614549ebca17b277272df
round[07].m_col: e913e7b18f507d4b227ef652758acbcc
round[07].k_sch: e510976183519b6934157c9ea351f1e0
round[07].start: 0c0370d00c01e622166b8accd6db3a2c
round[08].s_box: fe7b5170fe7c8e93477f7e4bf6b98071
round[08].s_row: fe7c7e71fe7f807047b95193f67b8e4b
round[08].m_col: 6cf5edf996eb0a069c4ef21cbfc25762
round[08].k_sch: 1ea0372a995309167c439e77ff12051e
round[08].start: 7255dad30fb80310e00d6c6b40d0527c
round[09].s_box: 40fc5766766c7bcae1d7507f09700010
round[09].s_row: 406c501076d70066e17057ca09fc7b7f
round[09].m_col: 7478bcdce8a50b81d4327a9009188262
round[09].k_sch: dd7e0e887e2fff68608fc842f9dcc154
round[09].start: a906b254968af4e9b4bdb2d2f0c44336
round[10].s_box: d36f3720907ebf1e8d7a37b58c1c1a05
round[10].s_row: d37e3705907a1a208d1c371e8c6fbfb5
round[10].m_col: 0d73cc2d8f6abe8b0cf2dd9bb83d422e
round[10].k_sch: 859f5f237a8d5a3dc0c02952beefd63a
round[10].start: 88ec930ef5e7e4b6cc32f4c906d29414
round[11].s_box: c4cedcabe694694e4b23bfdd6fb522fa
round[11].s_row: c494bffae62322ab4bb5dc4e6fce69dd
round[11].m_col: 71d720933b6d677dc00b8f28238e0fb7
round[11].k_sch: de601e7827bcdf2ca223800fd8aeda32
round[11].start: afb73eeb1cd1b85162280f27fb20d585
round[12].s_box: 79a9b2e99c3e6cd1aa3476cc0fb70397
round[12].s_row: 793e76979c3403e9aab7b2d10fa96ccc
round[12].k_sch: a4970a331a78dc09c418c271e3a41d5d
round[12].output: dda97ca4864cdfe06eaf70a0ec0d7191

AES-192 (Nk = 6, Nr = 12)
Test Vector
FIPS 197 Pages 39 to 40

Inverse Cipher (Decrypt)

round[12].start: dda97ca4864cdfe06eaf70a0ec0d7191
round[12].k_sch: a4970a331a78dc09c418c271e3a41d5d
round[11].s_row: 79a9b2e99c3e6cd1aa3476cc0fb70397
round[11].s_box: afb73eeb1cd1b85162280f27fb20d585
round[11].k_sch: de601e7827bcdf2ca223800fd8aeda32
round[11].start: c494bffae62322ab4bb5dc4e6fce69dd
round[10].s_row: c4cedcabe694694e4b23bfdd6fb522fa
round[10].s_box: 88ec930ef5e7e4b6cc32f4c906d29414
round[10].k_sch: 859f5f237a8d5a3dc0c02952beefd63a
round[10].start: d37e3705907a1a208d1c371e8c6fbfb5
round[09].s_row: d36f3720907ebf1e8d7a37b58c1c1a05
round[09].s_box: a906b254968af4e9b4bdb2d2f0c44336
round[09].k_sch: dd7e0e887e2fff68608fc842f9dcc154
round[09].start: 406c501076d70066e17057ca09fc7b7f
round[08].s_row: 40fc5766766c7bcae1d7507f09700010
round[08].s_box: 7255dad30fb80310e00d6c6b40d0527c
round[08].k_sch: 1ea0372a995309167c439e77ff12051e
round[08].start: fe7c7e71fe7f807047b95193f67b8e4b
round[07].s_row: fe7b5170fe7c8e93477f7e4bf6b98071
round[07].s_box: 0c0370d00c01e622166b8accd6db3a2c
round[07].k_sch: e510976183519b6934157c9ea351f1e0
round[07].start: 85e5c8042f8614549ebca17b277272df
round[06].s_row: 8572a1542fe5727b9e86c8df27bc1404
round[06].s_box: 671ef1fd4e2a1e03dfdcb1ef3d789b30
round[06].k_sch: f501857297448d7ebdf1c6ca87f33e3c
round[06].start: cd54c7283864c0c55d4c727e90c9a465
round[05].s_row: cdc972c53854a47e5d64c765904cc028
round[05].s_box: 80121e0776fd1d8a8d8c31bc965d1fee
round[05].k_sch: 2ab54bb43a02f8f662e3a95d66410c08
round[05].start: 93faa123c2903f4743e4dd83431692de
round[04].s_row: 9316dd47c2fa92834390a1de43e43f23
round[04].s_box: 22ffc916a81474416496f19c64ae2532
round[04].k_sch: 58e151ab04a2a5557effb5416245080c
round[04].start: 68cc08ed0abbd2bc642ef555244ae878
round[03].s_row: 684af5bc0acce85564bb0878242ed2ed
round[03].s_box: f75c7778a327c8ed8cfebfc1a6c37f53
round[03].k_sch: 40f949b31cbabd4d48f043b810b7b342
round[03].start: 1fb5430ef0accf64aa370cde3d77792c
round[02].s_row: 1f770c64f0b579deaaac432c3d37cf0e
round[02].s_box: cb02818c17d2af9c62aa64428bb25fd7
round[02].k_sch: 544afef55847f0fa4856e2e95c43f4fe
round[02].start: 84e1dd691a41d76f792d389783fbac70
round[01].s_row: 84fb386f1ae1ac977941dd70832dd769
round[01].s_box: 4f63760643e0aa85aff8c9d041fa0de4
round[01].k_sch: 10111213141516175846f2f95c43f4fe
round[01].start: 6353e08c0960e104cd70b751bacad0e7
round[00].s_row: 63cab7040953d051cd60e0e7ba70e18c
round[00].s_box: 00102030405060708090a0b0c0d0e0f0
round[00].k_sch: 000102030405060708090a0b0c0d0e0f
round[00].output: 00112233445566778899aabbccddeeff

AES Test 256 Bit Test Vector

NIST Standard Test Data
AES-256 (Nk = 8, Nr = 14)
Test Vector
FIPS 197 Pages 42 to 43

Cipher (Encrypt)

round[00].input: 00112233445566778899aabbccddeeff
round[00].k_sch: 000102030405060708090a0b0c0d0e0f
round[00].start: 00102030405060708090a0b0c0d0e0f0
round[01].s_box: 63cab7040953d051cd60e0e7ba70e18c
round[01].s_row: 6353e08c0960e104cd70b751bacad0e7
round[01].m_col: 5f72641557f5bc92f7be3b291db9f91a
round[01].k_sch: 101112131415161718191a1b1c1d1e1f
round[01].start: 4f63760643e0aa85efa7213201a4e705
round[02].s_box: 84fb386f1ae1ac97df5cfd237c49946b
round[02].s_row: 84e1fd6b1a5c946fdf4938977cfbac23
round[02].m_col: bd2a395d2b6ac438d192443e615da195
round[02].k_sch: a573c29fa176c498a97fce93a572c09c
round[02].start: 1859fbc28a1c00a078ed8aadc42f6109
round[03].s_box: adcb0f257e9c63e0bc557e951c15ef01
round[03].s_row: ad9c7e017e55ef25bc150fe01ccb6395
round[03].m_col: 810dce0cc9db8172b3678c1e88a1b5bd
round[03].k_sch: 1651a8cd0244beda1a5da4c10640bade
round[03].start: 975c66c1cb9f3fa8a93a28df8ee10f63
round[04].s_box: 884a33781fdb75c2d380349e19f876fb
round[04].s_row: 88db34fb1f807678d3f833c2194a759e
round[04].m_col: b2822d81abe6fb275faf103a078c0033
round[04].k_sch: ae87dff00ff11b68a68ed5fb03fc1567
round[04].start: 1c05f271a417e04ff921c5c104701554
round[05].s_box: 9c6b89a349f0e18499fda678f2515920
round[05].s_row: 9cf0a62049fd59a399518984f26be178
round[05].m_col: aeb65ba974e0f822d73f567bdb64c877
round[05].k_sch: 6de1f1486fa54f9275f8eb5373b8518d
round[05].start: c357aae11b45b7b0a2c7bd28a8dc99fa
round[06].s_box: 2e5bacf8af6ea9e73ac67a34c286ee2d
round[06].s_row: 2e6e7a2dafc6eef83a86ace7c25ba934
round[06].m_col: b951c33c02e9bd29ae25cdb1efa08cc7
round[06].k_sch: c656827fc9a799176f294cec6cd5598b
round[06].start: 7f074143cb4e243ec10c815d8375d54c
round[07].s_box: d2c5831a1f2f36b278fe0c4cec9d0329
round[07].s_row: d22f0c291ffe031a789d83b2ecc5364c
round[07].m_col: ebb19e1c3ee7c9e87d7535e9ed6b9144
round[07].k_sch: 3de23a75524775e727bf9eb45407cf39
round[07].start: d653a4696ca0bc0f5acaab5db96c5e7d
round[08].s_box: f6ed49f950e06576be74624c565058ff
round[08].s_row: f6e062ff507458f9be50497656ed654c
round[08].m_col: 5174c8669da98435a8b3e62ca974a5ea
round[08].k_sch: 0bdc905fc27b0948ad5245a4c1871c2f
round[08].start: 5aa858395fd28d7d05e1a38868f3b9c5
round[09].s_box: bec26a12cfb55dff6bf80ac4450d56a6
round[09].s_row: beb50aa6cff856126b0d6aff45c25dc4
round[09].m_col: 0f77ee31d2ccadc05430a83f4ef96ac3
round[09].k_sch: 45f5a66017b2d387300d4d33640a820a
round[09].start: 4a824851c57e7e47643de50c2af3e8c9
round[10].s_box: d61352d1a6f3f3a04327d9fee50d9bdd
round[10].s_row: d6f3d9dda6279bd1430d52a0e513f3fe
round[10].m_col: bd86f0ea748fc4f4630f11c1e9331233
round[10].k_sch: 7ccff71cbeb4fe5413e6bbf0d261a7df
round[10].start: c14907f6ca3b3aa070e9aa313b52b5ec
round[11].s_box: 783bc54274e280e0511eacc7e200d5ce
round[11].s_row: 78e2acce741ed5425100c5e0e23b80c7
round[11].m_col: af8690415d6e1dd387e5fbedd5c89013
round[11].k_sch: f01afafee7a82979d7a5644ab3afe640
round[11].start: 5f9c6abfbac634aa50409fa766677653
round[12].s_box: cfde0208f4b418ac5309db5c338538ed
round[12].s_row: cfb4dbedf4093808538502ac33de185c
round[12].m_col: 7427fae4d8a695269ce83d315be0392b
round[12].k_sch: 2541fe719bf500258813bbd55a721c0a
round[12].start: 516604954353950314fb86e401922521
round[13].s_box: d133f22a1aed2a7bfa0f44697c4f3ffd
round[13].s_row: d1ed44fd1a0f3f2afa4ff27b7c332a69
round[13].m_col: 2c21a820306f154ab712c75eee0da04f
round[13].k_sch: 4e5a6699a9f24fe07e572baacdf8cdea
round[13].start: 627bceb9999d5aaac945ecf423f56da5
round[14].s_box: aa218b56ee5ebeacdd6ecebf26e63c06
round[14].s_row: aa5ece06ee6e3c56dde68bac2621bebf
round[14].k_sch: 24fc79ccbf0979e9371ac23c6d68de36
round[14].output: 8ea2b7ca516745bfeafc49904b496089

AES-256 (Nk = 8, Nr = 14)
Test Vector
FIPS 197 Pages 43 to 44

Inverse Cipher (Decrypt)

round[14].start: 8ea2b7ca516745bfeafc49904b496089
round[14].k_sch: 24fc79ccbf0979e9371ac23c6d68de36
round[13].s_row: aa218b56ee5ebeacdd6ecebf26e63c06
round[13].s_box: 627bceb9999d5aaac945ecf423f56da5
round[13].k_sch: 4e5a6699a9f24fe07e572baacdf8cdea
round[13].start: d1ed44fd1a0f3f2afa4ff27b7c332a69
round[12].s_row: d133f22a1aed2a7bfa0f44697c4f3ffd
round[12].s_box: 516604954353950314fb86e401922521
round[12].k_sch: 2541fe719bf500258813bbd55a721c0a
round[12].start: cfb4dbedf4093808538502ac33de185c
round[11].s_row: cfde0208f4b418ac5309db5c338538ed
round[11].s_box: 5f9c6abfbac634aa50409fa766677653
round[11].k_sch: f01afafee7a82979d7a5644ab3afe640
round[11].start: 78e2acce741ed5425100c5e0e23b80c7
round[10].s_row: 783bc54274e280e0511eacc7e200d5ce
round[10].s_box: c14907f6ca3b3aa070e9aa313b52b5ec
round[10].k_sch: 7ccff71cbeb4fe5413e6bbf0d261a7df
round[10].start: d6f3d9dda6279bd1430d52a0e513f3fe
round[09].s_row: d61352d1a6f3f3a04327d9fee50d9bdd
round[09].s_box: 4a824851c57e7e47643de50c2af3e8c9
round[09].k_sch: 45f5a66017b2d387300d4d33640a820a
round[09].start: beb50aa6cff856126b0d6aff45c25dc4
round[08].s_row: bec26a12cfb55dff6bf80ac4450d56a6
round[08].s_box: 5aa858395fd28d7d05e1a38868f3b9c5
round[08].k_sch: 0bdc905fc27b0948ad5245a4c1871c2f
round[08].start: f6e062ff507458f9be50497656ed654c
round[07].s_row: f6ed49f950e06576be74624c565058ff
round[07].s_box: d653a4696ca0bc0f5acaab5db96c5e7d
round[07].k_sch: 3de23a75524775e727bf9eb45407cf39
round[07].start: d22f0c291ffe031a789d83b2ecc5364c
round[06].s_row: d2c5831a1f2f36b278fe0c4cec9d0329
round[06].s_box: 7f074143cb4e243ec10c815d8375d54c
round[06].k_sch: c656827fc9a799176f294cec6cd5598b
round[06].start: 2e6e7a2dafc6eef83a86ace7c25ba934
round[05].s_row: 2e5bacf8af6ea9e73ac67a34c286ee2d
round[05].s_box: c357aae11b45b7b0a2c7bd28a8dc99fa
round[05].k_sch: 6de1f1486fa54f9275f8eb5373b8518d
round[05].start: 9cf0a62049fd59a399518984f26be178
round[04].s_row: 9c6b89a349f0e18499fda678f2515920
round[04].s_box: 1c05f271a417e04ff921c5c104701554
round[04].k_sch: ae87dff00ff11b68a68ed5fb03fc1567
round[04].start: 88db34fb1f807678d3f833c2194a759e
round[03].s_row: 884a33781fdb75c2d380349e19f876fb
round[03].s_box: 975c66c1cb9f3fa8a93a28df8ee10f63
round[03].k_sch: 1651a8cd0244beda1a5da4c10640bade
round[03].start: ad9c7e017e55ef25bc150fe01ccb6395
round[02].s_row: adcb0f257e9c63e0bc557e951c15ef01
round[02].s_box: 1859fbc28a1c00a078ed8aadc42f6109
round[02].k_sch: a573c29fa176c498a97fce93a572c09c
round[02].start: 84e1fd6b1a5c946fdf4938977cfbac23
round[01].s_row: 84fb386f1ae1ac97df5cfd237c49946b
round[01].s_box: 4f63760643e0aa85efa7213201a4e705
round[01].k_sch: 101112131415161718191a1b1c1d1e1f
round[01].start: 6353e08c0960e104cd70b751bacad0e7
round[00].s_row: 63cab7040953d051cd60e0e7ba70e18c
round[00].s_box: 00102030405060708090a0b0c0d0e0f0
round[00].k_sch: 000102030405060708090a0b0c0d0e0f
round[00].output: 00112233445566778899aabbccddeeff

Machine Cryptanalysis of Basic Cryptosystems by James Pate Williams, Jr. BA, BS, MSwE, PhD

In Winter and Spring 2018 I wrote a simple C# computer program to perform machine cryptanalysis of the following basic (elementary and easily breakable) cryptosystems:

  1. Affine Cipher Operating on Monographs and Digraphs
  2. Matrix Cipher
  3. Mono-alphabetic Cipher
  4. n-Rotor with Shifting Polyalphabetic Cipher

The key ingredient in this program is a relatively extensive English language dictionary.

This slideshow requires JavaScript.