## 3 LED-PHOTON AE Implementation  
The proposed authenticated encryption scheme makes use of shared resources between the block cipher (LED) and the hash function (PHOTON). The encryption process is followed by a MAC process using the generic method of encrypt-then-MAC. The processing begins by resetting the registers of the state (STR) and the selector (LP), and initializing the round constants register (RC) by using a suitable value from the LFSR. RC is utilized to count the round indices of the permutation in both primitives (LED and PHOTON). STR holds the input values to the state matrix. LP is the selector used for performing LED encryption followed by PHOTON authentication. The encryption process begins when LP is set to one; it carries out all four permutation blocks and generates the output \begin{table}
\begin{tabular}{c c c c c c c c c c c c} \hline \hline
**Row** & **N\({}_{\mathbf{R}}\)** & **1** & **2** & **3** & **4** & **5** & **6** & **7** & **8** & **9** & **10** & **11** & **12** \\ \hline
**1** & 1 & 3 & 7 & E & D & B & 6 & C & 9 & 2 & 5 & A \\ \hline
**2** & 0 & 2 & 6 & F & C & A & 7 & D & 8 & 3 & 4 & B \\ \hline
**3** & 2 & 0 & 4 & D & E & 8 & 5 & F & A & 1 & 6 & 9 \\ \hline
**4** & 7 & 5 & 1 & 8 & B & D & 0 & A & 15 & 4 & 3 & 12 \\ \hline
**5** & 5 & 7 & 3 & A & 9 & F & 2 & 8 & D & 6 & 1 & E \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Round dependents for PHOTON-80/20/16. ciphertext while also taking advantage of shared resources with the permutation operations of PHOTON. Once the plaintext encryption is completed and the ciphertext is generated, LP is set and the authentication of the ciphertext begins. PHOTON applies authentication to the ciphertext generated by the LED. The permutation operation of PHOTON is processed while sharing the possible resources with the LED. The round count of the permutation operation is controlled by the LFSR. Figure 9 illustrates the block diagrams for the top-level design, and Figure 10 illustrates the arithmetic state machine, of the proposed authenticated encryption architecture. The design of the LED block cipher architecture is inherited from the PHOTON hash function, as they are produced by the same group. The internal permutation structure for both LED and PHOTON is an AES-like structure following the substitution permutation network (SPN). Therefore, the LED-PHOTON authenticated encryption (AE) process has some similarities within the permutation modules. The similarity between LED and PHOTON permutation functions is exploited to reduce the logic area utilization. The LED block cipher applies the encryption to the input message. The architecture of the individual design of LED-64 is shown in Figure 3. The processing of the LED begins by XORing the input plaintext (\(P\)) with the encryption key (\(K\)), and the output is loaded to the state register (\(STR\)) to be processed in the permutation blocks. This XOR operation of \(K\) and \(P\) is repeated every four rounds. The round constants (\(RCs\)) are fed every round to control the XOR and permutation operations, whereas the STR register is updated every round to hold the current state values. Once the STR is loaded, the state is passed through the permutation blocks for the main encryption operations. The output ciphertext is generated after 32 rounds of permutation functions. The PHOTON hash function performs the authentication process on the ciphertext encrypted by the LED. The architecture of the individual design of PHOTON-80/20/16 is shown in Figure 7. Four 20-bit input messages are considered, because the input to PHOTON is the 64-bit ciphertext from LED. The 64-bit input is padded with zeros to form a multiple of 20 to be absorbed by the sponge construction. The operation of PHOTON begins by XORing the 20 most significant bits of the initialization vector (\(IV\)) with the  
Figure 10: ASM chart of authenticated encryption. input message (\(M\)) and concatenating the result with the 80 least significant bits of \(IV\) and loading it to the \(STR\) register.