Skip to main content
Heliyon logoLink to Heliyon
. 2024 Feb 13;10(5):e26119. doi: 10.1016/j.heliyon.2024.e26119

Improved 2-round collision attack on IoT hash standard ASCON-HASH

Di Zhai a,b,, Wei Bai a,b, Jianding Fu a,b, Hongjian Gao a,b, Xueqiong Zhu c
PMCID: PMC10907535  PMID: 38434343

Abstract

Lightweight cryptography algorithms are a class of ciphers designed to protect data generated and transmitted by the Internet of Things. They typically have low requirements in terms of storage space and power consumption, and are well-suited for resource-limited application scenarios such as embedded systems, actuators, and sensors. The NIST-approved competition for lightweight cryptography aims to identify lightweight cryptographic algorithms that can serve as standards. Its objective is to enhance data security in various scenarios. Among the chosen standards for lightweight cryptography, ASCON has been selected. ASCON-HASH is a hash function within the ASCON family. This paper presents a detailed analysis of the differential characteristics of ASCON-HASH, utilizing the quadratic S-box. Additionally, we employ message modification techniques and ultimately demonstrate a non-practical collision attack on the 2-round ASCON-HASH, requiring a time complexity of 298 hash function calls.

Keywords: IoT, ASCON, ASCON-HASH, Collision attack, Lightweight cryptograph

1. Introduction

The demand for lightweight ciphers primarily arises from the widespread use of IoT devices. In resource constrained environments, there are limitations on storage space and power consumption. Traditional cryptographic algorithms may be too complex to operate efficiently in such constrained resources. Hence, there is a need to design lightweight cryptographic algorithms to meet the requirements of these unique environments. The design goal of lightweight cryptographic is to provide sufficient security and performance in resource constrained scenarios. They achieve this by balancing security and resource consumption in their design, offering an appropriate level of security for these environments. These ciphers need to ensure the protection of sensitive data and secure communication while also delivering efficient encryption and decryption performance to meet real-time requirements.

Moreover, standardization plays a vital role in encouraging the use and compatibility of lightweight cryptographic algorithms. By going through the standardization process, these algorithms can guarantee security and dependability, establishing uniform guidelines for developers in relevant domains. This, in turn, simplifies their implementation and utilization in different Internet of Things (IoT) situations. In 2013, the National Institute of Standards and Technology (NIST) initiated the lightweight cryptography project. In 2016, NIST presented an outline of the project and emphasized the necessity to discover novel algorithms for a lightweight cryptography standard. Consequently, in 2019, NIST totally received 57 submissions, out of these 56 were chosen as first-round candidates after the initial evaluation. As the initiative progressed to Round 2 [1], NIST further narrowed down the selection to 32 submissions, including ASCON. ASCON, which was among the Round 2 candidates initially, successfully advanced as one of the ten finalists in the standardization process for lightweight cryptography. Ultimately, on February 7, 2023, NIST officially declared the ASCON family as the selected standard for lightweight cryptography.

The ASCON cipher suite [2] offers authenticated encryption with associated data (AEAD) and hashing capabilities. Its design is straightforward and adaptable, allowing for efficient implementation in both hardware and software. This makes it particularly well-suited for environments with limited resources. Additionally, ASCON is designed to meet different security and performance needs. For example, ASCON-128 and ASCON-128a provide a 128-bit security level, ideal for applications requiring robust security. Conversely, ASCON-80pq offers an 80-bit security level, making it a good fit for low-power and cost-effective scenarios. ASCON stands out for its ability to both encrypt data and protect integrity. It also accommodates associated data, enabling the confirmation of extra details like the sender's and receiver's identities during encryption.

Development of ASCON  ASCON participated in Round 1 of the CEASER competition [3] and introduced its initial design, version v1. ASCON specified a permutation and authenticated encryption mode, recommending ASCON-128 as the primary choice and ASCON-96 as a variant with a 96-bit key. Later versions, namely V1.1 [4] and V1.2 [5], incorporated minor functional tweaks, including the reorganization of round constants. The secondary recommendation was updated to ASCON-128a. These updates, in conjunction with V1.2 [5] and the accompanying status update document [6], were presented to the NIST Lightweight Cryptography initiative. The submission to NIST included not only the authenticated cipher family but also introduced hashing modes: ASCON-HASH and ASCON-XOF. Additionally, ASCON-80pq, a third parameterization for authenticated encryption, was included. ASCON-HASH supports 256-bit hash values, while ASCON-XOF can accommodate hash values of any length.

Related results  ASCON has been the subject of extensive analysis, with numerous analytic results available. The submission document [7] provides detailed information regarding the security of the ASCON permutation. The authors analyzed the security of the newest version in [8]. Nearly the proposition of ASCON, there followed some analysis results. In [9], the author proposed the differential analysis result for ASCON. [10] proposed a cube attack on round-reduced ASCON. A more detailed cryptanalysis for round-reduced ASCON was published in [11].

The security analysis of collision resistance for hash functions, specifically ASCON-XOF and ASCON-HASH, was conducted by the designers and presented in [12]. In the same paper, they also introduced a semi-free-start collision attack on 4-round ASCON-XOF and ASCON-HASH, assuming a chosen IV (initial value), without providing a detailed process or complexity analysis.

In [13], the authors proposed two attack strategies for finding collisions in hash functions based on sponge constructions, including GIMLI-HASH, ASCON-HASH, and ASCON-XOF. They primarily focused on the first strategy and presented the results of attacking the three hash functions using this approach. For brevity, we will omit the results of GIMLI-HASH. Regarding ASCON-XOF, they successfully achieved a practical collision with a designated IV. As for ASCON-HASH, they demonstrated a non-practical 2-round collision attack with a time complexity of 2125.

However, according to [14], the characteristic found by the authors is invalid that makes this attack invalid. But the strategy is effective. To a great extent, this time complexity depends on the active S-boxes in the input differential characteristic. Then in [15], the authors found a valid characteristic with fewer active S-boxes. Using the same attack strategy in [13], they gave a 2-round collision with a time complexity of 2103 hash function calls. Qin et al. [16] presented collision attacks on 3 and 4 rounds of ASCON-HASH by turning preimages for ASCON-XOF into collisions for ASCON-HASH. Although the authors expand the rounds, the time complexity of 2130 is still far from practical attack. Until now, we don't see any results using the message modification technique. So we try to accelerate the collision attack with this technique.

Our contributions  In this paper, our main focus is on ASCON-HASH, a hash function that utilizes the sponge construction. Initially, we present an attack strategy outlined in [13] for detecting collisions in a 2-round ASCON-HASH. Subsequently, we propose our own approach to decrease the time complexity required for this process, reducing it from 2103 to 298 hash function calls. Our method is based on a characteristic discovered in [15], and we draw inspiration from the work of [14], who merged conditions in 2 consecutive rounds of GIMLI-HASH using an algebraic method. However, in our case, we primarily employ the message modification technique described in [17]. The related results can be seen in Table 1.

Table 1.

The collision attack results of 2-round ASCON-HASH.

Reference [13] (invalid) [15] This paper
Time complexity 2125 2103 298

Outline. In section 2, we provide a concise overview of ASCON-HASH and introduce several notations that will be utilized in this paper. In section 3, we describe the attack strategy proposed in [13] and the useful observations of the S-box in ASCON-HASH. In section 4, we give our technique of improving this attack, including merging conditions and message modification. At last, section 5 concludes our paper.

2. Preliminaries

2.1. Notations

  • S is the state of the hash function.

  • M is the message.

  • Mi denotes the i-th block after the message being padded.

  • r represents the bit length of the rate part, in this paper, r=64.

  • c denotes the bit length of the capacity part, in this paper, c=256.

  • Sr is the rate part of S (the first 64 bits).

  • Sc is the capacity part of S (the last 4×64 bits).

  • Δ represents the XOR differential.

  • pa is the inner primitive of an a-round hash function.

  • p(i) denotes the primitive absorbing the i-th message block.

  • Si is the state in the i-th round function.

  • Si,s denotes the state after the S-box layer in the i-th round function.

  • Sj represents the j-th line (64-bit) of S.

  • X[k] is the k-th bit of a 64-bit word X, X[0] is the least significant bit.

  • xi is the i-th bit of a 5-bit word x, 0 denotes the most significant bit.

  • ⋙ denotes the right rotation (circular right shift).

  • Σi is the i-th linear diffusion function.

  • ⊕ is bitwise XOR.

2.2. Description of ASCON-HASH

ASCON-HASH is a type of hash function that is constructed using the sponge construction method, as described in the reference [18]. This hash function operates on a 320-bit state and applies a 12-round function to it. It takes a message of any length as input and produces an output of fixed size. The process of hashing is depicted in Fig. 1.

Figure 1.

Figure 1

The hash mode of ASCON-HASH.

In ASCON-HASH, the state is divided into five 64-bit words, represented as S=S0||S1||S2||S3||S4. The first word (64 bits) is referred to as the rate part, while the remaining four words form the capacity part. The round function used in ASCON-HASH consists of three operations: fCfSfL. These operations are based on the Substitution-Permutation Network (SPN) construction.

Addition of constantsfC  During this step, a round constant cr is added to the words S2 in each round state, represented as S2S2cr. The round constants cr for the 12-round ASCON-HASH are provided in Table 2.

Table 2.

Constant cr used in the permutation of ASCON.

Round 0 1 2 3 4 5 6 7 8 9 10 11
Constant cr f0 e1 d2 c3 b5 a5 96 87 78 69 5a 4b

Substitution layerfS  This process involves utilizing 64 parallel instances of the 5-bit S-box to modify the state. The S-box is specified in Table 3. Each group of five input bits, denoted as x0,,x4, and output bits, denoted as y0,,y4, from the S-box, represents a column in the input or output state. Refer to Fig. 2a for a visual representation.

Table 3.

The 5-bit S-box.

x 0 1 2 3 4 5 6 7 8 9 a b c d e f
S(x) 4 b 1f 14 1a 15 9 2 1b 5 8 12 1d 3 6 1c

x 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f
S(x) 1e 13 7 e 0 d 11 18 10 c 1 19 16 a f 17

Figure 2.

Figure 2

Substitution layer and linear layer.

Linear diffusion layerfL  This step introduces diffusion within each 64-bit word Xi, as depicted in Fig. 2b. The corresponding word Si undergoes linear functions Σi according to the following expressions:

S0Σ0(S0)=S0(S019)(S028),S1Σ1(S1)=S1(S161)(S139),S2Σ2(S2)=S2(S21)(S26),S3Σ3(S3)=S3(S310)(S317),S4Σ4(S3)=S4(S47)(S441).

The state will be denoted within the i-th (0i<12) round function as follows:

SifCSi,cfSSi,sfLSi+1.

The hash function begins by initializing the 320-bit state using a constant value of IV=00400c0000000000. Subsequently, a permutation is applied to initialize the state S0, denoted as S0=p12(IV||0256). In the context of the absorbing phase, we consider S0 as the initial state. For the 12-round ASCON-HASH, the value of S0 is as follows:

ee9398aadb67f03d8bb21831c60f1002S0b48a92db98d5da6243189921b8f8e3e8348fa5c9d525e140

The padding procedure for ASCON-HASH is as follows: it adds a single 1 followed by the fewest number of 0s to the message M in order to make the length of the padded message a multiple of r=64 bits. The detailed explanation of the hash function can be found in Algorithm 1. The security claim for ASCON-HASH is 2128.

Algorithm 1.

Algorithm 1

ASCON-HASH.

3. The 2-round collision attack strategy on ASCON-HASH

3.1. Observations

The ANF of ASCON's 5-bit S-box with input x=x0||x1||x2||x3||x4 and output y=y0||y1||y2||y3||y4 is shown in Equation (1).

{y0=x4x1x3x2x1x2x1x0x1x0,y1=x4x3x2x3x1x3x2x1x2x1x0,y2=x4x3x4x2x11,y3=x4x0x4x3x0x3x2x1x0,y4=x4x1x4x3x1x0x1. (1)

[13] proposed some useful observations of the S-box. We here take most advantage of Observation 1, as the details following.

Observation 1

When all the last four input difference bits are inactive, i.e., Δx1=Δx2=Δx3=Δx4=0 the following constraints hold (note that Δx0=1):

-The output difference satisfies some conditions:

{Δy0Δy4=1,Δy1=Δx0,Δy2=0. (2)

-The input value satisfy some conditions:

{x1=Δy01,x3x4=Δy31. (3)

The proof of Observation 1 can be seen in the appendix of [13]. Just following this thinking, we get Observation 2.

Observation 2

Focusing on y0 of an S-box, we can get the equations hold as follows. When x2, x3, x4 are known and specifically x1=0, the value of y0 is determined by x0 as Equation (4) shows.

y0={x3x2x0=0,x3x21x0=1, (4)

and while x1=1, x0 has no affection on y0.

Proof

Substituting x0=0 or x0=1 into y0 of Equation (1), we can easily get the equation as follows:

y0={x4x1x3x2x1x2x1,x0=0x4x1x3x2x1x21,x0=1 (5)

It's easy to see if x1=1, the two equations in Equation (5) are the same. So when we let x1=0, the value of y0 can be controlled by x0. Moreover, since in S0, x0 can be adjusted by the message absorbed, the value of y0 can be adjusted by modifying the message.

3.2. The attack process

Here we describe the first strategy described in [13] in detail. It takes use of k-round differential characteristics where both the input and output have nonzero difference in the rate part but zero difference in the capacity part. Assume that there are totally s (s>2) pairs of message blocks we have to construct.

Before S0, the first s2 message pairs absorbed have no difference. After these s2 message block pairs are absorbed, the constraints of the capacity part in S0 are satisfied. Next, we construct one more message pair to satisfy the difference in the rate part, namely Ms1Ms1=ΔS00. After the 2-round permutation, last message pair is needed to eliminate the difference in the rate part of the output difference, namely constructing one more message pair that satisfies MsMs=ΔS02. So assuming that we will totally construct s message block pairs, the first s2 pairs have no difference and only the last 2 message pairs have difference. The point is shown in Fig. 3. The whole process is described as follows.

Figure 3.

Figure 3

The attack strategy.

-Find a 2-round differential.

In [15], the authors discovered a 2-round ASCON differential characteristic, as presented in Table 4. This characteristic exhibits a lower number of active S-boxes compared to the one described in [13]. The overall probability of this characteristic is 2156. It is evident that the input and output differences are only non-zero in the rate part. With 27 active S-boxes in ΔS0, according to Observation 1, there are 54 constraints in the capacity part of S0. Specifically, within these 27 active S-boxes, the corresponding capacity bits must satisfy x1=Δy01 and x3x4=Δy31.

Table 4.

The differential characteristic of the ASCON in [15] for two rounds.

ΔS0 (2−54) ΔS1 (2−102) ΔS2
bb450325d90b1581 2201080000011080 baf571d85e1153d7
0 2adf0c201225338a 0
0 0 0
0 0000000100408000 0
0 2adf0c211265b38a 0

-Construct message pairs.

As mentioned earlier, we select pairs of messages that only differ in the last two blocks, denoted as ΔMi=0,1is2. Each message consists of s blocks. As stated in Observation 1, when we have the input difference of the original (s1) round characteristic, there will be corresponding constraints on the value of the capacity part of S0 of p(s1). Assuming there are X constraints, and considering the r bits of freedom provided by the primitive, we need at least Xr blocks to obtain one valid S0 of p(s1). In the case of the characteristic mentioned in Table 4, we have X=54 and r=64. Finally, we generate two additional message blocks that respectively lead to the characteristic and eliminate the output difference. For the given characteristic, these blocks would be ΔMs1=bb450325d90b1581 and ΔMs=baf571d85e1153d7.

-Search for the collisions.

We attempt to discover suitable values for S0 of p(s1) by randomly selecting the first s2 message blocks. The filtering probability is 254. For each qualified S0, considering the characteristic's probability as p, on average, we can find a pair that adheres to the difference model of the characteristic by utilizing 1/p pairs of the (s1)-th block. To summarize, the attack strategy consists of the aforementioned three steps. In this particular case, the complete attack process is outlined as follows.

  • 1.

    By taking advantage of the 64-bit freedom provided by one ASCON message block, we generate 254+10264=292 pairs of 2-block messages (M0,M1) randomly. We then apply the hash function and keep track of all the state values.

  • 2.

    Theoretically, there is a probability of 254 to obtain 238 values (M0,M1) that satisfy the 54 constraints.

  • 3.

    We exhaustively iterate through all 264 pairs of message blocks M2 and compute M2=M2ΔS00 for each of the 238 2-block messages (M0,M1) obtained in Step 2. This results in a total of 264+38=2102 pairs of 3-block messages.

  • 4.

    With a probability of 2102, a message pair will satisfy the constraints in the second round. Consequently, one message pair will produce the desired output difference.

  • 5.

    By applying a random message block M3 and computing M3=M3ΔS02 for the message blocks selected at the end of Step 4, we can directly obtain a collision.

Complexity. The complexity of the attack procedure above is (2×292)+(2×2102)2103 hash function calls.

The result is improved compared to 2125 hash function calls in [13]. In next section, we will discuss how to improve this attack, reducing the time complexity to 298 hash function calls.

4. To improve the 2-round collision attack on ASCON-HASH

The main idea to improve this attack is converting the constraints in latter rounds to the constraints in former rounds of the two consecutive rounds. We are inspired by [14] where the authors used the specific properties of SP-boxes in hash function GIMILI and successfully merged the conditions in two consecutive rounds. Also we use the message modification technique proposed in [17] to further reduce the complexity.

4.1. Find the fixed bits in the states

Taking the linear layer into account, the complete differential characteristic of a primitive is shown in Table 5. The differential propagation is as follows: ΔS0fSΔS0,sfLΔS1fSΔS1,sfLΔS2.

Table 5.

The 2-round ASCON-HASH differential characteristic including linear diffusion layer.

ΔS0(2−54) ΔS0,s ΔS1(2−102) ΔS1,s ΔS2
bb450325d90b1581 0000000000011080 2201080000011080 2adf0c211265b38a baf571d85e1153d7
0 bb450325d90b1581 2adf0c201225338a 0 0
0 0 0 0 0
0 0000000100000000 0000000100408000 0 0
0 bb450325d90a0501 2adf0c211265b38a 0 0

In fact, we originally took fC (add constants) into account and then we found it has no affection in any steps. So for clarity, we don't discuss it here.

According to Observation 1, since there are 27 active S-boxes in the input difference, we can totally get 54 constraints in the capacity part. Moreover, there are 28 active S-boxes in ΔS1, and the probability from ΔS1 to ΔS1,s is 2102. So we are going to find out the 102 constraints that the value S1 has to satisfy. We observe that the 28 active S-boxes in ΔS1 only have 3 different pairs of the input and output values from ΔS1 to ΔS1,s as Table 6 shows. The difference from ΔS0 to ΔS0,s is clearly as Equation (2) shows.

Table 6.

The input and output differential between the S-boxes of ΔS1 and ΔS1s (0 refers to the least significant bit).

situation ΔS041[i] ΔS041,s[i] number of S-boxes i
1 11001 10000 7 7,12,16,43,48,57,61
2 00011 10000 3 15,22,32
3 01001 10000 18 1,3,8,9,13,18,21,25,28,37,42,49,50,51,52,54,55,59

Considering the relation between the difference and the state of S-boxes, for these 3 situations we got some constraints. In the following, we refer x as the input of a 5-bit S-box and y as the output of the same 5-bit S-box. And xi refers to the i-th bit of x and the same as yi. The proof of equations (6-8) is shown in Appendix A.

Situation 1. When Δx=11001 and Δy=10000 for an S-box, the following 3 equations hold. For there are 7 such S-boxes between ΔS1 and ΔS1,s, we will totally get 21 constraints in S1.

{x0x4=0,x2=1,x3=0. (6)

Situation 2. When Δx=00011 and Δy=10000 for an S-box, the following 3 equations hold. For there are 3 such S-boxes between ΔS1 and ΔS1,s, we will totally get 9 constraints in S1.

{x1=0,x2=0.x3x4=0, (7)

Situation 3. When Δx=01001 and Δy=10000 for an S-box, the following 4 equations hold. For there are 18 such S-boxes between ΔS1 and ΔS1,s, we will totally get 72 constraints in S1.

{x0=0,x1x4=1,x2=0,x3=0. (8)

Note that in Situation 3, because of x0=0, the corresponding 18 bits in ΔS01 have been fixed to 0.

Now we've got totally 21+9+72=102 constraints that S1 has to satisfy. We'll next show how to convert 8 of them into the constrains in S0. In the following, we use X denoting S0 and Y denoting S0,s. And as above, we still refer x as the input of a 5-bit S-box and y as the output of the same 5-bit S-box.

As discussed above, since there are 27 active S-boxes in ΔX, according to Equation (3) in Observation 1 we can easily get these 54 constraints corresponding to these 27 active S-boxes. In other words, in these 27 columns, x1 and x3x4 can be fixed. We can see in Equation (3), x1 and x3x4 are determined by Δy0 and Δy3. From Table 5, it's easy to see that there are three different value pairs of Δy0 and Δy3 in these 27 active S-boxes as we will discuss below. After we get the fixed X's bits, we can substitute them into Equation (1) to get fixed Y's bits.

Wheni = 32, ΔY0[i]=0 and ΔY3[i]=1, so X1[i]=1 and X3[i]X4[i]=0. Substituting them into equation (1), we can get that

Y0[i]=1.

Wheni = 7, 12, 16, ΔY0[i]=1 and ΔY3[i]=0, so X1[i]=0 and X3[i]X4[i]=1. Substituting them into equation (1), we can get that

Y4[i]=1.

Wheniequals to the other 23 locations of the active S-boxes, ΔY0[i]=0 and ΔY3[i]=0, so X1[i]=1 and X3[i]X4[i]=1. Substituting them into equation (1), we can get that

Y0[i]=0.

After calculating all the 27 columns, there are 24 bits fixed in Y0, namely in S0,0s. It's easy to see S00,s is transformed into S01 after the linear function Σ0. As soon as S00,s[i] is fixed, S00,s[i]j (j is a constant) can be fixed. For clarity, we fulfill those bits as shown in Table 7. By using Σ0 we can fix more bits, we'll discuss it in the next section.

Table 7.

The fixed bits in S00,s and S01.

4.1.

4.2. Transforming conditions

As above, we've fixed some bits in S00,s and S01. With the current known conditions, we can infer more fixed bits in the two states. Taking the least significant bit as an example, for S00,s[0]=0,S00,s19[0]=0 and S00,s28[0]=0 are known, S01[0]=000=0 can be fixed. Next, as it can be seen that S00,s[8]=0, S00,s19[8]=0 and S01[8]=0 are fixed, S00,s28[8]=0 can be got. Considering the rotation operation, S00,s[36]=0 and S00,s19[17]=0 can be known.

Calculating all the bits as above, we can get more fixed bits as shown in Table 8. The derivation process is shown in Table B.9 in Appendix B. Compared to Table 7, we got 8 more bits fixed in S0,0s and 6 more bits fixed in S01. It's unnecessary to take the latter 6 bits into account in the next, because once all constraints in S0 and S1 are satisfied, they hold with probability 1.

Table 8.

The fixed bits in S00,s and S01 after derivation.

4.2.

Observing Table 8, when i{0,8,9,13,18,27,28,31,36,37,46,54,55,63}, the all four bits of the i-th column are fixed, namely S00,s[i], S00,s19[i], S00,s28[i] and S01[i]. Ignoring the extra 6 bits deduced in S01, 8 of these 14 columns, namely i{8,9,13,18,28,37,54,55} are part of the original 102 constrains in S1. This means if we let S0,s satisfy these 8 constraints derived in S00,s, the corresponding 8 constraints in S1 will hold with probability 1. So the 8 constraints in S1 can be transformed into the corresponding 8 constraints in the former round.

In the next, we'll discuss how to use the message modification technique to ensure these 8 conditions hold.

4.3. Message modification

In Table 8, it can be seen that 8 more bits are fixed in S00,s compared to Table 7. These 8 columns correspond to S00,s[i] where iP (P={1,9,13,18,36,46,47,55}). And it's easy to obtain that when iP, the S-boxes are all inactive in ΔS0[i].

We use a five-bit x denoting the input of the i-th S-box in state S0 and a five-bit y denoting the output of the i-th S-box in state S0,s (iP). According to Equation (4) in Observation 2, since x2,x3,x4 are known and x1=0, the value of y0 is determined by x0, which can be adjusted by the message block Ms1. So we add another 8 constraints x1=0, namely S10[i]=0 (iP), to the capacity part. In other words, we add another 8 constraints to the first s2 message blocks that ensure S10[i]=0 (iP). Then we can modify message Ms1 in these 8 bits to make S00,s that equals to the corresponding value as above.

For clarity, here regard all the 8 values of x0 as the bits before state S0 absorbing message Ms1. Since x1=0 and y0 is known, the modification step of Ms1 is shown in Equation (9). Notice that y0=1 only when i=13, otherwise y0=0.

Ms1[i]={x3x2x01,i=13,x3x2x0,i=1,9,18,36,46,47,55. (9)

4.4. Time complexity

This improved attack builds on the attack strategy given in Section 3. The constraints in S0 increase to 54+8=62 and in S1 decrease to 1028=94. But because of the message modification, the freedom of message block Ms1 and Ms1 is reduced to 256. We observe that if we let all the 8 extra constraints hold in S0, the time complexity has almost no improvement.

So we don't convert all the 8 constraints into S0 straightforward. Observing the attack process, we can see the time complexity is decided by two steps, namely constructing random 2-block messages (M0,M1) and constructing message pairs of (M2,M2) to satisfy the input difference. To make the time complexity lowest, we can just convert part of these 8 constraints instead of all of them. Assuming that we add λ constraints into S0, and 8λ constraints unchanged, the constrains in capacity part of S0 will increase to 54+λ and decrease to 102λ in S1. And the freedom offered by message block Ms1 will be reduced to 264λ. Then the time complexity of the first step can be calculated as 2(54+λ)+(102λ)(64λ)=292+λ hash function calls. The time complexity of the second step is 2102λ hash function calls. The ideal λ should make the equation 92+λ=102λ holds. It's easy to get that λ=5.

Finally, the constraints in S0 are 54+5=59 and in S1 is 1025=97. The freedom of message M2 is 645=59. So the complete procedure is as follows:

  • 1.

    First, we totally generate 259+9759=297 pairs of random 2-block messages (M0,M1).

  • 2.

    With probability of 259, we can get 238 messages corresponding to the constraints in S0.

  • 3.

    For these 238 messages, exhausting the 259 messages for each, we can totally get 238+59=297 message pairs of (M2,M2) with M2M2=ΔS0,0.

  • 4.

    It is expected that one pair of these 297 message pairs will lead to the output difference.

  • 5.

    Apply one more random message block M3 and M3=M3ΔS2,0 at the end of step 4.

Complexity. The whole complexity of this attack is (2×297)+(2×297)298 hash function calls, which is superior to 2103.

5. Conclusion

In this paper, we reduce the attack complexity of 2-round ASCON-HASH. At beginning, we analyze the currently optimal characteristic to find the fixed bits in the states. Specifically, we find the properties of the S-box with particular differences so that we can get some constraints of the input state. After that, we take use of the linear layer to convert 8 constraints of round 1 into 8 constraints of round 0. To reach the lowest time complexity, we convert only 5 of these 8 constraints instead of all of them using the message modification technique.

Funding

This research was funded by State Grid Science and Technology Project (No. 5108-202218280A-2-201-XG).

CRediT authorship contribution statement

Di Zhai: Methodology, Conceptualization. Wei Bai: Writing – review & editing, Writing – original draft, Conceptualization. Jianding Fu: Writing – review & editing, Methodology. Hongjian Gao: Writing – review & editing, Writing – original draft, Formal analysis. Xueqiong Zhu: Writing – review & editing, Writing – original draft, Formal analysis.

Declaration of Competing Interest

The authors declare the following financial interests/personal relationships which may be considered as potential competing interests:

Di Zhai reports financial support was provided by State Grid Corporation of China. Di Zhai reports a relationship with State Grid Corporation of China that includes: employment. All the co-authors are employed by State Grid Corporation of China.

Acknowledgements

The authors would like to thank the anonymous reviewers for their helpful comments.

Appendix A. Proof of equations (6), (7), (8)

First we introduce this obvious theorem that when Δa=0, Δ(ab)=aΔb. It's easy to prove since Δ(ab)=(abab).

As it is already known the ANF of ASCON's 5-bit S-box as equation (1), it's easy to derive the relation between difference as below:

{Δy0=Δ(x4x1)Δx3Δ(x2x1)Δx2Δ(x1x0)Δx1Δx0,Δy1=Δx4Δ(x3x2)Δ(x3x1)Δx3Δ(x2x1)Δx2Δx1Δx0,Δy2=Δ(x4x3)Δx4Δx2Δx1,Δy3=Δ(x4x0)Δx4Δ(x3x0)Δx3Δx2Δx1Δx0,Δy4=Δ(x4x1)Δx4Δx3Δ(x1x0)Δx1. (A.1)

Then substitute equation (8) with the values, where we always have Δy0=1,Δy1=Δy2=Δy3=Δy4=0.

Proof of equation (6)

We have Δx0=1, Δx1=1, Δx2=0, Δx3=0, Δx4=1.

  • Focusing on Δy2, we can get Δy2=Δ(x3x4)=0. For Δx4=1, then x3=0.

  • So the values of the monomials formally like x3xi are all equal to zero so that Δx3xi=0. Substitute this into Δy0, we can get Δ(x1x2)=1. Similarly because Δx1=1, x2=1 can be got.

  • Using the same way, then observing the other 3 equations, there is Δy3=Δ(x0x4)1=0. Based on that condition, we get x0x4=0.

Proof of equation (7)

We have Δx0=0, Δx1=0, Δx2=0, Δx3=1, Δx4=1.

  • Just like the method used above, we first substitute the values known and derive new conditions and then substitute until there are no new conditions. First observing Δy4, we can get Δy4=Δ(x4x1). For Δx4=0, x1=0 can be got. And then the monomials formally like Δ(x1xi)=0.

  • Then we further substitute x1=0 into Δy1. We can get Δy1=Δ(x3x2)=0, so x2=0 can be got.

  • And then observing Δy2, there are Δy2=Δ(x4x3)=0. So we get x3x4=1.

Proof of equation (8)

We have Δx0=0, Δx1=1, Δx2=0, Δx3=0, Δx4=1. We eliminate some redundant steps here.

  • We start the derivation process from Δy2 because this equation Δy3=Δ(x4x3)=0 is the simplest compared to other 4. We can get x3=0 so that all the values of the monomials formally like Δ(x3xi) are equal to 0.

  • Then the equation of Δy3 can be simplified into Δ(x4x0)=0. We can get one more constraint x0=0. And it's the same as above, all the values of the monomials formally like Δ(x0xi) are equal to 0.

  • Substituting the values we got above into Δy4, we can get x1x4=1.

  • At last, substituting all the values we have got into Δy1, we can get x2=0.

Appendix B. Derivation process in Section 4.2

The complete derivation process in Table 7 and Table 8 of Section 4 is shown in Table B.9.

Table B.9.

The derivation process between Table 7 to Table 8 (for simplicity, x = S0,0s, a = S0,0s19, b = S0,0s28, y = S1,0).

Step Known bits Derived bits
1 a[55]=b[55]=y[55]=0 x[55]=a[36]=b[27]=0
2 a[13]=1,b[13]=[13]=0 x[13]=a[58]=b[49]=1
3 a[9]=b[9]=y[9]=0 x[9]=a[54]=b[45]=0
4 x[8]=b[8]=y[8]=0 b[8]=x[36]=a[27]=0
5 x[36]=a[36]=b[36]=0 y[36]=0
6 x[0]=a[0]=b[0]=0 y[0]=0
7 x[28]=b[28]=y[28]=0 a[28]=x[47]=b[19]=0
8 x[31]=a[31]=b[31]=0 y[31]=0
9 x[54]=a[54]=y[54]=0 b[54]=x[18]=a[63]=0
10 x[63]=a[63]=b[63]=0 y[63]=0
11 x[18]=a[18]=y[18]=0 b[18]=x[46]=a[27]=0
12 x[27]=a[27]=b[27]=0 y[27]=0
13 x[37]=a[37]=y[37]=0 b[37]=x[1]=a[46]=0
14 x[46]=a[46]=b[46]=0 y[46]=0

Data availability

Data is contained within the article.

References

  • 1.Bovy E., Daemen J., Mennink B. Radboud University; 2020. Comparison of the second round candidates of the nist lightweight cryptography competition. Bachelor Thesis. [Google Scholar]
  • 2.Dobraunig C., Eichlseder M., Mendel F., Schlffer M. Ascon v1.2: lightweight authenticated encryption and hashing. J. Cryptol. 2021;34(3) [Google Scholar]
  • 3.Dobraunig C., Eichlseder M., Mendel F., Schläffer M. Ascon v1, submission to round 1 of the CAESAR competition. 2014. https://competitions.cr.yp.to/round1/asconv1.pdf
  • 4.Dobraunig C., Eichlseder M., Mendel F., Schläffer M. Ascon v1.1, submission to round 2 of the CAESAR competition. 2015. https://competitions.cr.yp.to/round2/asconv11.pdf
  • 5.Dobraunig C., Eichlseder M., Mendel F., Schläffer M. Ascon v1.2, submission to round 1 of the NIST lightweight cryptography project. 2019. https://csrc.nist.gov/CSRC/media/Projects/Lightweight-Cryptography/documents/round-1/spec-doc/ascon-spec.pdf
  • 6.Dobraunig C., Eichlseder M., Mendel F., Schläer M. 2020. Status update on ascon v1.2. [Google Scholar]
  • 7.Dobraunig C., Eichlseder M., Mendel F., Schlffer M. 2016. Ascon - submission to the caesar competition. [Google Scholar]
  • 8.C. Dobraunig, M. Eichlseder, F. Mendel, et al., A v1. 2–analysis of security and efficiency.
  • 9.Tezcan C. 2nd International Conference on Information Systems Security and Privacy. 2016. Truncated, impossible, and improbable differential analysis of ascon. [Google Scholar]
  • 10.L. Zheng, X. Dong, X. Wang, Conditional cube attack on round-reduced ascon, 2017.
  • 11.Li Yanbin, Zhang G., Wang W., Wang M. Cryptanalysis of round-reduced ascon. Sci. China Inf. Sci. 2017;03 [Google Scholar]
  • 12.C. Dobraunig, M. Eichlseder, F. Mendel, M. Schläffer, Preliminary analysis of ascon-xof and ascon-hash, 2019.
  • 13.Zong R., Dong X., Wang X. Collision attacks on round-reduced gimli-hash/ascon-xof/ascon-hash. IACR Cryptol. ePrint Arch. 2019;2019:1115. [Google Scholar]
  • 14.F. Liu, T. Isobe, W. Meier, Automatic verification of differential characteristics: application to reduced gimli, 2020.
  • 15.Gérault D., Peyrin T., Tan Q.Q. Universitatsbibliothek der Ruhr-Universitat Bochum; 2021. Exploring Differential-Based Distinguishers and Forgeries for Ascon. [Google Scholar]
  • 16.Qin L., Zhao B., Hua J., Dong X., Wang X. Weak-diffusion structure: meet-in-the-middle attacks on sponge-based hashing revisited. 2023. https://eprint.iacr.org/2023/518 Cryptology ePrint Archive, Paper 2023/518.
  • 17.X. Wang, X. Lai, D. Feng, C. Hui, X. Yu, Cryptanalysis of hash functions md4 and ripemd, 2004.
  • 18.G. Bertoni, J. Daemen, M. Peeters, G.V. Assche, Sponge functions, ecrypt hash workshop, 2007.

Associated Data

This section collects any data citations, data availability statements, or supplementary materials included in this article.

Data Availability Statement

Data is contained within the article.


Articles from Heliyon are provided here courtesy of Elsevier

RESOURCES