Open Access Paper
2 February 2023 Analysis on AES encryption standard and safety
Zhengyi Lu
Author Affiliations +
Proceedings Volume 12462, Third International Symposium on Computer Engineering and Intelligent Communications (ISCEIC 2022); 1246215 (2023) https://doi.org/10.1117/12.2662564
Event: International Symposium on Computer Engineering and Intelligent Communications (ISCEIC 2022), 2022, Xi'an, China
Abstract
AES has replaced DES to become a widely used encryption algorithm since 2000s. This paper may insight the basic theory of AES and safety analysis. In this paper, the whole process of AES encryption is described. The procedures of plaintext processing firstly, substituting bytes secondly, then shifting rows, mixing columns and adding round keys. AES-128 is taken as the study example in this paper to introduce the features and operating steps of AES. The construction and use of a simple S-box is also mentioned to help understand the procedure of substituting bytes. Safety analysis of AES is also taken into consideration to test AES’s resistance against different kinds of attacks. The results show that AES is free from brute force attack with time security analysis. AES with 128 or more bits of key length can resist square attacks according to reviews on research. A way of differential cryptanalysis attack with concrete operating steps is introduced as a potential attack method against AES encryption standard. The paper also casts view on an improved AES algorithm to increase efficiency and security proposed by other research.

1.

INTRODUCTION

Cryptography is a common technology in information industry. It means methods of transforming significant data into meaningless and messy codes with encryption functions to hide the data from attackers during transmitting procedure. After reaching the target receiver, the massy codes can be recovered with specific decryption functions. To be more vivid, encryption is like an excellent combination of art and science with the function of transferring plain and readable information into un-readable format [1]. Cryptography has shown great value in various industries including password protection, bitcoin mining, bitcoin transaction and so on. Cryptography has many subs and AES is one of the most practical and widely-used encryption algorithms.

1.1

Background

The Advanced Encryption Standard is called AES for short. Before it appeared, Data Encryption Standard, which is shorted as DES, was used by programmers for encryption on the world scale. DES is a symmetric cryptosystem developed by IBM in 1972. In 1977, it was identified as the Federal Data Processing Standard by the Federal Government of the United States and authorized to be used in non-secret government communications. However, DES only has a key length of 64 bits. It began to fail to meet the security requirements of encryption algorithm over time.

In 1990s, NIST started to collect for AES scheme to replace DES. The requirements for this standard were that it should be faster than Triple DES and should have at least the same security with Triple DES. Another request is that the winner should be able to resist both practical attacks and theoretical attacks with academic cryptanalysis methods [2]. During that period, Rijndael algorithm, which is the predecessors of AES, is created by Joan Daemen and Vincent Rijmen. For the design of Rijndael algorithm, it has principles of pursuing simplicity, focusing on performance and using well-understood components [2].

By 1999, five algorithms had been included as final alternative solutions. They are MARS, RC6, Rijndael, Serpent and Twofish. In 2000, Rijndael algorithm won in the competition with other algorithms and became the final standard in early 2000s. In US, NIST withdrew DES in 2004, which is a significant symbol for the recognition of AES. Internationally, AES has been included in ISO, IETF and IEEE standard [2].

1.2

Features

AES is a symmetric encryption algorithm. It means that its encryption key and decryption key have the same length. The decryption process of AES is the inverse of its encryption process. As a symmetric encryption algorithm, AES has advantages of relatively light computation requirements, fast encryption speed and high efficiency during the process of encryption.

What’s more, AES is a block cipher algorithm in structure, which represents that the block length and key length are independent and the block length is fixed. Moreover, the plaintext and ciphertext are texts with the same bit length. For AES, it has a fixed block length of 128 bits. Its key length is not fixed and can be adjusted according to different demands. It can be 128 bits, 192bits and 256bits, which correspond to 10, 12 and 14 rounds of encryption.

2.

PROCEDURE ANALYSIS AND PRINCIPLE

2.1

Overall Process

For more detailed study, the research contributes insight into AES-128, which has a key length of 128 bits and 10rounds of encryption. It contains universal procedures of plaintext processing, and four procedures for each round. A diagram for a typical 10 rounds encryption is shown in Figure 1.

Figure 1.

Procedures

00041_PSISDG12462_1246215_page_2_1.jpg

As shown in this diagram, the origin message is blocked and has a length of 128 bits. The zero round only contains the operation of adding round key. During the next 9 rounds of encryption, each round has procedures of substituting bytes firstly, shifting rows secondly, then mixing columns and adding round keys. However, for the last round, the operation of mixing columns is removed.

2.2

Plaintext Processing

Before rounds, operations should be done to transform plaintext to a matrix. The matrix is 4×4 bytes. The plaintext is fixed as 128 bits for one process. One letter takes up one byte (8 bits) of space. For example, Plaintext = “abcdefghijklmnop”. The matrix is P0, P1, …, P15 from top to bottom and left to right. Then “a” corresponds to “P0”, and “p” corresponds to “P15”. Figure 2 provides a visualization of the concrete operation.

Figure 2.

Text Processing

00041_PSISDG12462_1246215_page_3_1.jpg

2.3

Substitute Bytes

After entering rounds, operation of substituting bytes should be first completed. A S-Box, which is constructed complicatedly, is used. It is a 16×16matrix. A S-box is shown below in Figure 3.

Figure 3.

S-box [3]

00041_PSISDG12462_1246215_page_3_2.jpg

For example, for an 8-bit to 8-bit mapping, a = a0a1a2a3a4a5a6a7. Then the output should be S[a0a1a2a3][a4a5a6a7]. For this S-Box, if a = 00000000B, then the output should be S[0][0]=63H.

It comes to S-box and its structure. S-box provides mix functions for block key cipher and also serves as defender for different kinds of attacks. For AES-128, S-box is used for 160 times during processing and encryption. In consequence, the security of S-box is strongly associated to the safety of the whole cipher system [4].

To ensure the security of the whole system and make it able to withstand different attacks, the design of S-box should take differential cryptanalysis analysis and linear analysis into consideration. The process of designing one specific S-box is kept secret and should match several requirements. The S-box should be reversible to deal with encryption and decryption demands and should have complexity based on GF (28) [5]. GF (28) has a field of 256 elements and it is constructed according to the polynomial that f(x) = x8+x4+x3+x+1 is irreducible in the ring Z2[x] [6]. An algebraic interpretation of a S-box is started with one byte (eight bits) with each bit representing 0 or 1. Its S-box entry can be found applying GF (28) and computing algebraically [6].

2.4

Shift Rows

This procedure is a transformation of bytes in a 4×4 matrix (the data matrix). The first row on the top remains unchanged. The second row is shifted left for 8 bits (one byte) circularly. The third row is shifted left for two bytes circularly. The last row on the bottom is shifted left for three bytes circularly. The initial matrix and the result matrix obtained after row-shifts are shown in Figure 4.

Figure 4.

Shift Rows

00041_PSISDG12462_1246215_page_4_1.jpg

2.5

Mix Columns

In this procedure, a left multiplication is applied by multiplying data matrix with a fixed mix matrix. The basic requirements of mixing columns are as follows. The process should be reversible and symmetric [7]. It should also on GF (28). A more specific process is shown in Figure 5 as below.

Figure 5.

Mix Columns

00041_PSISDG12462_1246215_page_4_2.jpg

Different from common matrix multiplication, the calculation is based on GF (28) and the XOR calculation is applied.

2.6

Add Round Keys

For AES-128, key length is equal to 128 bits. By applying Key-generating function, 44 elements can be generated with each having a length of 4: W[0], W[1],….,W[43].

Among them, the elements from W[0] to W[3] are the original key. Others are divided into 10 groups and serve as round keys for 10rounds encryption.

For every round, XOR calculation is done with the data and the round key. Restoring the text of this round is available by doing the XOR calculation with the round key again.

3.

SAFETY ANALYSIS AND IMPROVEMENTS

AES has been widely used since it is authorized. When it comes to advantages, AES can resist many known attacks. It can be put into practical use on different kinds of platforms. What’s more, it is fast and has a relatively simple structure for users and programmers to adapt to. Since AES’s applications are numerous, for example, the development of accounting information system with AES, these industries and systems need high security assurance along with their development [8]. Thus, safety analysis of AES is necessary and meaningful.

The safety analysis is an important part for an algorithm to evaluate its usability and stability. The meaning of safety analysis is to judge the algorithm with the requirement that the potential attackers are still unable to break the key though they get to know the structure and procedures of the algorithm [9]. The attackers should consume more time on key attacks than exhaustive methods on this algorithm. For the safety analysis of AES, the resistance capacity towards different kinds of key attacks should be taken into consideration.

3.1

Brute Force Attack Analysis and Time Security

Brute force attack means applying exhaustive methods to figure out the key of the encryption. The time complexity of brute force attack is mainly decided by the block length and the key length of the algorithm. For this study, AES-128 has key length of 128 bits. After careful calculation, the results show that brute force attack has to try 3.403×1038 key combinations in the worst condition. This number of possible keys means that even for the fastest computer in the world, it will need about 3.19×1014 years to find that correct key [10]. This computation result shows a barely imaginable time demand for brute force attack, which verifies the time safety. What’s more, the block size for plaintext and key length are both 128-bit for AES-128 and it has an additional random key size of 8 bits. For the additional bits, the attacker needs to try 8.712×1040 key combinations in the worst condition. It will still need about 8.165×1016 years in maximum to crack the AES-128 algorithm even with the currently fastest computer in the world [10]. To be brief, it is totally impossible for human to try all the key combinations in a short time with current computation capacity.

3.2

Differential Cryptanalysis Analysis

Differential cryptanalysis is an effective method for block key analysis. It is proposed by Bihamand Shamiin in 1991 as a branch of chosen-plaintext attack. The fundamental idea of differential cryptanalysis is to acquire as many key bits as possible through the method of analyzing the effect of chosen plaintext changes on the ciphertext. This method is useful to attack block ciphers and ciphers constructed by iterating over a fixed round function.

For AES, the differential cryptanalysis is based on S-box attacks. Since the security of one encryption system is mainly dependent on the keys rather than the system. The keys of AES are the round keys generated by S-box. As a result, S-box is studied in every round to figure out part of the key. Linear analysis is applied for finding the most suitable linear functions among bits to try to find all bits [8]. For X, X’ ⊕ {0, 1}n, the differential of X, X’ can be expressed as ΔX = X ⊕ X’. For input pair (X, X’) and the output cipher pair (Y, Y’), the differential pair is (α, β), which satisfies α = X⊕X’ and β = Y⊕Y’.

To generate differential distribution table of S-box, INs is defined. As S-box is a mapping of 00041_PSISDG12462_1246215_page_5_1.jpg, INs refer to the assemble of (α, β) which satisfies S(X⊕α) ⊕ S(X) = β. It means that 00041_PSISDG12462_1246215_page_5_2.jpg. The attacker can only get several plaintext pairs, but he can observe the differential from different cipher pairs. Then the attacker should follow these steps:

  • The attacker can select an input differential α and compute the plaintext pair (x1, x1 ⊕ α), (x2, x2 ⊕ α) and so on. With these pairs, the output differential δy1, δy2, … can be obtained.

  • Afterwards, the attacker computes ⋂INs (α, δyi) in order to get the possible key k.

  • To get the actual key, the attacker has to choose more input differential and follow the step a & b until there only remains one possible key, which is the actual key.

3.3

Square Attack Analysis

Square attack is an attack based on the A set balance and is also a kind of chosen-plaintext attack. The designer of AES recommends that the method of using the square algorithm to calculate passwords based on byte structures is called Persistent Threat. Since AES algorithm integrates the byte-structure-oriented feature of square algorithm, the square attack can also be applied to AES [11]. According to analysis of basic attacks of square attack, there’s no successful square attack towards the complete AES algorithm. There’re several methods for solving AES with the reduced rounds, which are 4~6 rounds in detail [9]. This means that the attack is only possible for AES with less than 6 rounds. To avoid the square attack and ensure the security, the number of rounds must be equal to or greater than 7 [11]. Therefore, after taking this condition and other features into consideration, the AES algorithm requires 10 rounds of operations, which correspond to 128-bit key.

3.4

Improvements

As the AES algorithm is a widely used cipher system currently, the potential risks as mentioned above need to be faced and solved. Continually being open to attacks will leave the practical users and platforms unsecure. To face up these attacks, divisions of them should be made. The differential cryptanalysis attack and square attack are both chosen-plaintext attacks. Besides, side channel attack and energy analysis attack are all methods that are likely to break the algorithm.

For improvements, a lot of researches and optimizations have been carried out. In Mouna’s research, an improved method for AES implementation is discussed [12]. It uses temporal redundancy and adjusts the AES cycle to make it able to perceive fault attacks that may appear during runtime execution. This change can improve working frequency because pipelined registers are used. According to the research results and statistics, the detection of single fault attacks and multiple fault attacks becomes possible reality with its efficient fault detection system.

4.

CONCLUSION

This paper introduces the basic theory and concrete procedures of AES algorithm. AES as a widely-used cryptography technology shows the typical process and the significant points of a symmetric and block cryptography function.AES-128 is taken as an example for research in this paper. Starting by plaintext processing, the message needed to be transformed is turned into data matrix for later procedures. Substituting bytes is applied with a S-box to further handle the data matrix. Shifting rows and mixing columns are continued with matrix transformation in two certain different ways to help the cipher data to become massy gradually. To add round key part, the original key is expended with key generation functions. The keys obtained from the function are separately work for ten rounds of encryption. For the decryption part, an inverse of the encryption function will successfully work to help get the original plaintext provided with the ciphertext.

Safety analysis is applied for AES algorithm. Its resistance against brute force attack, differential cryptanalysis attack and square attack is taken into consideration. For brute force attack, AES shows perfect time security after computation of time consumption for exhaustive methods. The differential cryptanalysis attack provides a potential attack method against AES. Basic steps are shown for a typical differential cryptanalysis attack. The square attack turns out to be not effective against AES as AES has rounds of more than ten to resist such kind of attacks. To optimize attacks mentioned before and other potential attacks, improvements are continually raised for better security and performance of AES. A method of using temporal redundancy and changing the AES cycle is mentioned, which can effectively detect single and multiple fault attacks and increasing working efficiency. Obviously, more measures and improvements will be figured out and help AES to become more and more comprehensive and secure in nearing future.

References

[1] 

A. Hamza and B. Kumar, “A Review Paper on DES, AES, RSA Encryption Standards,” in 2020 9th International Conference System Modeling and Advancement in Research Trends (SMART), 333 –338 (2020). Google Scholar

[2] 

J. Daemen and V. Rijmen, “The First 10 Years of Advanced Encryption,” IEEE Security & Privacy, 8 (6), 72 –74 (2010). https://doi.org/10.1109/MSP.2010.193 Google Scholar

[3] 

ReadingLover.Detailed explanation of cryptographic algorithm—AES,” (2015) https://www.cnblogs.com/luop/p/4334160.html Google Scholar

[4] 

Wang peifen, “S-box design analysis and improvement of AES encryption algorithm [J],” Journal of huaihai institute of technology (natural science edition), 2014 18 –21 Google Scholar

[5] 

Liu Yufeng, Xu Xiangyang, Su Hao, Geng Yanxiang and Liu Ting, “Optimization and design of block cipher AES [J],” Computer applications and software, 267 –270+297 (2020). Google Scholar

[6] 

Aiden A. Bruen, Mario A. Forcinito and James M. McQuillan, “Modes of Operation for AES and Symmetric Algorithms,” Cryptography, Information Theory, and Error-Correction: A Handbook for the 21st Century, 109 –123 Wiley,2021). https://doi.org/10.1002/9781119582397 Google Scholar

[7] 

Guo Yanzhen, Han Wenbao, Zhao Long and Liu Jiaxiao, “AES column hybrid transformation [J],” Journal of PLA university of science and technology, 232 –236 (2009). Google Scholar

[8] 

Qing-Xiang Zhu, Lu Li, Jing Liu and Nan Xu, “The analysis and design of accounting information security system based on AES algorithm,” in 2009 International Conference on Machine Learning and Cybernetics, 2713 –2718 (2009). Google Scholar

[9] 

Dongli Zhang and Wenchen Jiao, “AES algorithm and Safety Analysis,” in Proceedings of the 2011 International Conference on Future Computer Science and Application, 237 –239 (2011). Google Scholar

[10] 

Al-Mamun A, Shawon S M R, Ahmed Shaon T, et al, “Security Analysis of AES and Enhancing its Security by Modifying S-Box with an Additional Byte[J],” International Journal of Computer Networks and Communications, 69 –88 (2017). https://doi.org/10.5121/ijcnc Google Scholar

[11] 

Wei Baodian, Liu Dongsu and Wang Xinmei, “A New Square Attack [J],” Journal of Xidian University, 473 –476 (2003). Google Scholar

[12] 

Mouna Bedoui, Hassen Mestiri, Belgacem Bouallegue, Belgacem Hamdi and Mohsen Machhout, “An improvement of both security and reliability for AES implementations,” Journal of King Saud University - Computer and Information Sciences, (2022). Google Scholar
© (2023) COPYRIGHT Society of Photo-Optical Instrumentation Engineers (SPIE). Downloading of the abstract is permitted for personal use only.
Zhengyi Lu "Analysis on AES encryption standard and safety", Proc. SPIE 12462, Third International Symposium on Computer Engineering and Intelligent Communications (ISCEIC 2022), 1246215 (2 February 2023); https://doi.org/10.1117/12.2662564
Advertisement
Advertisement
RIGHTS & PERMISSIONS
Get copyright permission  Get copyright permission on Copyright Marketplace
KEYWORDS
Safety

Cryptanalysis

Standards development

Computer security

Analytical research

Cryptography

Detection and tracking algorithms

RELATED CONTENT

Study on traffic sign setting of Hong Kong Zhuhai Macao...
Proceedings of SPIE (December 22 2021)
Application analysis of cryptography in blockchain
Proceedings of SPIE (February 02 2023)
Chosen-message forgery attack on SCREAM
Proceedings of SPIE (April 21 2022)
Encryption algorithm based on Lagrange interpolation
Proceedings of SPIE (February 02 2023)

Back to Top