Next Article in Journal
Numerical Modeling of the Spread of Cough Saliva Droplets in a Calm Confined Space
Previous Article in Journal
Designing Tasks for Introducing Functions and Graphs within Dynamic Interactive Environments
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Analysis and Correction of the Attack against the LPN-Problem Based Authentication Protocols

by
Siniša Tomović
1,2,*,
Milica Knežević
1,2 and
Miodrag J. Mihaljević
1
1
Mathematical Institute of the Serbian Academy of Sciences and Arts, Kneza Mihaila 36, 11000 Belgrade, Serbia
2
Faculty of Technical Sciences, University of Novi Sad, Trg Dositeja Obradovića 6, 21000 Novi Sad, Serbia
*
Author to whom correspondence should be addressed.
Mathematics 2021, 9(5), 573; https://doi.org/10.3390/math9050573
Submission received: 4 February 2021 / Revised: 2 March 2021 / Accepted: 4 March 2021 / Published: 8 March 2021
(This article belongs to the Section Mathematics and Computer Science)

Abstract

:
This paper reconsiders a powerful man-in-the-middle attack against Random-HB# and HB# authentication protocols, two prominent representatives of the HB family of protocols, which are built based on the Learning Parity in Noise (LPN) problem. A recent empirical report pointed out that the attack does not meet the claimed precision and complexity. Performing a thorough theoretical and numerical re-evaluation of the attack, in this paper we identify the root cause of the detected problem, which lies in reasoning based on approximate probability distributions of the central attack events, that can not provide the required precision due to the inherent limitations in the use of the Central Limit Theorem for this particular application. We rectify the attack by employing adequate Bayesian reasoning, after establishing the exact distributions of these events, and overcome the mentioned limitations. We further experimentally confirm the correctness of the rectified attack and show that it satisfies the required, targeted accuracy and efficiency, unlike the original attack.

1. Introduction

The construction of lightweight and secure authentication protocols for RFID (Radio Frequency IDentification) devices is an important task of contemporary cryptography. These devices are employed in supply-chain management, payment and transportation systems, for the tracking of goods and other applications, and are rapidly becoming one of the most pervasive technologies. An RFID system usually consists of two entities—a resource-constrained Tag attached to a physical object and a more computationally powerful Reader, which communicate using authentication protocol in order to validate Tag by the Reader. Reaching high security requirements for such validation while minimizing its resources cost is a very active research area [1,2,3]. One of the important families of authentication protocols for RFID systems is the HB family.
The HB family originates from a lightweight protocol called HB that was proposed by Hopper and Blum [4] and is built over the hardness of the Learning Parity in Noise (LPN) problem. Informally, the LPN problem could be considered as a problem of solving an overdefined system of consistent linear equations over GF(2), the field with two elements, where certain equations are available only in a corrupted form. While the HB protocol resists passive (eavesdropping) attacks, it is shown to be vulnerable against an active adversary who can impersonate a reader and interact with legitimate tags. A modified protocol named HB+ [5,6] was proposed with the aim of addressing this weakness. Soon after, it was shown that the HB+ protocol is defenseless against a stronger adversary who can modify the messages sent by the reader [7]. This attack is known as the GRS man-in-the-middle (MIM) attack. In order to avoid the GRS-MIM attack, different protocol variants were proposed (see, for example, HB++ [8] and HB-MP [9]). However, they were shown to be vulnerable [10], until the HB# and Random-HB# protocols were introduced in [11] and proven to be secure against GRS-MIM. Shortly thereafter, Ouafi, Overback and Vaudenay proposed a more general MIM attack (OOV, by authors’ initials) [12] against HB# and Random-HB#. The attack implies an adversary that can modify the messages exchanged in both directions between the tag and the reader. Moreover, OOV can be regarded as a generic attack against the HB-family. The OOV attack remains one of the keystones in the analysis of HB-like authentication schemes and it is recognized as essential in the security evaluation of any novel HB-like protocol [1].
Some other HB-protocol variants are: HB-MP+ [13], HB-MP++ [14], HB-MP* [15], Trusted-HB [16], NLHB [17], HBN [18], GHB# [19], HB+PUF [20], PUF-HB [21], and Tree-LSHB [22,23]. However, many of these HB-family protocols have been shown to be vulnerable against several cryptanalysis techniques and MIM attacks [1,7,10,12]. For a detailed overview of the HB-protocols and analysis based on their efficiency and resistance against attacks, see, for example, [24].
Motivation for the work. Recent results presented in [25] showed that the OOV attack is significantly less successful than it was claimed in [12] and pointed out malfunctioning in the core component of the attack. The estimated complexity of the attack is 18 % higher for HB# and 55 % for Random-HB# than the claimed, in the case of the standard parameter set II. This is a significant increase having in mind the overall complexity and time consumption of the attack, which is claimed to be 2 29.4 for Random-HB#, and 2 21 for HB#. In this paper, we continue on this investigation path and revise the theoretical and numerical analysis behind the attack provided in [12], in order to determine the cause of the mentioned problem and try to solve it, if possible.
Summary of the results. This paper revises the cryptanalysis from [12] providing proof and explaining why the approximations of the probability distributions employed in the core component of the attack are inappropriate in the considered context, which results in lower precision and higher complexity of the OOV attack [12]. Further, this paper provides a derivation of the correct probability distributions on the number of successful authentications that leaks secret information, which can be used to recover secret keys. Finally, a correction of the OOV attack is proposed, which uses the derived, correct probability distributions, satisfying the targeted performances/complexity.
Organization of the work.Section 2 provides background on the HB# and Random-HB# protocols and the OOV attack. Section 3 brings a thorough revision of theoretical analysis behind the OOV attack and points to the critical omissions in it. Section 4 introduces the corrected attack and analyze its performance. Section 5 provides results of experimental analysis. In Section 6, the findings and results presented in the paper are briefly summarized.

2. Preliminaries

A list containing notation used throughout the remainder of the paper is given below.
  • Variables are denoted with normal, bold or capital bold letters (e.g., x, x and X ) if they represent single elements, vectors, or matrices, respectively
  • Z 2 m : set of all m-dimensional binary vectors
  • Z 2 k × m : set of all k × m -dimensional binary matrices
  • x i : i-th element of binary vector x
  • 1 i : binary vector with all zeros, except on the position i
  • x y : bitwise XOR operation of two binary vectors x and y
  • x : the Hamming weight of binary vector x (sum of its elements)
  • x $ X : sampling a value x which follows uniform distribution over a finite set X
  • P r [ A ] : probability of an event A
  • B e r τ : Bernoulli distribution with parameter τ . x B e r τ is sampling of value x such that P ( x = 1 ) = τ , P ( x = 0 ) = 1 τ
  • B i n ( n , p ) : Binomial distribution of n experiments with success probability p of each experiment
  • e B e r τ m : sampling binary vector e Z 2 m such that e i B e r τ , i = 1 , , m
  • N ( μ , σ 2 ) : Normal distribution with mean μ and variance σ 2
  • Φ ( x ) : standard normal cumulative distribution function
  • e r f c ( x ) = 2 Φ ( x 2 ) : complementary error function
  • X n D X : sequence of random variables X 1 , X 2 , X n converges weakly (in distribution) to a distribution X as n
  • P ( w ¯ ) : probability of acceptance during the OOV attack when the Adversary adds noise vector e ¯ , e ¯ = w ¯ to a regular noise vector e in a protocol session, that is, P ( w ¯ ) = P r [ e e ¯ t h r ]
  • P O O V ( w ¯ ) : = Φ ( t h r ( m e ¯ ) τ e ¯ ( 1 τ ) m τ ( 1 τ ) ) : approximation of P ( w ¯ ) used in the OOV attack [12].
The HB family of authentication protocols has attracted a lot of attention because of their simple implementations and the provable security based on the well-known hard problem—Learning Parity with Noise (LPN). Random-HB# and HB# are prominent representatives of this family. Their authentication procedure consists of the following steps [11]—first, the Tag sends a random blinding vector b to the Reader to initiate the authentication and the Reader responds with a random challenge vector a to the Tag. Then Tag sends z = aX bY e to the Reader, where e is a noise vector whose bits independently follow Bernoulli distribution with coefficient τ , and X Z 2 k X × m , Y Z 2 k Y × m are their shared secret keys (random matrices for Random-HB# and so-called Toeplitz matrices for HB#). The Reader validates the Tag, that is, accepts its response, if and only if the Hamming weight aX bY z | | falls under a certain threshold value (see Figure 1). Standard parameters’ values for these protocols are given in Table 1.
The mechanism of the OOV attack proposed in [12] is shown in Figure 2. The adversary:
  • Collects a triplet ( a ¯ , b ¯ , z ¯ = a ¯ X b ¯ Y e ¯ ) of messages exchanged between the Tag and the Reader by eavesdropping one of their communication sessions
  • Replaces each triplet ( a , b , z ) of messages between the Tag and the Reader during n following communication sessions with a triplet ( a a ¯ , b b ¯ , z z ¯ )
  • Counts the number c of “ACCEPT” decisions of the Reader at the end of those n sessions.
The acceptance rate c n , as it turns out, leaks the critical information which reveals the secret values. More precisely, the theoretical analysis from [12] shows that:
c n Φ ( t h r ( m e ¯ ) τ e ¯ ( 1 τ ) m τ ( 1 τ ) ) ,
where Φ is the standard normal cumulative distribution function. This formula allows the adversary to estimate the Hamming weight e ¯ using solely the empirical value c n , for n large enough (Algorithm 1 from [12]).
After the adversary discovers the Hamming weight of the noise vector e ¯ , he can reconstruct the vector by flipping its bits (more precisely, he flips z ¯ = a ¯ X b ¯ Y e ¯ which secretly contains e ¯ ) and measures weight of e ¯ after the flipping. If the weight has increased, the flipped bit was 0, otherwise, it was 1. This way, he reconstructs the noise vector e ¯ and obtains the linear combination a ¯ X b ¯ Y since a ¯ X b ¯ Y = z ¯ e ¯ (Algorithm 2 from [12]). The whole previous procedure is repeated also for other modification triplets ( a ¯ i , b ¯ i , z ¯ i = a ¯ i X b ¯ i Y e ¯ i ) obtained by eavesdropping, until the adversary collects enough of these linear combinations a ¯ i X b ¯ i Y = z ¯ i e ¯ i to form a full system of linear equations. The secret keys X and Y are then recovered as the solution to this system.
As illustrated above, in each corrupted communication session, the Reader computes:
aX b ^ Y z ^ =   aX ( b b ¯ ) Y ( z z ¯ ) =   ( aX bY z ) ( a ¯ X b ¯ Y z ¯ ) =   e     e ¯
and the Tag successfully authenticates iff e     e ¯ t h r , whereas in a regular session, the Tag successfully authenticates iff e t h r . This way, by creating the cumulative noise e e ¯ , the adversary manipulates the verification criterion of the Reader and changes its theoretical acceptance rate from P r [ e t h r ] to P ( w ¯ ) : = P r [ e e ¯ t h r ] Φ ( t h r ( m e ¯ ) τ e ¯ ( 1 τ ) m τ ( 1 τ ) ) .
Let us provide a simple and useful characterization of the OOV attack Algorithm 1 [12] output by introducing the notion of “decision zones.”
Definition 1.
(“OOV decision zones”). OOV w ¯ -decision zone is an interval I w ¯ O O V such that OOV Algorithm 1 estimates e ¯ as w ¯ iff c n I w ¯ O O V .
After eavesdropping a triplet, the adversary considers all weights of the noise vector e ¯ possible. He decides that e ¯ is w ¯ w ¯ 1 2 P O O V 1 ( c n ) < w ¯ + 1 2 c n I w ¯ O O V = ( P O O V ( w ¯ + 1 2 ) , P O O V ( w ¯ 1 2 ) ] , since P is a monotone decreasing function (see Figure 3a).
After flipping a bit in the noise vector, whose weight is previously estimated as w ¯ , the adversary considers only two weights possible: w ¯ 1 and w ¯ + 1 , so there are two decision zones — I w ¯ 1 O O V = ( P O O V ( w ¯ ) , ) and I w ¯ + 1 O O V = ( , P O O V ( w ¯ ) ] (see Figure 3b).
In [12], the complexity of the OOV attack is estimated as an overall number of modified authentication sessions, which is minimized if the expected noise vector weight w e x p coincides with the so-called optimal weight when it is polynomial (for weights not near enough the optimal one, it becomes exponential). To achieve this, different strategies are introduced in [12], such as flipping the adequate number of last bits when w e x p w o p t before weight measurement, or removing the already recovered 1-bits when w e x p w o p t .
Also, ref [12] provides an optimized version of the attack which uses flipping block-by-block in the noise vector recovery process instead of bit-by-bit. However, it is observed empirically in [25] that the actual benefit that this optimized version brings is somewhat overestimated. An explanation was offered that it uses insufficient sample sizes for decision making when measuring the weights, which are further away from the optimal one.

3. Revision of the OOV Attack

The previous work [25] has shown that the OOV attack predominantly incorrectly estimates weights of noise vectors. The probability of key recovery, that is, efficiency of the attack, is shown to be significantly lower compared to the values claimed in [12]. For the standard parameter set II, the probability of correct key recovery is shown to be 0.158 in the case of HB# and 10 7 in the case of Random-HB#. The analysis presented in [25] reveals that, in order to achieve the precision of key recovery claimed in [12], it is necessary to increase the number of intercepted authentications by 18% in the case of HB# and by 55% in the case of Random-HB#. Since the number of intercepted authentication sessions is the unit of the attack complexity, the complexity increases accordingly. Furthermore, the analysis from [25] shows that the weight estimation error cannot be corrected by taking a larger “sample” n, i.e., larger number of intercepted authentication sessions. On the contrary, by increasing the sample, the quality of the weight estimate worsens. So, for example, experimental evaluation on the standard parameter set II shows that the percentage of correctly estimated weights is only 5%, even if a very large number of modifications is used (for more details, see Section 4.4 in [25]).
This has led us to conduct a thorough revision of cryptanalysis from [12], which we provide in this Section. We shall prove that the attack’s erroneous output is caused by inadequate, non-Bayesian inference over improper, approximate probability distributions of acceptance rates, which cannot be improved due to Central limit theorem application limitations for these protocols. We identify the exact distributions and the exact error of the approximations from [12]. Then we employ Bayesian reasoning over the exact distributions to construct proper decision zones, and show how OOV weight decision making proposed in [12] deviates significantly from the proper, Bayesian one.

3.1. Revision of the Theoretical Analysis behind the OOV Weight Estimate

Here, we revise the derivation of approximations of acceptance rates used in the OOV weight estimate process and report their significant imprecision. Specifically, this derivation is given in the “Correctness” paragraph, Section 2.1 in [12].

3.1.1. Incorrect Claim that Cumulative Noise Vector e e ¯ Follows Binomial Distribution

The mentioned paragraph begins with calculation of the probability that i-th bit of cumulative noise vector e e ¯ is 1:
P r [ ( e e ¯ ) i = 1 ] = τ , e ¯ i = 0 1 τ , e ¯ i = 1
Then it says (exact quotation): “Hence, m w ¯ bits of e e ¯ follow a Bernoulli distribution of parameter τ and the other w ¯ bits follow a Bernoulli distribution of parameter 1 τ , thus e     e ¯ follows a binomial distribution.” [12].
However, that is not correct: e e ¯ does not follow binomial distribution, because that is by definition a distribution of sum of independent and identically distributed Bernoulli trials i.e., of the same parameter (probability of success). Here, the Hamming weight of cumulative noise e e ¯ = i = 1 m ( e e ¯ ) i , as we can see, is a sum of Bernoulli trials of mixed parameter values τ or 1 τ and actually corresponds to a more general so-called Poisson-Binomial Distribution. We elaborate more on this distribution in the upcoming Section 3.2.

3.1.2. Approximation of Acceptance Rates P ( w ¯ ) P O O V ( w ¯ ) without Error Estimation

The “Correctness” paragraph [12] continues with the calculations of the expected weight of the vector e e ¯ as μ = E ( e e ¯ ) = w ¯ ( 1 τ ) + ( m w ¯ ) τ and its variance σ 2 = V a r ( e e ¯ ) = m τ ( 1 τ ) , which are correct, and derives approximation of acceptance rate during the attack:
P ( w ¯ ) = P r [ e e ¯ t h r ] Φ t h r ( m w ¯ ) τ w ¯ ( 1 τ ) m τ ( 1 τ ) ,
where Φ is the standard normal cumulative distribution function, by referring to the Central Limit Theorem (CLT)—Formula (1) in [12].
Here, ref [12] applies CLT to sum e e ¯ without discussing the magnitude of error of this approximation—the theorem itself only points to its convergence when m .

3.1.3. Unknown Error Bound of the Weight Estimate Process

In the rest of the “Correctness” paragraph [12], the authors merge previous approximation (1) with the second one (which is a consequence of the Law of large numbers):
c n P ( w ¯ )
to conclude that:
c n Φ ( t h r ( m w ¯ ) τ w ¯ ( 1 τ ) m τ ( 1 τ ) ) = : P O O V ( w ¯ ) .
The idea behind the merging of the two approximations can be explained in the following way: c / n converges to P ( w ¯ ) when n (by the Law of large numbers), while  | P O O V ( w ¯ ) P ( w ¯ ) | converges to 0 when m (by the Central Limit Theorem). Thus, c / n gets arbitrarily close to P O O V ( w ¯ ) , if both n and m are large enough. This can be represented as:
c n n Law   of   large   numbers P ( w ¯ ) m C L T P O O V ( w ¯ ) c n P O O V ( w ¯ ) .
Unlike P ( w ¯ ) P O O V ( w ¯ ) , ref [12] actually does derive error for c n P ( w ¯ ) approximation, and how large n should be in order to make the error negligible:
c n ( P ( w ¯ ) | r P ( w ¯ ) | , P ( w ¯ ) + | r P ( w ¯ ) | ) with probability 1 e r f c ( θ ) for n ( r , w ¯ ) = θ 2 r 2 R ( w ¯ ) (Formula (2) in [12]) where e r f c ( θ ) gets exponentially small as θ (i.e., n) increases asymptotically. Therefore, c n is used to estimate P ( w ¯ ) for n large enough.
However, as the final approximation (3) contains estimate P ( w ¯ ) P O O V ( w ¯ ) whose error was not assessed in [12], its error is also unknown. The bound of the error for (3) is essential, because if these approximate values P O O V ( w ¯ ) deviate too much from the actual P ( w ¯ ) values, it could lead to the wrong decision of w ¯ . Let us remember that in the OOV attack the weight of noise vector e ¯ is w ¯ , if P O O V 1 ( c n ) is closest to w ¯ , for all possible values of w ¯ .

3.1.4. Main Conclusions

We summarize the mistakes in the theoretical analysis behind the OOV attack from [12], found in the analysis given above, which will turn out as crucial for high error rate of the OOV weight estimate:
  • The distribution of the Hamming weight of cumulative noise vector is wrongly assessed as Binomial,
  • Approximation P ( w ¯ ) P O O V ( w ¯ ) lacks error estimation,
  • The error of the weight estimate procedure is unknown. Since error bound of P ( w ¯ ) P O O V ( w ¯ ) is unknown, this consequently also stands for the final approximation c n P O O V ( w ¯ ) which produces the output of weight estimate procedure.
In the following sections, we introduce our research process to overcome the listed omissions.

3.2. Error Estimation of Acceptance Rates Approximation P ( w ¯ ) P O O V ( w ¯ )

First, we infer the standard upper error bound of P ( w ¯ ) P O O V ( w ¯ ) by applying Berry-Esseen inequality for CLT approximations. The obtained result indicates that distance between P ( w ¯ ) and P O O V ( w ¯ ) could be too high and thus prevent a correct weight estimation. Then, we proceed to infer the exact distribution of the acceptance rates and the exact error of this approximation.

3.2.1. Standard Upper Error Bound for CLT Approximations

Approximation P ( w ¯ ) = P r [ e e ¯ t h r ] P O O V ( w ¯ ) = Φ ( t h r ( m w ¯ ) τ w ¯ ( 1 τ ) m τ ( 1 τ ) ) was derived in [12] using the CLT, which only implies its convergence when m . The Berry-Eseen inequality further refines this result by providing bound on its maximal error. Here, we show that the sum e e ¯ follows Poisson-Binomial distribution, not the plain Binomial distribution as claimed in [12]. Then we apply a general CLT for non-identical random variables to this distribution in order to obtain P ( w ¯ ) P O O V ( w ¯ ) , and we estimate its precision using the Berry-Eseen inequality.
Definition 2.
Poisson-Binomial distribution is a probability distribution of a sum i = 0 n X i of independent Bernoulli random variables X 1 , , X n with possibly different probabilities of success p 1 , , p n , and we denote it by PB ( p 1 , , p n ) . Binomial distribution is a special case of the Poisson-Binomial distribution where X 1 , , X n share the same probability of success.
Lemma 1.
The Hamming weight of cumulative noise vector e e ¯ , where e ¯ = w ¯ , which the Reader computes in the verification phase after MIM modification ( a ¯ , b ¯ , z ¯ = a ¯ X b ¯ Y e ¯ ) of Random HB# or HB# protocol session, follows Poisson-Binomial distribution
PB ( 1 τ , , 1 τ w ¯ , τ , , τ m w ¯ ) .
Proof. 
Since a new noise vector e B e r τ m is being generated in each modification session, and e ¯ B e r τ m remains fixed during all modifications, notice that:
e e ¯ = k = 1 m ( e k e ¯ k ) = k = 1 e ¯ k = 1 m ( e k 1 ) + k = 1 e ¯ k = 0 m e k = k = 1 w ¯ s ˜ k + k = 1 m w ¯ s k ,
where s k and s ˜ k are Bernoulli random variables, such that P r [ s k = 1 ] = τ and P r [ s ˜ k = 1 ] = 1 τ (see Figure 4).
Therefore, e e ¯ PB ( 1 τ , , 1 τ w ¯ , τ , , τ m w ¯ ) .  □
Theorem 1
(General CLT, Lyapunov condition [26]). Let X 1 , X 2 be a sequence of independent (and not necessarily identical) random variables such that E X i = μ i , V a r X i = σ i 2 < and D n 2 = V a r ( i = 1 n X i ) = i = 1 n σ i 2 . If there is δ > 0 such that:
lim n 1 D n 2 + δ i = 1 n E ( | X i μ i | ) 2 + δ = 0 ( Lyapunov condition )
then the distributions of i = 1 n X i i = 1 n μ i D n converge weakly to N ( 0 , 1 ) as n , that is,
i = 1 n X i i = 1 n μ i D n D N ( 0 , 1 ) .
Theorem 2
(General CLT for Poisson-Binomial distribution). If random variable X follows Poisson-Binomial distribution i.e., X = i = 1 n X i , X i B e r p i , where D n 2 = V a r ( X ) = i = 1 n p i ( 1 p i ) , and D n ( n ) , then:
X i = 1 n p i D n D N ( 0 , 1 ) .
Proof of Theorem 2. 
Let μ i = E ( X i ) = p i . We prove the Lyapunov condition is satisfied for δ = 1 .
Since X i : 1 0 p i 1 p i , | X i μ i | 3 : ( 1 μ i ) 3 μ i 3 p i 1 p i , we have that:
E | X i μ i | 3 = ( 1 μ i ) 3 p i + μ i 3 ( 1 p i ) = ( 1 p i ) 3 p i + p i 3 ( 1 p i ) = p i ( 1 p i ) [ ( 1 p i ) 2 + p i 2 ] = p i ( 1 p i ) [ 1 2 p i ( 1 p i ) ] p i ( 1 p i ) , i = 1 , , n .
Therefore i = 1 n E ( | X i μ i | ) 3 i = 1 n p i ( 1 p i ) = D n 2 and
1 D n 3 i = 1 n E ( | X i μ i | ) 3 D n 2 D n 3 = 1 D n 0 ( n ) .
 □
Since μ = E ( e e ¯ ) = w ¯ ( 1 τ ) + ( m w ¯ ) τ and V a r ( e e ¯ ) = m τ ( 1 τ ) , as a direct consequence of Theorem 2 and Lemma 1, we have that:
Lemma 2.
For the cumulative noise vector e e ¯ it holds that:
e e ¯ ( m w ¯ ) τ w ¯ ( 1 τ ) m τ ( 1 τ ) D N ( 0 , 1 ) , m .
In order to estimate the precision of this approximation, we proceed to use the standard error measure for general CLT:
Theorem 3
(Berry-Eseen inequality for non-identical random variables [27]). Let X 1 , , X n be independent random variables such that E X i = 0 , V a r X i = σ i 2 , and D n 2 = V a r ( i = 1 n X i ) = i = 1 n σ i 2 . Then for every n there is an absolute constant C such that:
sup x R P r X D n x Φ ( x ) C · i = 1 n E | X i | 3 D n 3 .
It was proven that 0.4097 10 + 3 6 2 π = C 0 C C 1 = 0.5600 ([28]). C 0 is the biggest known lower bound and C 1 the smallest known upper bound for C in literature, to the best of our knowledge.
Theorem 4
(Berry-Eseen inequality for Poisson-Binomial distribution). If random variable X follows Poisson-Binomial distribution, that is, X = i = 1 n X i , X i B e r p i , where D n 2 = V a r ( X ) = i = 1 n p i ( 1 p i ) , and D n ( n ) , then for every n there is a constant C [ C 0 , C 1 ] such that:
sup x R P r X i = 1 n p i D n x Φ ( x ) C · i = 1 n p i ( 1 p i ) [ ( 1 p i ) 2 + p i 2 ] D n 3
Proof. 
Let Y i = X i μ i , μ i = E X i = p i . Then E Y i = 0 , V a r ( Y i ) = p i ( 1 p i ) and E | Y i | 3 = p i ( 1 p i ) [ ( 1 p i ) 2 + p i 2 ] (see proof of Theorem 2). The claim follows directly by applying Berry-Eseen inequality to random variables Y 1 , , Y n .  □
Lemma 3.
For the cumulative noise vector e e ¯ it holds that:
sup x R P r e e ¯ ( m w ¯ ) τ w ¯ ( 1 τ ) m τ ( 1 τ ) x Φ ( x ) C · [ ( 1 τ ) 2 + τ 2 ] m τ ( 1 τ ) ,
where C [ C 0 , C 1 ] .
Proof. 
This is a direct consequence of the inequality above, taken in consideration that: e e ¯ = i = 1 m X i , X i B e r p i , p i = 1 τ , i = 1 , , w ¯ τ , i = w ¯ + 1 , , m ,
i = 1 m p i = ( m w ¯ ) τ + w ¯ ( 1 τ ) ,
D m 2 = V a r ( X ) = m τ ( 1 τ ) ,
i = 1 n p i ( 1 p i ) [ ( 1 p i ) 2 + p i 2 ] = m τ ( 1 τ ) [ ( 1 τ ) 2 + τ 2 ] = D m 2 [ ( 1 τ ) 2 + τ 2 ] .  □
As a consequence of this Lemma, by taking x = t h r μ σ , μ = ( m w ¯ ) τ + w ¯ ( 1 τ ) and σ 2 = m τ ( 1 τ ) , the standard Berry-Eseen upper bound estimate for the error of the approximation P ( w ¯ ) P O O V ( w ¯ ) is:
P r [ e e ¯ t h r ] Φ t h r μ σ C ¯ ,
where C ¯ [ C 0 · [ ( 1 τ ) 2 + τ 2 ] σ , C 1 · [ ( 1 τ ) 2 + τ 2 ] σ ] .
Using Formula (5) we derive that for the standard parameter set I, where τ = 0.25 and m = 1164 , the error upper bound lies in the interval [ 0.017334 , 0.023691 ] , while for the standard parameter set II, where τ = 0.125 and m = 441 , the error upper bound is from the interval [ 0.046091 , 0.062994 ] .
The exact P ( w ¯ ) lies somewhere in the interval [ ( P O O V ( w ¯ ) C ¯ , P O O V ( w ¯ ) + C ¯ ] . Nevertheless, this interval is wider, i.e., covers the interval in which the adversary has to decide between adjacent weights w ¯ and w ¯ + 1 (see Figure 5). It is possible that the adversary is incapable to determine and decide accurately if c n is closest to P ( w ¯ ) or P ( w ¯ + 1 ) , which directly jeopardizes his decision making. For example, if c n is in the position marked in Figure 6, the adversary will decide that the weight is w ¯ , because P O O V ( w ¯ ) is closest to it, but since c n is in a possible location of P ( w ¯ + 1 ) , it could in fact be closest to P ( w ¯ + 1 ) , and the actual weight could be w ¯ + 1 . In order to investigate possibility of such scenarios of erroneous weight conclusions due to high error of approximation, in the next Section, we shall determine where precisely are P ( w ¯ ) values.

3.2.2. The Exact Distribution of the Acceptance Rates

Here, we calculate the exact acceptance rate of HB# and Random-HB# protocols while under the OOV attack, by using Lemma 1 from Section 3.2.1.
Theorem 5.
Let P ( w ¯ ) = P [ e e ¯ t h r ] denote the probability of successful authentication after MIM modification using triplet ( a ¯ , b ¯ , z ¯ = a ¯ X b ¯ Y e ¯ ) of exchanged messages caught in a Random HB# or HB# protocol session, where w ¯ = e ¯ . Then:
P ( w ¯ ) = P B ( w ¯ ) : = j = 0 t h r i = max { 0 , j + w ¯ m } min { w ¯ , j } w ¯ i m w ¯ j i τ w ¯ + j 2 i ( 1 τ ) m ( w ¯ + j 2 i ) .
In addition, if c is the number of successful authentications after n MIM modifications, then for acceptance rate c n it holds that
c n B i n ( n , P ( w ¯ ) ) n .
Proof. 
Since:
e e ¯ = k = 1 m ( e k e ¯ k ) = k = 1 e ¯ k = 1 m ( e k 1 ) + k = 1 e ¯ k = 0 m e k = k = 1 w ¯ s ˜ k + k = 1 m w ¯ s k ,
where s k B e r τ , s ˜ k B e r 1 τ (see Proof of Lemma 1) we have that:
P ( w ¯ ) = P r [ e e ¯ t h r ] = j = 0 t h r P r [ e e ¯ = j ] = j = 0 t h r P r [ k = 1 w ¯ s ˜ k + k = 1 m w ¯ s k = j ] = j = 0 t h r i = 0 j P r [ k = 1 w ¯ s ˜ k = i ] · P r [ k = 1 m w ¯ s k = j i ] | i w ¯ , j i m w ¯ = j = 0 t h r i w ¯ j i m w ¯ i = 0 j w ¯ i ( 1 τ ) i τ w ¯ i m w ¯ j i τ j i ( 1 τ ) m w ¯ j + i = j = 0 t h r i = max { 0 , j + w ¯ m } min { w ¯ , j } w ¯ i m w ¯ j i τ w ¯ + j 2 i ( 1 τ ) m ( w ¯ + j 2 i ) .
 □
(Number of successes in w ¯ Bernoulli experiments can not exceed w ¯ . Similarly for m w ¯ .)

3.2.3. Exact Error of the Approximation P ( w ¯ ) P O O V ( w ¯ )

Finally, we are able to derive the exact error of the P O O V approximation as:
| P ( w ¯ ) P O O V ( w ¯ ) | = | j = 0 t h r i = max { 0 , j + w ¯ m } min { w ¯ , j } w ¯ i m w ¯ j i τ w ¯ + j 2 i ( 1 τ ) m ( w ¯ + j 2 i ) Φ t h r μ σ | ,
where μ = ( m w ¯ ) τ + w ¯ ( 1 τ ) and σ 2 = m τ ( 1 τ ) .
Although, in theory, this error diminishes for m large enough (see Figure 7), in the OOV attack m is the dimension of secret matrices. Thus, this error is a constant intrinsic to the protocol and the adversary is unable to manipulate it.
The exact error values for standard protocol parameters are shown in Figure 8.
Note that the error gets higher as w ¯ approaches the claimed optimal weight w o p t , where it reaches its maximum. This weight is 228 for the standard parameter set I, while it is 77 for the other one.

3.3. Proper Decision Zones

The OOV decision zones, which are based on the inverse function P O O V 1 ( c n ) values, have the following potential drawbacks, in general case:
  • the inverse function might not preserve the ratios of distances, so, for example, it could be possible that P 1 ( c n ) is closer to w ¯ than to w ¯ + 1 , while c n is actually closer to P ( w ¯ + 1 ) than to P ( w ¯ ) ,
  • P O O V is used as an approximation of exact acceptance rates P with unknown precision,
  • w ¯ should be determined by considering which of the possible distributions is c n most likely sampled from, i.e., by probabilistic reasoning, instead of simply applying the inverse function to c n value.
We employ the Bayesian reasoning over the exact distributions of acceptance rates to construct proper decision zones. The noise vector weight e ¯ is estimated as w ¯ if the observed empirical acceptance frequency c n most likely follows the exact distribution B i n ( n , P ( w ¯ ) ) n , w ¯ W , where W is the set of all the weights w ¯ the adversary considers possible.
As a general weight decision rule, w ¯ = argmax w W P r [ e ¯ = w | c n   observed   acceptance   rate ) ] = argmax w W { P ( w ) c n ( 1 P ( w ) ) 1 c n · P o c c u r ( w ) 1 n } , where P o c c u r ( w ) = P r [ e ¯ = w ] is the probability of occurrence of noise vector whose weight is w. By its logarithmic transformation, we obtain that the adversary decides the noise vector weight as w ¯ iff:
w ¯ = argmax w W { F ( c , n ) = c 0 ( w ) + c 1 ( w ) c n } ,
where c 0 ( w ) = l o g ( 1 P ( w ) ) + l o g ( P o c c u r ( w ) ) n , c 1 ( w ) = l o g P ( w ) 1 P ( w ) . After the mere eavesdropping, P o c c u r ( w ) = m w τ w ( 1 τ ) m w . If the eavesdropped vector was flipped in f positions to reach optimal weight, P o c c u r ( w ) = P B ( f , m , τ , w ) P B ( f , m , τ , w 1 ) . When recovering bits, P o c c u r ( w 1 ) = τ and P o c c u r ( w + 1 ) = 1 τ . The values P ( w ) and P o c c u r ( w ) may be calculated in advance, so decision making is highly efficient.
However, when considering weights near w o p t and standard parameter sets, for n large enough, the decision making can be further simplified. Namely, after comparing variances V a r ( w ) = P ( w ) ( 1 P ( w ) ) n of the exact distributions for the consecutive weights w 1 , w and w + 1 in such case, we have found their differences as insufficient to impact the Bayesian decision. Also, probabilities of occurrence of these weights produce negligible priors (observe division by n in c 0 ( w ) ).
Therefore, because these distributions B i n ( n , P ( w ¯ ) ) n D N ( P ( w ¯ ) , V a r ( w ¯ ) ) are almost symmetrical, for all practical purposes, w ¯ -decision zones will be ( P ( w ¯ ) + P ( w ¯ + 1 ) 2 , P ( w ¯ 1 ) + P ( w ¯ ) 2 ) , w ¯ = 1 , , m after eavesdropping, while they will be ( , P ( w ¯ 1 ) + P ( w ¯ + 1 ) 2 ) and ( P ( w ¯ 1 ) + P ( w ¯ + 1 ) 2 , ) when deciding between w ¯ + 1 and w ¯ 1 after flipping a bit. We shall also call them “PB-decision zones", since they use the exact values P ( w ¯ ) = P B ( w ¯ ) . Figure 9 provides a graphical illustration of the PB-decision zones used in the processes of weight estimate after eavesdropping and bit recovery.
Expressed more formally—probability that c n is sampled from N ( P ( w ¯ ) , V a r ( w ¯ ) ) is g ( c , n , w ¯ ) = 1 2 π V a r ( w ¯ ) e ( c n P ( w ¯ ) 2 ) 2 V a r ( w ¯ ) P o c c u r ( w ¯ ) , so according to maximum a posteriori (MAP) test, we choose hypothesis W = w ¯ over W = w ¯ + i , i { 1 , 2 } iff g ( c , n , w ¯ ) > g ( c , n , w ¯ + i ) that is,
V a r ( w ¯ + i ) V a r ( w ¯ ) · P o c c u r ( w ¯ ) P o c c u r ( w ¯ + 1 ) e ( c n P ( w ¯ + i ) ) 2 2 V a r ( w ¯ + i ) + ( c n P ( w ¯ ) ) 2 2 V a r ( w ¯ ) = e n 2 ( ( c n P ( w ¯ + i ) ) 2 P ( w ¯ + i ) ( 1 P ( w ¯ + i ) ) ( c n P ( w ¯ ) ) 2 P ( w ¯ ) ( 1 P ( w ¯ ) ) ) ,
that is, iff condition ( c n P ( w ¯ + i ) ) 2 > δ 2 ( c n P ( w ¯ ) ) 2 is satisfied, where δ 2 = P ( w ¯ + i ) ( 1 P ( w ¯ + i ) ) P ( w ¯ ) ( 1 P ( w ¯ ) ) = V a r ( w ¯ + i ) V a r ( w ¯ ) , i.e., c n < B or c n > A when δ < 1 , or A < c n < B when δ > 1 , where A = P ( w ¯ + i ) + δ δ + 1 ( P ( w ¯ ) P ( w ¯ + i ) ) , B = P ( w ¯ ) + δ δ 1 ( P ( w ¯ ) P ( w ¯ + i ) ) . However, since B < 0 for δ < 1 , and B 1 for δ > 1 , for weights near the optimal one, the condition is equivalent to c n > A . Furthermore, P r c n ( P ( w ¯ ) + P ( w ¯ + i ) 2 , A ) | c n D N ( P ( w ) , σ 2 ) , w { w ¯ , w ¯ + i } is negligible in such case, so we reduce this decision to condition c n > P ( w ¯ ) + P ( w ¯ + i ) 2 , that is, that the observed frequency c n is closer to P ( w ¯ ) than to P ( w ¯ + i ) (P is monotone decreasing function).

3.4. The Exact and the Approximate Probability Distribution Relation

We now show that the decisions the adversary makes about noise vectors weights can differ depending on whether he uses the OOV approximation or the exact distribution.
We have noticed that the OOV w-decision zones are substantially shifted to the left with respect to PB-w decision zones, and that they often largely overlap with the correct PB- w + 1 decision zone (see Figure 10). As a consequence, there is a high chance that the OOV adversary decides the weight is w, while the actual weight is w + 1 .
This adverse phenomena is especially pronounced in the expected case—when w ¯ is near the optimal weight w o p t , since there is the biggest distance between P ( w ¯ ) and P O O V ( w ¯ ) —degrading significantly the precision of the weight estimate.
Furthermore, the shift of the OOV decision zones can not be repaired by employing larger “sample size” n, that is, number of intercepted authentications, because the approximation P O O V ( w ¯ ) P ( w ¯ ) has a high fixed error in this scenario (as shown in the previous Section). The convergence c n P O O V ( w ¯ ) occurs only when both m and n :
c n n P ( w ¯ ) m P O O V ( w ¯ ) c n n , m P O O V ( w ¯ ) .
However, in the context of the OOV attack, m is a constant protocol parameter and thus:
c n n P ( w ¯ ) fixed   distance P O O V ( w ¯ ) | c n P O O V ( w ¯ ) | n | P ( w ¯ ) P O O V ( w ¯ ) | .
This explains the experimental observations from [25] that the weight estimate does not improve by increasing the sample size.

4. Correction of the OOV Attack

In this section, we give a correction of the OOV-MIM attack and show that it meets the targeted precision, unlike the original attack.

4.1. Correction of the OOV Attack Algorithm

In order to solve the problem of high error of the approximation P O O V ( w ¯ ) P ( w ¯ ) , we eliminate this approximation altogether, since we have shown that it can not be improved. Instead we employ the acceptance rates obtained from the exact distribution. That is, instead of:
c n n P ( w ¯ ) m P O O V ( w ¯ ) c n P O O V ( w ¯ ) = Φ ( t h r ( m w ¯ ) τ w ¯ ( 1 τ ) m τ ( 1 τ ) ) ,
we use Poisson-Binomial cumulative distribution function:
c n n P ( w ¯ ) c n P ( w ¯ ) = j = 0 t h r i = max { 0 , j + w ¯ m } min { w ¯ , j } w ¯ i m w ¯ j i τ w ¯ + j 2 i ( 1 τ ) m ( w ¯ + j 2 i ) .
Then, we incorporate it in proper, Bayesian decision zones described in Section 3.3 with their corresponding optimal weights and modification samples. Noise vector e ¯ Hamming weight will be estimated as w ¯ if and only if c n is nearest to P ( w ¯ ) , for all weights w { 0 , , m } considered possible.
Hence, the pseudocode of the proposed correction of the weight estimate procedure is given in Algorithm 1:
Algorithm 1PB-OOV weight estimate alg. Approximating w ¯ = e ¯
1:
Input:  a ¯ , b ¯ , z ¯ = a ¯ X b ¯ Y e ¯ , n
2:
Output:  estimate of noise vector weight
     w ¯ = a ¯ X b ¯ Y z ¯ , where
P ( w ¯ ) = j = 0 t h r i = max { 0 , j + w ¯ m } min { w ¯ , j } w ¯ i m w ¯ j i τ w ¯ + j 2 i ( 1 τ ) m ( w ¯ + j 2 i )
3:
Processing:
4:
c = 0
5:
for i = 1 n   do
6:
    During i-th session, the adversary modifies and replaces messages:
7:
     a with a ^ = a a ¯ , b with b ^ = b b ¯ , z with z ^ = z z ¯
8:
    if Verifier accepts the modified response then
9:
         c = c + 1
10:
    end if
11:
end for
12:
return w ¯ = argmin w { | c n P ( w ) | | w = 0 , , m } .
Since the PB Decision zone for w I = [ P ( w ) r ¯ , P ( w ) + r ¯ ] , where r ¯ = 1 2 m i n { P ( w ) P ( w + 1 ) , P ( w 1 ) P ( w ) } we have that:
P r [ c n PB   Decision   zone   for   w ] P r c n I | c n D N ( P ( w ¯ ) , σ 2 ) = 1 e r f c ( θ ) , θ = r ¯ · n 2 P ( w ¯ ) ( 1 P ( w ¯ ) ) .
Therefore, after the eavesdropping, PB-OOV adversary chooses sample of size n P B = 4 θ 2 R P B ( w ) , R P B ( w ) = 2 P ( w ) ( 1 P ( w ) ) r ¯ 2 to achieve the required precision 1 e r f c ( θ ) , which is based on exact values P B ( w ) instead of approximate ones P O O V ( w ) as in Formula (2) from [12]. Accordingly, he uses optimal weight w o p t P B which minimizes this sample across all weights and its value is 229 for parameter set I, and 78 for parameter set II. After the flipping, he will use samples of size θ 2 R P B ( w ) to recover bits.
It should be noted that the values P ( w ) , w = 0 , , m can be calculated in advance, as a part of the preprocessing step, and stored in a table to be later used during the attack.

4.2. Comparison of the OOV and PB-OOV Attack Success

In this section we analyze the probability of success of the OOV and PB-OOV attack. Namely, we derive the probability the OOV adversary will correctly reconstruct a noise vector (and consequently recover the key) and show that, as a consequence of the approximation employed, the OOV attack is significantly less efficient than claimed in [12]. Oppositely, the PB-OOV attack proposed in Section 4.1, achieves the desired precision and efficiency.

4.2.1. Noise Vector Hamming Weight Estimate

OOV adversary. First, let us observe the distribution of acceptance rate c n during the attack when e ¯ = w ¯ :
c = i = 1 n X i , X i B e r P ( w ¯ ) c n D N ( P ( w ¯ ) , σ 2 ( w ¯ , n ) ) ,
where σ = σ ( w ¯ , n ) : = P ( w ¯ ) ( 1 P ( w ¯ ) ) n .
The probability that the OOV adversary estimates that noise vector e ¯ has weight w e s t , when its weight is w ¯ (which may or may not be equal to w e s t ), using n modifications of authentication sessions is:
p 0 ( w e s t , w ¯ , n ) = P r c n OOV   Decision   zone   for   w e s t | e ¯ = w ¯
= P r c n ( P O O V ( w e s t + 1 2 ) , P O O V ( w e s t 1 2 ) ) | c n D N ( P ( w ¯ ) , σ 2 )
= Φ ( P O O V ( w e s t 1 2 ) P ( w ¯ ) σ ) Φ ( P O O V ( w e s t + 1 2 ) P ( w ¯ ) σ ) ,
Therefore, the adversary makes correct decision when e ¯ = w ¯ , using n modifications, with probability p 0 ( w ¯ , w ¯ , n ) .
After evaluating Formula (8), we have found that the weight will either be estimated as one lower (when the adversary is wrong, which is the majority of the time for the weights near the expected ones) or make a correct guess, that is, all other cases will appear with negligible probability (see Table 2). This supports the experimental findings from [25]. Table 2 shows comparison between the claimed and real precision p 0 ( w ¯ , w ¯ , n ) of the OOV weight estimate (see Appendix A Table A1 for details on the parameters’ values). It can be noticed that, for parameter set II, in the case of Random-HB#, the claimed precision is by two orders of magnitude smaller than the claimed. In all other cases, the discrepancy is somewhat smaller but, still, the real precision is by an order of magnitude smaller than the claimed.
PB-OOV adversary. Since ( P ( w ) + P ( w + 1 ) 2 , P ( w 1 ) + P ( w ) 2 ) , w = 1 , , m is PB-w decision zone after the eavesdropping, and PB-OOV adversary uses exact values P ( w ) instead of the approximate ones P O O V ( w ) , by analogous analysis as above, we obtain that he estimates the weight as w e s t when its actual value is w ¯ with probability:
p 0 ( w e s t , w ¯ , n ) = Φ ( P ( w e s t 1 ) + P ( w e s t ) 2 P ( w ¯ ) 2 σ ) Φ ( P ( w e s t ) + P ( w e s t + 1 ) 2 P ( w ¯ ) 2 σ )
Unlike the OOV weight estimate, whose precision is shown to be remarkably lower than the claimed, precision of the PB-OOV weight estimate is within the given boundaries (see Table 3). This is also confirmed by the experimental results presented in Section 5.3.

4.2.2. Noise Vector Bits Recovery

Here, we compare the success rate of the OOV adversary and PB-OOV adversary when it comes to the reconstruction of noise vectors, that is, bit recovery.
OOV adversary. After the adversary has estimated the weight of the observed vector e ¯ as w e s t after eavesdropping, he tries to recover its bits by flipping one by one each bit e ¯ i and estimating new weight as w e s t 1 or w e s t + 1 . If the weight has decreased, he concludes the flipped bit is 1, otherwise, that the bit is 0. Therefore, he recovers a bit correctly, depending on its value, with probabilities:
= P r c n OOV   Decision   zone   for   w e s t 1 , e ¯ i = 1 P r c n OOV   Decision   zone   for   w e s t + 1 , e ¯ i = 0
= P r c n > P O O V ( w e s t ) | c n D N ( P ( w ¯ 1 ) , σ 2 ( w ¯ 1 , n ) ) , e ¯ i = 1 P r c n P O O V ( w e s t ) | c n D N ( P ( w ¯ + 1 ) , σ 2 ( w ¯ + 1 , n ) ) , e ¯ i = 0
= p i 1 ( w e s t , w ¯ , n ) = 1 Φ ( P O O V ( w e s t ) P ( w ¯ 1 ) σ ( w ¯ 1 , n ) ) , e ¯ i = 1 p i 0 ( w e s t , w ¯ , n ) = Φ ( P O O V ( w e s t ) P ( w ¯ + 1 ) σ ( w ¯ + 1 , n ) ) , e ¯ i = 0 .
The results of evaluation of Formula (9) are shown in Table 4. First, it should be noted that the probability for bit recovery is very asymmetrical, that is, the precision for 0-bit recovery is very different from the precision for 1-bit, while the claimed precision is uniform for both bit values. Secondly, when the weight is correctly estimated, the precision for 0-bit is much lower than the claimed and it would make reconstruction of the noise vector (and further the key recovery itself) practically impossible. This is in accordance with the experimental results from [25]. On the other hand, the OOV adversary has more success in bits recovery when the initial weight estimate is incorrect, since the relative change remains intact if the measured weights are both one lower than the actual ones. The two errors made in the weight estimate processes can neutralize each other; however, even with this mutual cancellation of the errors, the claimed precision is not achieved. Namely, the precision for 1-bit recovery is lower than the targeted 1 1 2 e r f c ( θ ) and that lowers the probability of the attack success.
Let us further consider the probability that the OOV adversary will successfully recover a complete noise vector. We observe the expected case e ¯ = w e x p ( = w o p t for parameter set II). As we have already noted: (a) w e s t is either e ¯ or e ¯ 1 , and (b) the noise vector is practically impossible to recover when w e s t = e ¯ due to too high error for 0-bit. Thus, for parameter set II, the probability of the OOV Adversary successfully recovering a complete m-bit noise vector of weight e ¯ = w o p t is:
p v r ( w e x p ) = p v r ( w o p t ) = p 0 p i 0 m w o p t p i 1 w o p t ,
where p 0 = p 0 ( w o p t 1 , w o p t , 4 θ 2 R ( w o p t ) ) , p i k = p i k ( w o p t 1 , w o p t , θ 2 R ( w o p t 1 ) ) , k = 0 , 1 .
Similarly, for parameter set I, the adversary needs to recover and remove Δ = w e s t w o p t errors in a noise vector in order to achieve the optimal weight. This is expected to happen after recovering Δ / τ bits, thus:
p v r ( w e x p ) = p 0 p i 0 * w 0 p i 0 m w e x p w 0 p i 1 * Δ p i 1 w e x p Δ ,
where: p 0 = p 0 ( w e x p 1 , w e x p , 4 θ 2 R ( w e x p ) ) , p i k * = p i k ( w e x p 1 , w e x p , θ 2 R ( w e x p 1 ) ) , p i k = p i k ( w o p t , w o p t + 1 , θ 2 R ( w o p t ) ) , k = 0 , 1 , w 0 = Δ ( 1 τ ) τ = ( w e x p 1 w o p t ) ( 1 τ ) τ .
Using Formulas (10) and (11) we can evaluate the probability that the OOV adversary will correctly recover a complete noise vector in the expected case, and compare the obtained probability with the claimed one, which is calculated based on the claimed probabilities of correct weight estimate and bit guess as ( 1 e r f c ( θ ) ) ( 1 1 2 e r f c ( θ ) ) m . Results of the comparison are given in Table 5. Although the difference between the claimed and real precision on the noise vector level does not seem remarkable for Random-HB#, it does make a significant impact on the key recovery probability, having in mind the number of noise vector that have to be reconstructed, which is 592. More details will be provided in the next Section 4.2.3.
PB-OOV adversary. For the PB-OOV adversary, by replacing P O O V with P, and P O O V ( w e s t ) with P ( w e s t 1 ) + P ( w e s t + 1 ) 2 (i.e., by using proper PB w ¯ -decision zones) in the derivation above, the probabilities of successful bit recovery, depending on its value are:
p i 1 ( w e s t , w ¯ , n ) = 1 Φ ( P ( w ¯ + 1 ) P ( w ¯ 1 ) 2 σ ( w ¯ 1 , n ) ) , e ¯ i = 1 p i 0 ( w e s t , w ¯ , n ) = Φ ( P ( w ¯ 1 ) P ( w ¯ + 1 ) 2 σ ( w ¯ + 1 , n ) ) , e ¯ i = 0 .
Table 6 shows the precision the PB-OOV adversary achieves in the bit recovery process, when the standard parameter sets are employed. The results obtained by evaluating Formula (12) prove that the PB-OOV on the bit level does achieve the targeted precision using the OOV sample (i.e., the number of modifications). This is also confirmed by the experimental results presented in Section 5.3.
Further, we analyze the probability that the PB-OOV adversary will successfully recover a complete noise vector. We observe the expected case e ¯ = w e x p ( = w o p t for parameter set II). For parameter set II, the probability is given by the formula:
p v r ( w o p t ) = p 0 p i 0 m w o p t p i 1 w o p t ,
where p 0 = p 0 ( w o p t , w o p t , θ 2 R w o p t ) ) , p i k = p i k ( w o p t , w o p t , θ 2 R ( w o p t ) ) , k = 0 , 1 .
Similarly, for parameter set I, we have that:
p v r ( w e x p ) = p 0 p i 0 * w 0 p i 0 m w e x p w 0 p i 1 * Δ p i 1 w e x p Δ
where p 0 = p 0 ( w e x p , w e x p , 4 θ 2 R ( w e x p ) ) , p i k * = p i k ( w e x p , w e x p , θ 2 R ( w ¯ e x p ) ) , p i k = p i k ( w o p t , w o p t , θ 2 R ( w ¯ o p t ) ) , k = 0 , 1 , w 0 = Δ ( 1 τ ) τ = ( w e x p w o p t ) ( 1 τ ) τ .
Using Formulas (13) and (14), we can evaluate the probability that the PB-OOV adversary will correctly recover a complete noise vector in the expected case. Table 7 shows the results of this evaluation, which confirm that the PB-OOV attack does meet the targeted precision.

4.2.3. Secret Keys Recovery Comparison

Finally, let us compare the precision of the OOV attack and PB-OOV attack. We observe the expected case w ¯ = w e x p ( = w o p t for parameter set II). Let l be the number of secret bits, that is, secret key length and m be the noise vector length. The claimed probability of key recovery in [12] is calculated as c k r = ( 1 e r f c ( θ ) ) l m ( 1 1 2 e r f c ( θ ) ) l . This probability is equal 0.37 .
As we have shown in Section 4.2.2, the PB-OOV attack achieves the claimed precision on bit level, therefore it can recover the secret key with probability 0.37. Let us further compare this value with the probability that the OOV adversary recovers the key. In the case of Random-HB#, the number of secret bits is l = ( k x + k y ) m and the adversary has to recover k x + k y = 592 complete noise vectors of length m. The probability of a key recovery can be calculated using the values from Table 5 as p v r ( w e x p ) 592 . For parameter set I, the probability of key recovery is 8.6 × 10 19 , and for parameter set II, it is equal 1.2 × 10 7 . This is remarkably smaller than the claimed 0.37. In the case of HB#, the adversary has to recover l m complete noise vectors and additional l mod m bits. For parameter set I, the probability of key recovery for HB# is 0.024, and for parameter set II, it is 0.159.
More formally, the OOV attack reconstructs the secret keys if it recovers:
-
l m whole m-bit noise vectors—which happens with probability p v r ( w ¯ ) l m ,
-
and then the remaining l mod m bits, by guessing incorrectly one more noise vector weight, and recovering each one of them—which happens with probability p v r e s t ( w ¯ ) = p 0 p i 1 ( l mod m ) τ p i 0 ( l mod m ) ( 1 τ ) for parameter set II and
p v r e s t ( w ¯ ) = p 0 * p i 1 * Δ p i 0 * Δ ( 1 τ ) τ p i 1 ( l mod m Δ τ ) τ p i 0 ( l mod m Δ τ ) ( 1 τ ) for parameter set I, since Δ τ < l mod m .
Therefore, the probability of successful recovery of secret keys using OOV attack will be:
P r [ OOV - Attack   success ] = p v r ( w ¯ ) l m p v r e s t ( w ¯ )
and similarly, probability of successful recovery of secret keys using PB-OOV attack is:
P r [ PB - OOV - Attack   success ] = p v r ( w ¯ ) l m p v r e s t ( w ¯ ) ,
where p v r e s t is the same as p v r e s t , but with symbols p instead of p.
Complexity comparison. The complexity of the OOV attack needed to achieve the required (claimed) key recovery rate is C o m p l O O V = argmin n { P r [ OOV - Attack   success ] ( n ) c k r } . By increasing the number of modifications n until the claimed key recovery rate is reached, we have estimated that the complexity of the OOV attack is higher than the claimed—for parameter set II by 55% in the case of Random-HB# and by 18% for HB# (this supports the results from [25] based on experimental evaluation), and for parameter set I by 150% in the case of Random-HB# and 35% for HB#. On the other hand, since the PB-OOV attack achieves the required precision on a bit recovery level targeted in [12], its precision and complexity is in accordance with the one claimed for the original OOV attack.

5. Experimental Results and Discussion

5.1. Evaluation of the Acceptance Rates

We have conducted a set of experiments to confirm the convergence of experimentally obtained acceptance rates to the corresponding PB values. There were 4 rounds of tests, for n = 2500 , n = 5000 , n = 10,000 and n = 15,000. For each n, we generated 500 noise vectors and flipped the appropriate number of their last bits, so that the expected weight of the noise vectors is optimal, that is, 78. For each test vector e i , we measured the acceptance rate and analyzed how it relates to P O O V ( e i ) and P B ( e i ) . In general, it can be noted that the experimental acceptance rates lie above the corresponding OOV points, but compared to the corresponding PB points, they are evenly distributed above and bellow (see Figure 11). It can also be noticed that as n increases, the experimental points concentrate around the PB points, as expected. This further explains and confirms that the OOV algorithm relaying on the OOV approximation has high error rate when it comes to weight estimate, while the corrected PB-OOV algorithm gives much better results.
Furthermore, we compare experimentally obtained acceptance rates c ( e i ) n with OOV and PB reference points, i.e., P O O V ( e i ) and P B ( e i ) , using a standard error measure—Mean absolute error (MAE), and show how it relates to the correctness of weight estimates. That is, for a set { e i } i = 1 N of test noise vectors, we observe the MAE between the acceptance rates c ( e i ) n , where n is the number of intercepted authentication sessions (i.e., modifications), and P O O V ( e i ) and P B ( e i ) :
A v g _ d i s t n O O V = 1 N i = 1 N | c ( e i ) n P O O V ( e i ) | ,
A v g _ d i s t n P B = 1 N i = 1 N | c ( e i ) n P B ( e i ) | .
From the previous theoretical analysis given in Section 4.1, we have that c ( e i ) n n P B ( e i ) , i = 1 , , N . Therefore:
A v g _ d i s t n O O V n 1 N i = 1 N | P B ( e i ) P O O V ( e i ) | ,
A v g _ d i s t n P B n 0 .
Consequently, the expected MAE value for the OOV points, across all possible weights e i , as n , converges to:
E ( A v g _ d i s t O O V ) = 1 N i = 1 N w = 1 m | P B ( w ) P O O V ( w ) | ( P B ( f , m , τ , w ) P B ( f , m , τ , w 1 ) ) ,
since P r [ e i = w ] = P B ( f , m , τ , w ) P B ( f , m , τ , w 1 ) , after flipping f last bits in e i , while for the PB points they converge to: E ( A v g _ d i s t P B ) = 0 .
This is in accordance with the experimental results shown in Figure 12, for different number of modifications n. Furthermore, Figure 12 and Figure 13 show that there is an inverse correlation between the distance (between the experimental and OOV points, i.e., PB points, respectively) and the accuracy of weight estimation.

5.2. Precision Comparison of the OOV and PB-OOV Weight Estimate: Experimental

Here, the differences in the weight estimate quality between the original OOV Algorithm 1 and the PB-OOV Algorithm 1 proposed in Section 4.1 are experimentally proven. We have analyzed and compared effectiveness of the two algorithms for different Hamming weights. For the standard parameter set I, 99% of all noise vectors have the weight between 250 and 330. The comparison of the algorithms is based on the sample of 5000 noise vectors whose Hamming weight is from that interval. The number of modifications employed for weight estimation corresponds to the HB# scenario. The success rate of the OOV algorithm is 20% and for the PB-OOV it is 98%. Detailed results are given in Figure 14a. For the standard parameter set II, 99% of all noise vectors have the weight between 60 and 95 (this is after flipping ( w o p t m τ ) / ( 1 2 τ ) bits to obtain a vector of the optimal weight from a vector of the expected weight) and the comparison of the two algorithms is based on the sample of 5000 noise vectors with the Hamming weight in this interval. The number of modifications employed for weight estimation corresponds to the HB# scenario. The experimental results again show that the success rate of the OOV algorithm is much worse than PB-OOV (11% in contrast to 99%). Details are given in Figure 14b.

5.3. Evaluation of the PB-OOV Attack Precision

In Section 2.1 from [12], the authors derive the error formula and calculate the number of modifications n that should provide the aimed accuracy of the OOV attack, that is, of the weight estimate and bit recovery. However, the analysis given in Section 4.2 shows that the precision deviates significantly from the one claimed. The analysis provides the theoretical proof that supports the experimental findings presented in [25]. On the other hand, the analysis of the proposed PB-OOV algorithm given in Section 4.2, shows that this algorithm does achieve the desired precision and efficiency. We have conducted a series of experiments in order to experimentally verify the correctness of the PB-OOV attack. The experimental results presented in this section support the conclusions of the theoretical analysis.
The tests are conducted for both HB# and Random-HB# protocols and parameter set II. The number of modifications used (“sample size”) is the one from the [12]. For the HB# protocol we have tested the weight estimate and bit recovery precision for 2000 randomly generated noise vectors of the optimal weight. The weights of two noise vector were incorrectly estimated as 79, since the obtained acceptance rates were 0.473227 and 0.475217. This gives success rate of 0.999 in weight estimation step. When the weight of a vector is incorrectly guessed, it further causes high error rate in the bit recovery process, since the algorithm relies on the initial weight estimate w e s t and chooses between w e s t 1 and w e s t + 1 after flipping the observed bit. However, when the weight estimate is correct, targeted bit precision is 1 1 2 e r f c ( θ ) , and our tests verify that the PB-OOV attack complies with this. Namely, in the set of noise vectors whose weight is correctly estimated, the average bit guessing success rate in our test is 0.999342, compared to the targeted 0.999320. For Random-HB#, we have randomly generated 25,000 noise vectors of the optimal weight. The PB-OOV attack correctly estimated all weights, while the achieved average bit guessing success rate was 0.999996, which is in line with the targeted precision. An interesting finding regarding the OOV attack is that the bit guessing precision may significantly differ for 0-bits and 1-bits, for example, in the case of HB# and parameter set II, precision for 0-bit is 0.764623, while for 1-bit it is remarkably higher and equal 1 5.5 × 10 9 (see Table 4). On the other hand, the proposed PB-OOV algorithm does not have this strong and distinct bias. Table 8 summarizes the results of the tests.

6. Conclusions

This paper provides a detailed examination of the OOV attack reported in [12] against the LPN based authentication protocols known as HB# and Random-HB#. We have found that the problem of discrepancy between the theoretically estimated performances and complexity in [12] and the experimentally evaluated ones in [25] arises from non-Bayesian reasoning with inadequate approximations of the probability distributions on the acceptance rates during the attack, which can not be improved due to the limitations of Central limit theorem use in the attack context. We give a correction of the attack by employing proper, Bayesian inference after establishing the exact underlying probability distributions, and prove that the new version of the attack, unlike the original one, achieves the targeted precision and complexity.
Since the OOV attack is recognized as one of the cornerstones in the analysis of any HB-like authentication protocol, our correction of the OOV attack is not only significant against Random-HB# and HB#, but also for practical security analysis of all new members of the HB-family. An interesting future direction could be a design of improved MIM attacks against HB-like protocols, which could be based on the corrected version of the OOV attack proposed in this paper.

Author Contributions

Conceptualization, S.T., M.K. and M.J.M.; formal analysis, S.T. and M.K.; funding acquisition, S.T., M.K. and M.J.M.; investigation, S.T., M.K.; methodology, S.T., M.K., and M.J.M.; software, M.K., S.T.; validation, S.T. and M.K.; writing—original draft, S.T., M.K. and M.J.M. All authors have read and agreed to the published version of the manuscript.

Funding

This research has been supported by the Ministry of education, science and technological development, Government of Serbia.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

Appendix A

Table A1. Parameters’ values used in the OOV and PB-OOV attack.
Table A1. Parameters’ values used in the OOV and PB-OOV attack.
Parameter Set IParameter Set II
HB#Random-HB#HB#Random-HB#
θ 2.4013.3082.2653.164
R ( w e x p ) 16,780.41 *269.39
R ( w o p t ) 2742.61
R ( w e x p 1 ) 15,789.60270.95
R ( w o p t 1 ) 2743.75
n w e x p = θ 2 R ( w e x p ) 96,736183,62613822697
n w o p t = θ 2 R ( w o p t ) 15,81130,012
n w e x p 1 = θ 2 R ( w e x p 1 ) 91,024172,78313902712
n w o p t 1 = θ 2 R ( w o p t 1 ) 15,81730,024
* Rexp is calculated using Formula (2) from the OOV paper [12].

References

  1. Avoine, G.; Carpent, X.; Hernandez-Castro, J. Pitfalls in ultralightweight authentication protocol designs. IEEE Trans. Mob. Comput. 2015, 15, 2317–2332. [Google Scholar] [CrossRef]
  2. Baashirah, R.; Abuzneid, A. Survey on prominent RFID authentication protocols for passive tags. Sensors 2018, 18, 3584. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  3. D’Arco, P. Ultralightweight cryptography. In International Conference on Security for Information Technology and Communications; Springer: Cham, Switzerland, 2018; pp. 1–16. [Google Scholar]
  4. Hopper, N.J.; Blum, M. Secure Human Identification Protocols. In Advances in Cryptology—ASIACRYPT 2001. ASIACRYPT 2001. Lecture Notes in Computer Science; Boyd, C., Ed.; Springer: Berlin/Heidelberg, Germany, 2001; Volume 2248. [Google Scholar]
  5. Katz, J.; Shin, J.S. Parallel and Concurrent Security of the HB and HB+ Protocols. In Advances in Cryptology—EUROCRYPT 2006. EUROCRYPT 2006. Lecture Notes in Computer Science; Vaudenay, S., Ed.; Springer: Berlin/Heidelberg, Germany, 2006; Volume 4004. [Google Scholar]
  6. Katz, J.; Shin, J.S.; Smith, A. Parallel and concurrent security of the HB and HB+ protocols. J. Cryptol. 2010, 23, 402–421. [Google Scholar] [CrossRef] [Green Version]
  7. Gilbert, H.; Robshaw, M.; Sibert, H. Active attack against HB+: A provably secure lightweight authentication protocol. Electron. Lett. 2005, 41, 1169–1170. [Google Scholar] [CrossRef] [Green Version]
  8. Bringer, J.; Chabanne, H.; Dottax, E. HB++: A Lightweight Authentication Protocol Secure against Some Attacks. In Proceedings of the Second International Workshop on Security, Privacy and Trust in Pervasive and Ubiquitous Computing (SecPerU’06), Lyon, France, 29 June 2006; IEEE Computer Society: Washington, DC, USA, 2006; pp. 28–33. [Google Scholar]
  9. Munilla, J.; Peinado, A. HB-MP: A further step in the HB-family of lightweight authentication protocols. Comput. Netw. 2007, 51, 2262–2267. [Google Scholar] [CrossRef]
  10. Gilbert, H.; Robshaw, M.J.; Seurin, Y. Good variants of HB+ are hard to find. In Financial Cryptography and Data Security; Springer: Berlin/Heidelberg, Germany, 2008; pp. 156–170. [Google Scholar]
  11. Gilbert, H.; Robshaw, M.J.B.; Seurin, Y. HB#: Increasing the Security and Efficiency of HB+. In Advances in Cryptology—EUROCRYPT 2008. Lecture Notes in Computer Science; Smart, N., Ed.; Springer: Berlin/Heidelberg, Germany, 2008; Volume 4965. [Google Scholar]
  12. Ouafi, K.; Overbeck, R.; Vaudenay, S. On the Security of HB# against a Man-in-the-Middle Attack. In Advances in Cryptology—ASIACRYPT 2008. Lecture Notes in Computer Science; Pieprzyk, J., Ed.; Springer: Berlin/Heidelberg, Germany, 2008; Volume 5350. [Google Scholar]
  13. Leng, X.; Mayes, K.; Markantonakis, K. HB-MP+ protocol: An improvement on the HB-MP protocol. In Proceedings of the 2008 IEEE International Conference on RFID, Las Vegas, NV, USA, 16–17 April 2008; IEEE: Piscataway, NJ, USA, 2008; pp. 118–124. [Google Scholar]
  14. Yoon, B.; Sung, M.Y.; Yeon, S.; Oh, H.S.; Kwon, Y.; Kim, C.; Kim, K.H. HB-MP++ protocol: An ultra lightweight authentication protocol for RFID system. In Proceedings of the 2009 IEEE International Conference on RFID, Orlando, FL, USA, 27–28 April 2009; IEEE Computer Society: Washington, DC, USA, 2009; pp. 186–191. [Google Scholar]
  15. Aseeri, A.; Bamasak, O. HB-MP*: Towards a Man-in-the-Middle-Resistant Protocol of HB Family. In 2nd Mosharaka International Conference on Mobile Computing and Wireless Communications (MIC-MCWC 2011); Mosharaka for Research and Studies: Amman, Jordan, 2011; Volume 2, pp. 49–53. [Google Scholar]
  16. Bringer, J.; Chabanne, H. Trusted-HB: A low-cost version of HB+ secure against man-in-the-middle attacks. IEEE Trans. Inf. Theory 2008, 54, 4339–4342. [Google Scholar] [CrossRef]
  17. Madhavan, M.; Thangaraj, A.; Sankarasubramanian, Y.; Viswanathan, K. NLHB: A non-linear HopperBlum protocol. In Proceedings of the 2010 IEEE International Symposium on Information Theory, Austin, TX, USA, 13–18 June 2010; IEEE: Piscataway, NJ, USA, 2010; pp. 2498–2502. [Google Scholar]
  18. Bosley, C.; Haralambiev, K.; Nicolosi, A. HBN: An HB-like protocol secure against man-in-the-middle attacks. IACR Cryptol. ePrint Arch. 2011, 2011, 350. [Google Scholar]
  19. Rizomiliotis, P.; Gritzalis, S. GHB#: A provably secure HB-like lightweight authentication protocol. In International Conference on Applied Cryptography and Network Security; Springer: Berlin/Heidelberg, Germany, 2012; pp. 489–506. [Google Scholar]
  20. Hammouri, G.; Öztürk, E.; Birand, B.; Sunar, B. Unclonable lightweight authentication scheme. In International Conference on Information and Communications Security; Springer: Berlin/Heidelberg, Germany, 2008; pp. 33–48. [Google Scholar]
  21. Hammouri, G.; Sunar, B. PUF-HB: A tamper-resilient HB based authentication protocol. In International Conference on Applied Cryptography and Network Security; Springer: Berlin/Heidelberg, Germany, 2008; pp. 346–365. [Google Scholar]
  22. Deng, G.; Li, H.; Zhang, Y.; Wang, J. Tree-LSHB+: An LPN-based lightweight mutual authentication RFID protocol. Wirel. Pers. Commun. 2013, 72, 159–174. [Google Scholar] [CrossRef]
  23. Qian, X.; Liu, X.; Yang, S.; Zuo, C. Security and privacy analysis of tree-LSHB+ protocol. Wirel. Pers. Commun. 2014, 77, 3125–3314. [Google Scholar] [CrossRef]
  24. Karrothu, A.; Scholar, R.; Norman, J. An analysis of LPN based HB protocols. In Proceedings of the 2016 Eighth International Conference on Advanced Computing (ICoAC), Chennai, India, 19–21 January 2017; IEEE: Piscataway, NJ, USA, 2017; pp. 138–145. [Google Scholar]
  25. Knežević, M.; Tomović, S.; Mihaljević, M.J. Man-In-The-Middle Attack against Certain Authentication Protocols Revisited: Insights into the Approach and Performances Re-Evaluation. Electronics 2020, 9, 1296. [Google Scholar] [CrossRef]
  26. Koralov, L.; Sinai, Y.G. Theory of Probability and Random Processes; Springer: Berlin/Heidelberg, Germany, 2007; pp. 131–134. [Google Scholar]
  27. Shiganov, I.S. Refinement of the upper bound of the constant in the central limit theorem. J. Math. Sci. 1986, 35, 2545–2550, (translated from Stab. Probl. Stoch. Models 1982, 105–115.). [Google Scholar] [CrossRef]
  28. Shevtsova, I.G. An improvement of convergence rate estimates in the Lyapunov theorem. Dokl. Math. 2010, 82, 862–864. [Google Scholar] [CrossRef]
Figure 1. Random-HB# and HB# authentication protocols.
Figure 1. Random-HB# and HB# authentication protocols.
Mathematics 09 00573 g001
Figure 2. The OOV attack against Random-HB# and HB#.
Figure 2. The OOV attack against Random-HB# and HB#.
Mathematics 09 00573 g002
Figure 3. Decision making of the OOV attack Algorithm 1.
Figure 3. Decision making of the OOV attack Algorithm 1.
Mathematics 09 00573 g003
Figure 4. Distribution structure of the cumulative noise vector e e ¯ .
Figure 4. Distribution structure of the cumulative noise vector e e ¯ .
Mathematics 09 00573 g004
Figure 5. The approximation error upper bound is larger than the interval widths used in the attack. Thus, the adversary may not be capable to accurately estimate noise vectors weights.
Figure 5. The approximation error upper bound is larger than the interval widths used in the attack. Thus, the adversary may not be capable to accurately estimate noise vectors weights.
Mathematics 09 00573 g005
Figure 6. Localization of P ( w ) values using Berry-Eseen upper error bound.
Figure 6. Localization of P ( w ) values using Berry-Eseen upper error bound.
Mathematics 09 00573 g006
Figure 7. Theoretically, the approximation error decreases as m increases by CLT (note the transition in color of the error peak). In the OOV attack, m = 1164 or m = 441 , for standard parameter sets I or II, respectively.
Figure 7. Theoretically, the approximation error decreases as m increases by CLT (note the transition in color of the error peak). In the OOV attack, m = 1164 or m = 441 , for standard parameter sets I or II, respectively.
Mathematics 09 00573 g007
Figure 8. The exact error of the P O O V approximation.
Figure 8. The exact error of the P O O V approximation.
Mathematics 09 00573 g008
Figure 9. PB-decision zones used after eavesdropping (left) and for bit recovery (right).
Figure 9. PB-decision zones used after eavesdropping (left) and for bit recovery (right).
Mathematics 09 00573 g009
Figure 10. Different “decision zones” according to the OOV approximation and the exact Poisson-Binomial distribution.
Figure 10. Different “decision zones” according to the OOV approximation and the exact Poisson-Binomial distribution.
Mathematics 09 00573 g010
Figure 11. Comparison of the experimentally obtained acceptance rates and the corresponding P O O V ( e i ) and P B ( e i ) points for n = 2500, 5000, 10,000, 15,000.
Figure 11. Comparison of the experimentally obtained acceptance rates and the corresponding P O O V ( e i ) and P B ( e i ) points for n = 2500, 5000, 10,000, 15,000.
Mathematics 09 00573 g011
Figure 12. MAE between the experimentally obtained acceptance rates and the OOV and PB points, respectively, for n = 2500, 5000, 10,000 and 15,000.
Figure 12. MAE between the experimentally obtained acceptance rates and the OOV and PB points, respectively, for n = 2500, 5000, 10,000 and 15,000.
Mathematics 09 00573 g012
Figure 13. Percentage of correct weights estimates based on acceptance rates using the PB distribution and OOV approximation respectively, for n = 2500, 5000, 10,000 and 15,000.
Figure 13. Percentage of correct weights estimates based on acceptance rates using the PB distribution and OOV approximation respectively, for n = 2500, 5000, 10,000 and 15,000.
Mathematics 09 00573 g013
Figure 14. Precision comparison of the weight estimate using the OOV and PB-OOV algorithms.
Figure 14. Precision comparison of the weight estimate using the OOV and PB-OOV algorithms.
Mathematics 09 00573 g014
Table 1. Standard parameter sets I and II for HB# and Random-HB# proposed in [11]. Number l of secret bits is ( k x + k y ) m for Random-HB#, while it is k x + k y + 2 m 2 for HB#.
Table 1. Standard parameter sets I and II for HB# and Random-HB# proposed in [11]. Number l of secret bits is ( k x + k y ) m for Random-HB#, while it is k x + k y + 2 m 2 for HB#.
Parameter Set k x k y m τ thr
I8051211640.25405
II805124410.125113
Table 2. Comparison of the claimed and real precision of the OOV weight estimate showing that the real precision is remarkably smaller than the claimed one.
Table 2. Comparison of the claimed and real precision of the OOV weight estimate showing that the real precision is remarkably smaller than the claimed one.
Parameter Set IParameter Set II
HB#Random-HB#HB#Random-HB#
claimed precision = 1 e r f c ( θ ) 0.9993150.9999970.9986410.999992
real precision = p 0 ( w e x p , w e x p , 4 n w e x p ) 0.0878030.0310170.0388520.006860
p 0 ( w e x p 1 , w e x p , 4 n w e x p ) 0.9121970.9689830.9611460.993139
Table 3. Precision of the proposed PB-OOV algorithm meets the targeted precision for weight estimate.
Table 3. Precision of the proposed PB-OOV algorithm meets the targeted precision for weight estimate.
Parameter Set IParameter Set II
HB#Random-HB#HB#Random-HB#
targeted precision = 1 e r f c ( θ ) 0.9993150.9999970.9986410.999992
real precision = p 0 ( w e x p , w e x p , 4 n w e x p ) 0.9995060.9999980.9986410.999992
Table 4. Comparison of the claimed and real precision of the OOV bit recovery depending on the initial weight estimate.
Table 4. Comparison of the claimed and real precision of the OOV bit recovery depending on the initial weight estimate.
Parameter Set IParameter Set II
HB#Random-HB#HB#Random-HB#
claimed precision = 1 1 2 e r f c ( θ ) 0.9996580.99999860.9993200.999996
p i 1 ( w e x p , w e x p , n w e x p ) 1 4.4 × 10 9 1 1.1 × 10 15 1 5.5 × 10 9 1 7.1 × 10 16
p i 1 ( w o p t , w o p t , n w o p t ) 1 4.6 × 10 13 1 3.9 × 10 23
p i 0 ( w e x p , w e x p , n w e x p ) 0.8580890.9301140.7646230.843169
p i 0 ( w o p t , w o p t , n w o p t ) 0.3655920.317990
p i 1 ( w e x p 1 , w e x p , n w e x p 1 ) 0.9917120.9995180.9935080.999740
p i 1 ( w o p t 1 , w o p t , n w o p t 1 ) 0.999908 1 1.3 × 10 7
p i 0 ( w e x p 1 , w e x p , n w e x p 1 ) 0.999997 1 2.8 × 10 10 0.999957 1 2.1 × 10 8
p i 0 ( w o p t 1 , w o p t , n w o p t 1 ) 0.9988630.999987
Table 5. Comparison of the claimed and real precision of the OOV noise vector recovery showing that the real precision is smaller than the claimed one.
Table 5. Comparison of the claimed and real precision of the OOV noise vector recovery showing that the real precision is smaller than the claimed one.
Parameter Set IParameter Set II
HB#Random-HB#HB#Random-HB#
claimed precision0.6707200.9983140.7399670.998306
p v r ( w e x p ) 0.2451680.9321410.5730190.973427
Table 6. Precision of the proposed PB-OOV algorithm meets the targeted precision for bit recovery.
Table 6. Precision of the proposed PB-OOV algorithm meets the targeted precision for bit recovery.
Parameter Set IParameter Set II
HB#Random-HB#HB#Random-HB#
targeted precision = 1 1 2 e r f c ( θ ) 0.9996580.99999860.9993200.999996
p i 1 ( w e x p , w e x p , n w e x p ) 0.9996230.99999830.9993450.999996
p i 1 ( w o p t , w o p t , n w o p t ) 0.9996600.9999986
p i 0 ( w e x p , w e x p , n w e x p ) 0.9998740.99999980.9993510.999996
p i 0 ( w o p t , w o p t , n w o p t ) 0.9996590.9999986
Table 7. Precision of the proposed PB-OOV algorithm meets the targeted precision for noise vector recovery.
Table 7. Precision of the proposed PB-OOV algorithm meets the targeted precision for noise vector recovery.
Parameter Set IParameter Set II
HB#Random-HB#HB#Random-HB#
claimed precision0.6707200.9983140.7399670.998306
p v r ( w e x p ) 0.6982790.9985380.7497700.998443
Table 8. PB-OOV experimentally obtained precision.
Table 8. PB-OOV experimentally obtained precision.
HB#Random-HB#
num. tests200025,000
targeted OOV weight est. precision = 1 e r f c ( θ ) 0.9986410.999992
experimentally obtained weight est. precision0.9991
targeted OOV bit precision = 1 1 2 e r f c ( θ ) 0.9993200.999996
experimentally obtained avg. bit precision0.9993420.999996
experimentally obtained 0-bit precision0.9993440.999996
experimentally obtained 1-bit precision0.9993330.999995
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Tomović, S.; Knežević, M.; Mihaljević, M.J. Analysis and Correction of the Attack against the LPN-Problem Based Authentication Protocols. Mathematics 2021, 9, 573. https://doi.org/10.3390/math9050573

AMA Style

Tomović S, Knežević M, Mihaljević MJ. Analysis and Correction of the Attack against the LPN-Problem Based Authentication Protocols. Mathematics. 2021; 9(5):573. https://doi.org/10.3390/math9050573

Chicago/Turabian Style

Tomović, Siniša, Milica Knežević, and Miodrag J. Mihaljević. 2021. "Analysis and Correction of the Attack against the LPN-Problem Based Authentication Protocols" Mathematics 9, no. 5: 573. https://doi.org/10.3390/math9050573

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop