# Maintaining Secure Level on Symmetric Encryption under Quantum Attack
## 4 Programming and Testing
### Software Avalanche Test  
In order to ensure the security of AES-384 and AES-512, two scheduled avalanche tests will be conducted in this section. First, the former will be shown and explained, and the latter will only include the execution process [18].  
The avalanche test of AES-384 uses two strings with a difference of only one character. Table 9 presents the input and output of two plaintexts.  
Finally, Table 10 shows the results of two kinds of plaintext encryption, including hexadecimal and binary demonstrations. This test has a total of 128 bits, and the two strings of very similar plaintexts have changed by 64 bits, which is exactly 50%, which meets the conditions of the avalanche test.  
Next is the AES-512 avalanche test process and results, and the test data used in AES-512. Table 11 shows the input information of two different plaintext encryptions. Table 12 shows the two kinds of plaintext output results. According to the actual measurement of the encryption results, the two gaps between the latter accounted for 53.9% of the total number of bits which also passed the avalanche test.  
\begin{table}
\begin{tabular}{c c c c c c c c c c c c c c c c} \hline \hline  & & & & & & & & & & & & & & & & & & \\ \hline Output & 8c & 09 & 93 & 51 & a6 & 3e & 92 & 8e & f2 & 99 & 04 & 96 & 69 & 31 & 36 & b1 \\ ASCII & d6 & 99 & ba & 2f & ae & 53 & 6f & b6 & 55 & 98 & 13 & b1 & 4a & 77 & 33 & 9b \\ \hline \hline \end{tabular}
\end{table}
Table 10: AES-384 output plaintext.  
\begin{table}
\begin{tabular}{c c c c c c c c c c c c c c c c c} \hline \hline
**Original Key** & **2b** & **7e** & **15** & **16** & **28** & **ae** & **d2** & **a6** & **ab** & **f7** & **15** & **88** & **09** & **cf** & **4f** & **3c** \\ \hline Round 1 key & a0 & fa & fe & 17 & 88 & 54 & 2c & b1 & 23 & a3 & 39 & 39 & 2a & 6c & 76 & 05 \\ \hline Round 2 key & f2 & c2 & 95 & f2 & 7a & 96 & b9 & 43 & 59 & 35 & 80 & 7a & 73 & 59 & f6 & 7f \\ \hline Round 3 key & 3d & 80 & 47 & 7d & 47 & 16 & fe & 3e & 1e & 23 & 7e & 44 & 6d & 7a & 88 & 3b \\ \hline Round 4 key & ef & 44 & a5 & 41 & a8 & 52 & 5b & 7f & b6 & 71 & 25 & 3b & db & 0b & ad & ee \\ \hline Round 5 key & d4 & d1 & c6 & f8 & 7c & 83 & 9d & 87 & ca & f2 & b8 & bc & 11 & f9 & 15 & bc \\ \hline Round 6 key & 6d & 88 & a3 & 7a & 11 & 0b & 3e & fd & db & f9 & 86 & 41 & ca & 00 & 93 & fd \\ \hline Round 7 key & 4e & 54 & f7 & Be & 5f & 5f & c9 & f3 & 84 & a6 & 4f & b2 & 4e & a6 & dc & 4f \\ \hline Round 8 key & ea & d2 & 73 & 21 & b5 & 8d & ba & d2 & 31 & 2b & f5 & 60 & 7f & 8d & 29 & 2f \\ \hline Round 9 key & ac & 77 & 66 & f3 & 19 & fa & dc & 21 & 28 & d1 & 29 & 41 & 57 & 5c & 09 & 6e \\ \hline Round 10 key & d0 & 14 & f9 & a8 & c9 & ee & 25 & 89 & e1 & 3f & 0c & c8 & b6 & 63 & 0c & a6 \\ \hline \hline \end{tabular}
\end{table}
Table 8: 10 round expanded key.  
\begin{table}
\begin{tabular}{c c c c c c c c c c c c c c c c} \hline \hline  & & & & & & & & & & & & & & & & & & \\ \hline \multicolumn{12}{c}{**Plaintext 1**} & & & & & & & & & & & & & & & & & \\ \multicolumn{12}{c}{**Plaintext 2**} & & & & & & & & & & & & & & & & & & \\ \multicolumn{12}{c}{**Plaintext 3456**} & & & & & & & & & & & & & & & & & & & \\ \hline \multirow{3}{*}{ASCII} & 48 & 65 & 6c & 6c & 6f & 77 & 6f & 72 & 48 & 65 & 6c & 6c & 6f & 77 & 6f & 72 \\  & 6c & 64 & 31 & 32 & 33 & 34 & 35 & 36 & 6c & 64 & 31 & 32 & 33 & 34 & 35 & 30 \\ \hline \multirow{3}{*}{Original key} & 2b & 7e & 15 & 16 & 28 & ae & & & d2 & a6 & ab & f7 & 15 & 88 & & \\  & 09 & cf & 4f & 3c & 7e & 15 & & & 16 & 28 & ae & d2 & a6 & ab & & \\ \cline{1-1}  & f7 & 15 & 88 & 09 & cf & 4f & & & 3c & 2b & 2b & 7e & 15 & 16 & & \\ \cline{1-1}  & 28 & ae & d2 & a6 & ab & f7 & & & 15 & 88 & 09 & cf & 4f & 3c & & \\ \hline \hline \end{tabular}
\end{table}
Table 9: AES-384 input plaintext.