# polarRLCE: A New Code-Based Cryptosystem Using Polar Codes

Authors: Jingang Liu; Yongge Wang; Zongxiang Yi; Zhiqiang Lin
Journal: Security and Communication Networks
 (2019)

---

## Abstract

Security challenges brought about by the upcoming 5G era should be taken seriously. Code-based cryptography leverages difficult problems in coding theory and is one of the main techniques enabling cryptographic primitives in the postquantum scenario. In this work, we propose the first efficient secure scheme based on polar codes (i.e.,polarRLCE) which is inspired by the RLCE scheme, a candidate for the NIST postquantum cryptography standardization in the first round. In addition to avoiding some weaknesses of the RLCE scheme, we show that, with the proper choice of parameters, using polar codes, it is possible to design an encryption scheme to achieve the intended security level while retaining a reasonably small public key size. In addition, we also present a KEM version of the polarRLCE scheme that can attain a negligible decryption failure rate within the corresponding security parameters. It is shown that our proposal enjoys an apparent advantage to decrease the public key size, especially on the high-security level.


---

## Body

## 1. Introduction

Cryptography is essential for the security of online communication. However, many commonly used cryptosystems will be completely broken once large quantum computers exist. It is well known that several computation-intensive tasks may be significantly accelerated through algorithms running on a quantum computer, such as Shor’s [1] and Grover’s [2] algorithm. Current cryptographic protocols, such as RSA and Diffie–Hellman, are proven to be vulnerable under quantum algorithms. This fact pushed cryptographic research to focus on postquantum solutions, i.e., finding new primitives based on more well-suited mathematical problems that may still be difficult to solve for a quantum computer. With this in mind, the US National Institute of Standards and Technology (NIST) is now beginning to prepare for the transition into postquantum cryptography (PQC) and has launched a call for PQC standardization project [3], and this ongoing standardization has moved on to 2nd round thus far. Due to its inherent resistance to attacks by quantum computers, code-based cryptography is one of the main candidates for the PQC standardization call, alongside multivariate and lattice-based schemes.Code-based cryptography is accepted as quantum computing resistant based on a hard coding theory problem, decoding a random linear code in some metric. Historically, the conservative and well-understood choices for code-based cryptography are the McEliece cryptosystem [4] and its dual variant by Niederreiter [5] using binary Goppa codes. However, they suffer from the disadvantage of having large public key size, in spite of the fast encryption and decryption operations. It is therefore of utmost importance to seek ways to reduce the key sizes for code-based cryptosystems while keeping their security level. After the original proposal of the code-based encryption scheme by McEliece [4] which was based on binary Goppa codes, several variants have been proposed using different codes that allow for smaller keys or more efficient encoding and decoding algorithms, e.g., algebraic geometric (AG) codes [6], generalized Reed–Solomon (GRS) codes [7, 8], low-density parity check (LDPC) codes [9, 10], Reed–Muller (RM) codes [11], low-rank parity check (LRPC) codes [12], and among others. Although the original McEliece cryptosystem remains secure, most of these variants have been successfully cryptanalyzed [13–17]. Despite their promising features, the alternative codes need to be handled carefully due to too much structure.It is noteworthy that Wang [18, 19] proposed a random linear code-based quantum resistant public key encryption scheme, referred as RLCE, which is a variant of the McEliece encryption scheme. They analyzed an instantiation of the RLCE scheme using GRS codes and introduced randomness in public key, which is based on the juxtaposition of a GRS code with a random linear code. The idea of the RLCE scheme is to use a distortion matrix that mixes some random columns with the structured ones. The advantage of the RLCE scheme is that its security does not depend on any specific structure of underlying linear codes, instead, it is based on the NP-hardness of decoding random linear codes. In such a manner, previous attacks regarding GRS codes based on the technique of filtration distinguisher no longer work. Nevertheless, part of the original parameters was attacked by [20], and RLCE was not selected for the second round of the NIST PQC standardization call.Polar codes, introduced by Arikan in [21], have received much attention since they are the first class of error-correcting codes that provably achieve the capacity for any symmetric binary discrete memoryless channel (B-DMC) with very efficient encoding and decoding algorithm, whose time complexity scales as Onlogn, where n is the length of the code. Because of the good performance and low complexity, polar codes have been adopted for use in future wireless communication systems (e.g., 5G cellular systems). Looking forward, there is a critical need to ensure that 5G techniques, as developed, envision future adoption of PQC for public key cryptosystems.


### 1.1. Related Work

Within this thread of research, there are two heuristic variants [22, 23] of the McEliece cryptosystem based on polar codes. The first one [23] was broken by Bardet et al. [24] using the structure of the minimum weight codewords. They managed to solve the code equivalence problem for polar codes and thus completely broke the scheme [23] based on polar codes. The second variant was presented by Hooshmand et al. [22] which suggested using the subcode of polar codes. However, we found that the proposal in [22] is useless in practice since 80% ciphertexts could not be decrypted, as discussed in Section 2.4.


### 1.2. Our Contribution

In this work, we combine the idea of the RLCE scheme by inserting random columns, then propose the first efficient secure scheme based on polar codes (i.e.,polarRLCE), which can avoid the attack of [24]. Furthermore, possible attacks are outlined and the key size of several choices of parameters is compared to those of known schemes with the same security level. We show that the existing attacks on the proposal scheme do not seem to be effective. More importantly, our proposal enjoys an apparent advantage to decrease the public key size, especially on the high-security level. It allows us to reconsider polar codes as a good candidate for using in code-based cryptography.The rest of this paper is organized as follows. Some necessary preliminaries such as notation and definitions are given in the Section2. In Section 3, we present the precise description of the construction of the polarRLCE scheme. Section 4 discusses the known cryptanalytic attacks against our proposal and presents a compact key-encapsulation mechanism (KEM) version regarding polarRLCE. Furthermore, we give the choice of suggested parameters and key size for the achievable security level. Finally, some concluding remarks are made in Section 5.


## 1.1. Related Work

Within this thread of research, there are two heuristic variants [22, 23] of the McEliece cryptosystem based on polar codes. The first one [23] was broken by Bardet et al. [24] using the structure of the minimum weight codewords. They managed to solve the code equivalence problem for polar codes and thus completely broke the scheme [23] based on polar codes. The second variant was presented by Hooshmand et al. [22] which suggested using the subcode of polar codes. However, we found that the proposal in [22] is useless in practice since 80% ciphertexts could not be decrypted, as discussed in Section 2.4.


## 1.2. Our Contribution

In this work, we combine the idea of the RLCE scheme by inserting random columns, then propose the first efficient secure scheme based on polar codes (i.e.,polarRLCE), which can avoid the attack of [24]. Furthermore, possible attacks are outlined and the key size of several choices of parameters is compared to those of known schemes with the same security level. We show that the existing attacks on the proposal scheme do not seem to be effective. More importantly, our proposal enjoys an apparent advantage to decrease the public key size, especially on the high-security level. It allows us to reconsider polar codes as a good candidate for using in code-based cryptography.The rest of this paper is organized as follows. Some necessary preliminaries such as notation and definitions are given in the Section2. In Section 3, we present the precise description of the construction of the polarRLCE scheme. Section 4 discusses the known cryptanalytic attacks against our proposal and presents a compact key-encapsulation mechanism (KEM) version regarding polarRLCE. Furthermore, we give the choice of suggested parameters and key size for the achievable security level. Finally, some concluding remarks are made in Section 5.


## 2. Preliminaries

In this section, we introduce some of the basic background information necessary to follow this paper. Throughout the paper, we will denote vectors by lower-case bold letters, e.g.,m. And denote matrices by upper-case bold letters, e.g., A.


### 2.1. Coding Theory

We begin by briefly reviewing the basic concepts in coding theory and show its application to public-key cryptography.Definition 1 (linear codes).
Ann,k linear code C over a finite field Fq is a k-dimensional linear subspace of Fqn.Definition 2 (generator matrix and parity check matrix).
Ak×n matrix G with entries from Fq having row-span C is a generator matrix for the n,k linear code C. And parity check matrix H is a n−k×n matrix whose rows generate the orthogonal complement of C.
One can specify a linear codeC via a generator matrix G∈Fqk×n or a parity check matrix H∈Fqn−k×n via(1)C≔xG∈Fqnx∈FqkorC≔c∈FqnHcT=0.
IfG∈Fqk×n or H∈Fqn−k×n, i.e., each matrix entry is chosen uniformly at random from Fq, then we call C a random linear code.
The codeC can be represented by different generator matrices. An important one is the systematic form, i.e., when each input symbol is directly represented in its first k coordinate positions. For a systematic linear code, the generator matrix G can always be written as G=IkP, where Ik is the identity matrix of size k. And if G has such a systematic form, then H=−PTIn−k.Definition 3 (punctured and shortened codes).
Given ann,k linear code C, let I be a subset of 1,…,n and the ith entry of a codeword c∈C is written as ci. Then, we define the punctured code PIC and the shortened code SIC as(2)PIC=cii∉Ic∈C,SIC=cii∉I∃c∈C,s.t.∀i∈I,ci=0.
Given a subsetI of the set of coordinates of a vector x, we denote by PIx the vector x punctured at I, that is to say, whose ith entry has been deleted for any i∈I.Lemma 1.
LetC be a code of dimension k and generator matrix G. Then, the matrix GP is a generator matrix for PIC, which can be obtained by deleting the columns from G index in I.We now only consider binary codes, i.e.,q=2. The hamming weight wHx of a binary vector in x∈F2n is the number of nonzero entries in the vector. And the minimum hamming distance of the code C is defined as d=minwHx−y, where x≠y.


### 2.2. McEliece’s Public-Key Cryptosystem

In 1978, McEliece presented in his seminal paper [4] the first code-based public key encryption system, which relied on Goppa codes to form the secret key. And a permutation matrix and an invertible matrix are used for scrambling and concealing secret key. It employs an n,k linear code C over F2, with an error-correcting capability of t errors, for which an efficient decoding algorithm is known. The general key generation, encryption, and decryption steps for the original proposal in [4] work as follows.Private key: it consists of three matricesG, S, and P, where G is an k×n generator matrix of this code, S is an arbitrary k×k binary nonsingular matrix (called the scrambling matrix), and P is an n×n random permutation matrix.Public key: it is composed of thek×n matrix G′ defined by G′=SGP and the error-correcting capability with t.Encryption: to encrypt the messagem∈F2k and choose a random error vector e∈F2n with weight wHe≤t, then the corresponding ciphertext is computed as(3)y=mG′+e.Decryption: the decryption procedure consists in computing(4)yP−1=mSG+eP−1,and using a fast decoding algorithm for Goppa codeC to recover mS. The message is then recovered by m=mSS−1.Notice that multiplying the error vector by a permutation does not change the weight of the vector. One can easily verify the correctness of the scheme by checking(5)DecryptEncryptm,pk,sk=m.A dual version of the McEliece cryptosystem that uses the parity-check matrix instead of the generating matrix has been proposed by Niederreiter in [5]. Following the idea of [25], the Niederreiter system and the McEliece system are equivalent in terms of security.Knowing the description of the selected Goppa codeC allows efficient decoding, since there are many efficient decoding algorithms for this problem running in polynomial time. However, knowing only the public key G′, the attacker is facing a decoding problem for a code that looks like a random code, which is NP-hardness. The attacker can either try to decode an intercepted ciphertext (message recovery attack) or try to recover the secret matrix G from the public matrix G′ (key-recovery attack).The security level of the McEliece system has remained remarkably stable, despite dozens of attack papers over 40 years, regardless of the original McEliece parameters being designed for only 64-bit security level. For instance, as recommended by Bernstein et al. [26], the McEliece scheme with binary Goppa codes using code length n=2960 and code dimension k=2288 and adding t=57 errors can achieve 128-bit security level, Thus, the corresponding public key size is 187.69 KBytes.


### 2.3. Polar Codes Construction

We first recall the basic facts about polar codes. As shown in the seminal work by Arikan [21], for any B-DMC, there exists a polar code of block length n=2m which is characterized by the information bit set A with exponentially small word-error rate under successive cancellation (SC) decoder. A polar code may be specified completely by n,k,ℱ, where n is the length of a codeword in bits, k is the number of information bits encoded per codeword, and ℱ is a set of n−k integer indices called frozen bit locations from 0,1,…,n−1. The k more reliable subchannels (based on the polarization phenomenon) with indices in set A carry information bits and the rest subchannels included in the complementary set Ac (i.e., the set ℱ) can be set to fixed bit values, such as all zeros. Generally, the challenge is to select the information bits set A or, more precisely, the methods that are proposed for finding the indices of good polarized channels.For a binary polar code of lengthn=2m, the polar encoding of an input vector is carried out by the polarization transformation matrix Gn=F⊗m, which is the mth Kronecker power of the 2×2 kernel matrix:(6)F=1011.For a given noise channel, the generator matrixG of an n,k polar code is defined as the submatrix of Gn consisting of k rows with indices corresponding to information set A=i1,i2,…,ik. Roughly speaking these rows are chosen in such a way that it gives good performance for the SC decoder. These codes come equipped with an SC decoder whose decoding complexity scales as Onlogn (see [21] for more details).The idea of exploiting polar codes in cryptography came in a natural way since polar codes benefit of various interesting properties: can achieve Shannon capacity for the class of binary discrete memoryless channels, attain better performance (lower decoding errors) because of the channel polarization along with the increased block length, posses efficient encoding and decoding procedures, etc. Even though polar codes are closely related to RM codes, the techniques used for the cryptanalysis of RM codes do not work on polar codes.


### 2.4. The Proposal by Hooshmand et al. [22]

The error-correcting capacity of polar codes [21] does not only depend on the code length but also on other factors such as the code rate and the designed channel. However, the error-correcting capacity was merely set to be a fixed value of t=2n−1 in the proposal by Hooshmand et al. [22], they did not consider the error probability of decoding. For instance, they claimed that one can use 2048,1750-polar code with t=89, which followed Theorem 8 in [27]. Actually, Theorem 8 from [27] is only suitable for the concatenated polar codes with respect to the length of burst-errors as stated in [27]. Nevertheless, the proposal in [22] used random errors through the encryption process. With these parameters in [22], we performed numerical simulation using MATLAB R2018a where 105 decoding trails are exploited under SC decoder [21], and the experiment result indicates that the decoding error probability is nearly 0.8, i.e., 80% ciphertexts could not be decrypted and cannot be employed in a practical environment. With respect to our proposal, the error probability is approximately 2−14 (see Section 3). Furthermore, we transform the basic polarRLCE into a key-encapsulation mechanism (KEM) version, which can achieve the negligible decryption failure rate (DFR) within the corresponding security parameters.


## 2.1. Coding Theory

We begin by briefly reviewing the basic concepts in coding theory and show its application to public-key cryptography.Definition 1 (linear codes).
Ann,k linear code C over a finite field Fq is a k-dimensional linear subspace of Fqn.Definition 2 (generator matrix and parity check matrix).
Ak×n matrix G with entries from Fq having row-span C is a generator matrix for the n,k linear code C. And parity check matrix H is a n−k×n matrix whose rows generate the orthogonal complement of C.
One can specify a linear codeC via a generator matrix G∈Fqk×n or a parity check matrix H∈Fqn−k×n via(1)C≔xG∈Fqnx∈FqkorC≔c∈FqnHcT=0.
IfG∈Fqk×n or H∈Fqn−k×n, i.e., each matrix entry is chosen uniformly at random from Fq, then we call C a random linear code.
The codeC can be represented by different generator matrices. An important one is the systematic form, i.e., when each input symbol is directly represented in its first k coordinate positions. For a systematic linear code, the generator matrix G can always be written as G=IkP, where Ik is the identity matrix of size k. And if G has such a systematic form, then H=−PTIn−k.Definition 3 (punctured and shortened codes).
Given ann,k linear code C, let I be a subset of 1,…,n and the ith entry of a codeword c∈C is written as ci. Then, we define the punctured code PIC and the shortened code SIC as(2)PIC=cii∉Ic∈C,SIC=cii∉I∃c∈C,s.t.∀i∈I,ci=0.
Given a subsetI of the set of coordinates of a vector x, we denote by PIx the vector x punctured at I, that is to say, whose ith entry has been deleted for any i∈I.Lemma 1.
LetC be a code of dimension k and generator matrix G. Then, the matrix GP is a generator matrix for PIC, which can be obtained by deleting the columns from G index in I.We now only consider binary codes, i.e.,q=2. The hamming weight wHx of a binary vector in x∈F2n is the number of nonzero entries in the vector. And the minimum hamming distance of the code C is defined as d=minwHx−y, where x≠y.


## 2.2. McEliece’s Public-Key Cryptosystem

In 1978, McEliece presented in his seminal paper [4] the first code-based public key encryption system, which relied on Goppa codes to form the secret key. And a permutation matrix and an invertible matrix are used for scrambling and concealing secret key. It employs an n,k linear code C over F2, with an error-correcting capability of t errors, for which an efficient decoding algorithm is known. The general key generation, encryption, and decryption steps for the original proposal in [4] work as follows.Private key: it consists of three matricesG, S, and P, where G is an k×n generator matrix of this code, S is an arbitrary k×k binary nonsingular matrix (called the scrambling matrix), and P is an n×n random permutation matrix.Public key: it is composed of thek×n matrix G′ defined by G′=SGP and the error-correcting capability with t.Encryption: to encrypt the messagem∈F2k and choose a random error vector e∈F2n with weight wHe≤t, then the corresponding ciphertext is computed as(3)y=mG′+e.Decryption: the decryption procedure consists in computing(4)yP−1=mSG+eP−1,and using a fast decoding algorithm for Goppa codeC to recover mS. The message is then recovered by m=mSS−1.Notice that multiplying the error vector by a permutation does not change the weight of the vector. One can easily verify the correctness of the scheme by checking(5)DecryptEncryptm,pk,sk=m.A dual version of the McEliece cryptosystem that uses the parity-check matrix instead of the generating matrix has been proposed by Niederreiter in [5]. Following the idea of [25], the Niederreiter system and the McEliece system are equivalent in terms of security.Knowing the description of the selected Goppa codeC allows efficient decoding, since there are many efficient decoding algorithms for this problem running in polynomial time. However, knowing only the public key G′, the attacker is facing a decoding problem for a code that looks like a random code, which is NP-hardness. The attacker can either try to decode an intercepted ciphertext (message recovery attack) or try to recover the secret matrix G from the public matrix G′ (key-recovery attack).The security level of the McEliece system has remained remarkably stable, despite dozens of attack papers over 40 years, regardless of the original McEliece parameters being designed for only 64-bit security level. For instance, as recommended by Bernstein et al. [26], the McEliece scheme with binary Goppa codes using code length n=2960 and code dimension k=2288 and adding t=57 errors can achieve 128-bit security level, Thus, the corresponding public key size is 187.69 KBytes.


## 2.3. Polar Codes Construction

We first recall the basic facts about polar codes. As shown in the seminal work by Arikan [21], for any B-DMC, there exists a polar code of block length n=2m which is characterized by the information bit set A with exponentially small word-error rate under successive cancellation (SC) decoder. A polar code may be specified completely by n,k,ℱ, where n is the length of a codeword in bits, k is the number of information bits encoded per codeword, and ℱ is a set of n−k integer indices called frozen bit locations from 0,1,…,n−1. The k more reliable subchannels (based on the polarization phenomenon) with indices in set A carry information bits and the rest subchannels included in the complementary set Ac (i.e., the set ℱ) can be set to fixed bit values, such as all zeros. Generally, the challenge is to select the information bits set A or, more precisely, the methods that are proposed for finding the indices of good polarized channels.For a binary polar code of lengthn=2m, the polar encoding of an input vector is carried out by the polarization transformation matrix Gn=F⊗m, which is the mth Kronecker power of the 2×2 kernel matrix:(6)F=1011.For a given noise channel, the generator matrixG of an n,k polar code is defined as the submatrix of Gn consisting of k rows with indices corresponding to information set A=i1,i2,…,ik. Roughly speaking these rows are chosen in such a way that it gives good performance for the SC decoder. These codes come equipped with an SC decoder whose decoding complexity scales as Onlogn (see [21] for more details).The idea of exploiting polar codes in cryptography came in a natural way since polar codes benefit of various interesting properties: can achieve Shannon capacity for the class of binary discrete memoryless channels, attain better performance (lower decoding errors) because of the channel polarization along with the increased block length, posses efficient encoding and decoding procedures, etc. Even though polar codes are closely related to RM codes, the techniques used for the cryptanalysis of RM codes do not work on polar codes.


## 2.4. The Proposal by Hooshmand et al. [22]

The error-correcting capacity of polar codes [21] does not only depend on the code length but also on other factors such as the code rate and the designed channel. However, the error-correcting capacity was merely set to be a fixed value of t=2n−1 in the proposal by Hooshmand et al. [22], they did not consider the error probability of decoding. For instance, they claimed that one can use 2048,1750-polar code with t=89, which followed Theorem 8 in [27]. Actually, Theorem 8 from [27] is only suitable for the concatenated polar codes with respect to the length of burst-errors as stated in [27]. Nevertheless, the proposal in [22] used random errors through the encryption process. With these parameters in [22], we performed numerical simulation using MATLAB R2018a where 105 decoding trails are exploited under SC decoder [21], and the experiment result indicates that the decoding error probability is nearly 0.8, i.e., 80% ciphertexts could not be decrypted and cannot be employed in a practical environment. With respect to our proposal, the error probability is approximately 2−14 (see Section 3). Furthermore, we transform the basic polarRLCE into a key-encapsulation mechanism (KEM) version, which can achieve the negligible decryption failure rate (DFR) within the corresponding security parameters.


## 3. Our Proposed Scheme of polarRLCE

In this section, we describe our new variant of the McEliece cryptosystem by exploiting the method of RLCE [18, 19] scheme. More precisely, the procedures of our polarRLCE are specified as follows.Key generation: according to the construction of the polar code in Section2.3,(i)
Choose ann,k polar code with the generator matrix G of length n and dimension k.(ii)
Generatew random column vectors r1,r2,…,rw, and let(7)G1=g1,…,gn−w,gn−w+1,r1,…,gn,rw,be thek×n+w matrix obtained by inserting w random k×1 column vectors ri into matrix G.(iii)
To mix the columns, choosew random nonsingular binary 2×2 matrices A1,A2,…,Aw. Denote A with the n+w×n+w block-diagonal matrix:(8)A=In−w0A1⋱0Aw.(iv)
LetS be a randomly chosen k×k nonsingular matrix and P be the n+w×n+w permutation matrix.(v)
The public keyk×n+w matrix is defined as(9)Gpub=SG1AP.Then, the public key and private key are given, respectively, by(10)GpubandG,S,P,A.Encryption: letm∈F2k be the message to be encrypted. Then, we randomly generate error vector e∈F2n+w such that the hamming weight wHe≤t. Compute the corresponding ciphertext:(11)c=mGpub+e.Decryption: to decrypt the received ciphertextc,(i)
CalculatecP−1A−1=c1′,c2′,…,cn+w′.(ii)
Deletew entries at the ri position of row vector c1′,c2′,…,cn+w′. We denote the obtained n-length vector by(12)c′=c1′,c2′,…,cn−w+1′,cn−w+3′,cn−w+5′,…,cn+w−1′.(iii)
It is easy to check thatc′=mSG+e′ for some error vector e′∈F2n, where wHe′≤t. Then, using the efficient decoding algorithm, one can recover the corresponding message m.For the purpose of constructing polar code used in our proposed variant scheme, we consider here the binary symmetric channel (BSC) with crossover probabilityε=0.05. For instance, to achieve 128-bit security, for reliable decoding and keeping reasonably small key size with enough security level, we will set the choice of parameters such that n=211, k=500, and w=50. Following the method of Dragoi [28], validated through exhaustive simulation, we can choose the error vector weight of t=285 with the reasonable decoding error probability is approximately 2−14.Remark 1.
Please note that our scheme allows occasional decryption failures for valid ciphertexts (similar to some NIST PQC submissions), which is inherited from the decoding algorithm. However, for the good performance of polar codes, one can easily resolve this issue through repeated encryption as presented by Eaton et al. [29] which can reduce the decryption failure rate to a level negligible in the security parameter, without altering the whole parameters.


## 4. Security Analysis

In this section we will discuss several possible attacks against our proposed polarRLCE scheme in 3. There are two main attacks to thwart, i.e., key structural attack and decoding attack.Furthermore, if the codeC, whose generator matrix is used as a part of the public key, could be distinguished, then an adversary could exploit the structure of C, and this would also possibly allow the adversary to develop faster attacking algorithms. Indeed, most of these variations of the McEliece system are vulnerable to structural attacks because of the algebraic structure of underlying codes.


### 4.1. Brute Force Attack

A brute force attack is a trial-and-error method used to obtain the correct keys. For our proposed scheme, recall that the private keyG,S,P,A is obtained randomly. Moreover, the number of candidate invertible scrambling matrix Sk×k over F2 is(13)N=∏i=1k2k−2i−1=2k2∏i=1k1−2i>2k2−2.By putting in the suggested parameters (with 128-bit security)n=2048, k=500, and w=50, it turns out that it is as well infeasible to retrieve the other three elements building the private key just by guessing, since there exist n+w!=2048!≫2128 different matrix P and nearly N=25002≫2128 choices for S. Moreover, the candidate of block-diagonal matrix A is 6w=2129.25. Hence, the complexity of the exhaustive search attack against our scheme has an exponential time, which indicates this attack is impractical.


### 4.2. Square Attack

In this section, we study the square attack on our polarRLCE. There has been an increased interest in the square (a.k.a. Schur product) of linear codes in the last years (cf. [30]). Another and more recent application of the Schur product concerns cryptanalysis of code-based public key cryptosystems. In this context, the Schur product is a very powerful operation which can help to distinguish secret codes from random ones.In fact, the method of inserting random columns or rows in the secret matrix has indeed proposed [7, 8, 31] to avoid structural attacks on similar versions of the McEliece cryptosystem. Although this proposal has effectively avoided the original attack, recent studies [14, 32, 33] have shown that in the case of GRS codes or RM codes, the random columns can be found through the consideration of the dimension of the Schur product code.Definition 4 (Schur product).
Letx,y∈F2n, then the Schur product of two vectors is denoted by(14)x∗y=x1y1,x2y2,…,xnyn.Definition 5 (square code).
LetA and ℬ be linear codes with length n. The Schur product of the two codes is the vector space spanned by all products a∗b with a∈A and b∈ℬ:(15)A∗ℬ=a∗ba∈Aandb∈ℬ.
IfA=ℬ, then we call A∗A the square code of A and denote it by A2. The impact of the square code on the code-based cryptosystem becomes clear when we study the dimension of these constructions.Definition 6 (Schur matrix).
LetG be a k×n matrix, with rows gi1≤i≤k. The Schur matrix of G, denoted by SG consists of the rows gi∗gj for 1≤i≤j≤k.
We observe that ifG is a generator matrix of a code C, then its Schur matrix SG (or the submatrix which contains the linear independent rows of SG) is a generator matrix of the square code of C. For the k×n matrix G, the matrix SG at most has the size k+12×n (refer to [30]).
It is well known that the square of a linear codeCn,k has the dimension(16)dimC2≤minn,12kk+1,and a random linear code attains this upper bound with high probability.
One of the key features in most of the successful cryptanalysis efforts has been that the proposed codes have small Schur-product dimension which leads to key recovery or distinguishing attacks. In particular, this lends credence to the idea that codes with small Schur-product dimension appear to be unsuitable for use in the McEliece framework. For instance, if the code is generalized Reed–Solomon (GRS) code, then it satisfies(17)dimC2=minn,2k−1,and fulfills this lower bound with equality, i.e., for k<n/2, their square dimension is much smaller than one expects from a random code. Actually, this fact is, e.g., utilized by [14, 33] to build an effective distinguisher, yielding a structural attack on the GRS-based McEliece cryptosystem.
Looking at the definition of the square code, we observe that it is generated by all possible Schur-products of every pair of (nonnecessarily distinct) codewords in the given linear code. Therefore, it is natural to expect that the dimension of the square code is “as large as possible.” In other words, for a randomly chosen linear codeℛ, we expect that inequality (16) is actually an equality with very high probability.
Let us consider the recent work [34] which reported that it might possibly exist as a heuristic distinguisher, if given two specific weakly decreasing sets. However, in the case of our polarRLCE scheme, such sets could not be found easily because of the extended public codes by inserting random columns.
To illustrate the square attack, we performed simulation by generating 10,000 random sets of the public key matrix. Our experimental result shows that, as in the case of the proposed polarRLCE scheme, the square code of the public code can always reach the maximal dimension bound. Considering the choice of parameters (with 128-bit security) such thatn=2048, k=500, and w=50. So, we can obtain the k×n+w public key matrix Gpub. Denote the extended public code as Cpub. Hence, from inequality (16), we have(18)dimCpub2=dimSGpub≤minn+w,12kk+1.
For the proposed parameters, we observed experimentally that the dimension of the public matrix by the square product always reach maximum, that is to say,(19)dimSGpub=n+w=2098.
Furthermore, after perform random puncturing operations,PIGpub, alternatively, we can obtain(20)dimSPIGpub=n+w−I.
On the basis of the observations made as stated above, we claim that the technique of square attack regarding our polarRLCE could not be used to distinguish from random codes.


### 4.3. Key-Recovery Attack

The key-recovery attack is one of the important ways of structural attack, consists in recovering the private key from the public key. In this case, the methods are specific to the code family. In order to compute the private key of a given public key, it is often reduced to solve the code equivalence problem.Definition 7.
LetG and G∗ be the generating matrix for two n,k binary linear codes. Given G and G∗, there exist a k×k binary invertible matrix S and n×n permutation matrix P such that G∗=SGP?.
This problem was first studied by Petrank and Roth [35] over the binary field. And the most common algorithm used to solve this problem is the support splitting algorithm (SSA) [36]. SSA is very efficient in the random case, but it cannot be used in the case of codes with large hulls or codes with large permutation group such as Goppa codes and polar codes.
However, a very effective structural attack on the variant [23] using polar codes was introduced by Bardet et al. in [24]. Firstly, they managed to determine exactly the structure of the minimum weight codeword of the original polar codes. Then, they solved the code equivalence problem for polar codes with respect to decreasing monomial codes. Notice that this attack is very specific to the simple usage of polar codes in [23].
Regarding our proposal, there is a really effective way of protecting the scheme since the structure of the private code is someway shattered by inserting random elements. Thus, even though one can find enough low-weight codewords, while they are not subject to the original polar code, because that these codewords possess an extended lengthn+w which is generated by the public key matrix Gpub. The natural way is to perform puncturing operations, but an exponential number of codewords need to check since there are (21)n+ww=209850=2336.68.
On the other hand, the adversary cannot identify the inserted positions by distinguishing attack or square attack as stated on Section4.2. So, the code equivalence problem becomes even more complicated to solve in this case. Therefore, the attack by [24, 34] does not apply directly to our proposed polarRLCE scheme.
Finally, we notice that very recently, Couvreur et al. [20] presented a key-recovery attack on half the parameter sets proposed in the RLCE scheme [19]. They showed that it is possible to distinguish some keys from random codes by computing the square of some shortened public codes. The set of positions 1,…,n+w splitted into four parts based on the fact that the entry of any GRS codeword satisfies a specific expression formalization, i.e., dimGRSkx,y2=2k−1, and then recognizes the twin positions. While polar codes are used for the aforementioned situation because of the different structure between polar codes and GRS codes.
According to the aforementioned analysis and the fact that we found no other distinguishing methods for our proposal, we claim that it is indeed able to avoid the key-recovery attack.


### 4.4. Message-Decoding Attack

Message-decoding attack is an important issue in code-based cryptography. The problem of recovering the private message from a ciphertext is directly related to the hardness of generic decoding for the linear code. One possibility attack to recover the message is information set decoding (ISD) algorithm, which means to decode a random linear code without exploiting any structural property of the code. The ISD algorithm searches for an information set such that the error positions are all out of the information set. The work factor of ISD clearly increases with the number of errors added in the encryption process. Thus, when choosing parameters, we will focus mainly on defeating attacks of the ISD family.This technique was first introduced by Prange [37]. Hereafter, numerous different algorithmic techniques have been explored to improve complexity of ISD algorithm. Among several variants [26, 38–40] and generalizations, it is noteworthy that most modern ISD algorithms are based on Stern’s [38] algorithm, which incorporates collision search methods to speed up decoding.Thus, we will move on to analyze the complexity of Stern’s algorithm. Similarly, they try to find at-weight codeword in an n,k linear code C generated by F2k×n. More precisely, apart from the generator matrix G, the algorithm takes as input additional integer parameters p and l such that 0≤p≤t and 0≤l≤n−k. Each iteration consists of the steps described in Algorithm 1.Algorithm 1: Stern’s ISD algorithm.
Input: Generator matrix G∈F2k×n, with parameters t, p, and l.
Output: Codeword c∈C, s.t. wHc=t.
1 Select a random information setℐ from 1,2,…,n and divide it into two equal size subsets X and Y. Moreover, select a size-l subset Z of 1,2,…,n\ℐ.
2 PermutateG randomly, and let Gsys denote the systematic form: Gsys=IQJ
whereI is the k×k identity matrix, Q is a k×l matrix and J is a k×n−k−l matrix.
3 Letu run through all p-weight vectors of length k/2. Then, put all vectors x=u0Gsys in a sorted list ℒ1, sorted according to index ϕx, with ϕx being the value of a vector x in positions k+1 to k+l, i.e., ϕx=xk+1,xk+2,…,xk+l.
4 Then, construct another listℒ2 sorted according to ϕx, containing all vectors x=0uGsys, where u run through all p-weight vectors of length k/2.
5 Add all pairs of vectorsx∈ℒ1 and x′∈ℒ2 for which ϕx=ϕx′ and put in a new list ℒ.
6if there exists x∈ℒ, s.t. wHx=t−2p then
7 return the codewordc∈C corresponding to x.
8else
9 go back to Step 1;
10end(22)
P
stern
=
k
/
2
p
2
n
−
k
−
l
t
−
2
p
n
t
.Then, the probability of success in one single iteration isAnd the cost of one iteration of Stern’s algorithm is as follows:(23)n−k2n+k+k2−p+1+2lk2p+4pt−2p+1k2p22−l.We refer to the improved version of ISD attack algorithm in [26, 39], which is a generalization of Stern’s algorithm [38]. And they pointed out that for small fields (e.g., in our case, F2), choosing the new algorithm parameters c and r 1<r≤c should be taken into account, which can yield good speedups on the Gaussian elimination cost of each iteration. Furthermore, they offer an improved tool, which allows to compute a rough approximation of the security level of a code-based cryptosystem against information set decoding attacks.For a practical evaluation of the ISD running times and corresponding security level, similarly, most of the NIST PQCrypto code-based submissions exploited this complexity computation tool to determine the security level of their proposals, and we also use this tool to indicate the security level of our implementation. Note that the ciphertext length should ben+w instead of n in our case. According to this computation tool, we test different input parameters to classify expected bit security level κ≔128,192,256, respectively (see Section 4.6 for more details).


### 4.5. The KEM of polarRLCE Scheme

Key-encapsulation mechanisms (KEMs) are a common stepping stone aiming for the strong security goal, i.e., indistinguishability against adaptive chosen-ciphertext attacks (IND-CCA2). We also suggest a key-encapsulation mechanism (KEM) version of our polarRLCE scheme, consisting of three algorithms:KEM=KeyGen,Encaps,Decaps, by applying a transformation of Eaton et al.’s [29] observation. A favorable feature of this proposal is that the process of polarRLCE is convenient, and it enables our KEM-DEM version to achieve the negligible decryption failure rate within the corresponding security parameters. Let G, ℋ, and K be hash functions, typically SHA-3 as advised by NIST. Here, we show the KEM-DEM version below.KeyGen (pk,sk): exactly the same as polarRLCE key generation (Section 3), and generate a public/secret key pair pk,sk.Encaps (c,K): encapsulate a shared key K in ciphertext c as follows:(i)
Pick a seeds∈0,1k and set parallel degree P(ii)
Fori∈1,2,…,P, let ei=Gsi(iii)
Computexi=s+ℋeii, and the corresponding ciphertext ci = Enc.(pk, xi, ei)(iv)
Output the shared keyK=Ks and c=c1,…,cPDecaps (K): decapsulate the shared key K from ciphertext c with sk.(i)
Decrypt ciphertextc to get xi∗,ei∗, where i∈1,2,…,P.(ii)
Letj=i when the last step successfully decrypt for the current status, then compute s=xj+ℋejj.(iii)
Computeci∗ = Enc·(pk, xi∗, ei∗), obtain c∗ and verify that c∗=c. If so, return the shared key K=Ks.The same construction was proven to have IND-CCA2 guarantees in the work by [29]. More details regarding the security reduction can be found in [29].To provide IND-CCA2 for a given security level2κ, it is required for the decapsulation to have a correctness error δ≤2−κ. Recall that the DFR of our polarRLCE scheme is no more than 2−14. The resulting ciphertext includes several independent encapsulations with the same key so that a decapsulation failure occurs only if a decryption failure occurs in every instance of the underlying polarRLCE scheme. Willing to target a DFR of 2−κ, we can select the parallel degree P=10,14,19, respectively. Thus, our KEM version achieves the desired negligible target DFR value 2−140, 2−196, and 2−266.


### 4.6. Suggested Parameters for polarRLCE

In this section, we give the suggested parameters in 1 for our polarRLCE scheme, with the three most relevant standard security levels, 128-bit, 192-bit, and 256-bit. Besides, a comparison of the public key size for our suggested parameters with RLCE [19] (the secure second group parameters) and the original McEliece [26] scheme (under binary Goppa codes) is given in 2, together with the state-of-the-art NTS-KEM [41] and Classic-McEliece [42], which are moving on to the 2nd round of the NIST PQC standardization process.For convenience, we introduce the following notations of each column list in the tables:(i)
κ: security level(ii)
w: the number of inserted columns(iii)
n,k,t: code length n, code dimension k, and t is the error-correcting ability(iv)
PK: public-key size in kB(v)
SK: private-key size in KBytes(vi)
CT: ciphertext size in Bytes(vii)
WISD: the work factor of ISD attack algorithmTable 1
Set of parameters for polarRLCE scheme.
κ
n
,
k
,
t
w
PK
SK
CT
W
ISD
128
2
11
,
500,285
50
97.53
30.54
262.25
130.62
192
2
12
,
585,760
75
256.08
41.81
531.38
193.84
256
2
12
,
960,610
100
379.22
112.55
524.50
257.35Table 2
Public-key size comparison (in KBytes).
κ
Our
McEliece
RLCE
NTS-KEM
Classic-McEliece
128
97.53
187.69
187.53
312
255
192
256.08
489.4
446.36
907.97
511.88
256
379.22
936.02
1212.86
1386.43
1326We remark that the parameters given in Table1 may be vulnerable to the attack under the quantum random oracle model (QROM [43]). Here, we present the parameters solely to illustrate the rationality of our construction which, to our best knowledge, are secure against current known attacks.From Table2, we can see that our scheme can reduce the public key size of the original McEliece scheme by at least 52%. It has the apparent advantage to decrease the key size, especially on the high-security level. However, compared to the candidates based on hamming (rank) quasi-cyclic (QC) codes, the public key size of our proposal is inferior to them. Nevertheless, a new type of statistical analysis, called reaction attacks [44, 45], are threatening these schemes with a specific QC structure of the underlying codes [46, 47]. As a final remark, it would be required to consider the impact of reaction attacks even without the QC structure in our proposal.


## 4.1. Brute Force Attack

A brute force attack is a trial-and-error method used to obtain the correct keys. For our proposed scheme, recall that the private keyG,S,P,A is obtained randomly. Moreover, the number of candidate invertible scrambling matrix Sk×k over F2 is(13)N=∏i=1k2k−2i−1=2k2∏i=1k1−2i>2k2−2.By putting in the suggested parameters (with 128-bit security)n=2048, k=500, and w=50, it turns out that it is as well infeasible to retrieve the other three elements building the private key just by guessing, since there exist n+w!=2048!≫2128 different matrix P and nearly N=25002≫2128 choices for S. Moreover, the candidate of block-diagonal matrix A is 6w=2129.25. Hence, the complexity of the exhaustive search attack against our scheme has an exponential time, which indicates this attack is impractical.


## 4.2. Square Attack

In this section, we study the square attack on our polarRLCE. There has been an increased interest in the square (a.k.a. Schur product) of linear codes in the last years (cf. [30]). Another and more recent application of the Schur product concerns cryptanalysis of code-based public key cryptosystems. In this context, the Schur product is a very powerful operation which can help to distinguish secret codes from random ones.In fact, the method of inserting random columns or rows in the secret matrix has indeed proposed [7, 8, 31] to avoid structural attacks on similar versions of the McEliece cryptosystem. Although this proposal has effectively avoided the original attack, recent studies [14, 32, 33] have shown that in the case of GRS codes or RM codes, the random columns can be found through the consideration of the dimension of the Schur product code.Definition 4 (Schur product).
Letx,y∈F2n, then the Schur product of two vectors is denoted by(14)x∗y=x1y1,x2y2,…,xnyn.Definition 5 (square code).
LetA and ℬ be linear codes with length n. The Schur product of the two codes is the vector space spanned by all products a∗b with a∈A and b∈ℬ:(15)A∗ℬ=a∗ba∈Aandb∈ℬ.
IfA=ℬ, then we call A∗A the square code of A and denote it by A2. The impact of the square code on the code-based cryptosystem becomes clear when we study the dimension of these constructions.Definition 6 (Schur matrix).
LetG be a k×n matrix, with rows gi1≤i≤k. The Schur matrix of G, denoted by SG consists of the rows gi∗gj for 1≤i≤j≤k.
We observe that ifG is a generator matrix of a code C, then its Schur matrix SG (or the submatrix which contains the linear independent rows of SG) is a generator matrix of the square code of C. For the k×n matrix G, the matrix SG at most has the size k+12×n (refer to [30]).
It is well known that the square of a linear codeCn,k has the dimension(16)dimC2≤minn,12kk+1,and a random linear code attains this upper bound with high probability.
One of the key features in most of the successful cryptanalysis efforts has been that the proposed codes have small Schur-product dimension which leads to key recovery or distinguishing attacks. In particular, this lends credence to the idea that codes with small Schur-product dimension appear to be unsuitable for use in the McEliece framework. For instance, if the code is generalized Reed–Solomon (GRS) code, then it satisfies(17)dimC2=minn,2k−1,and fulfills this lower bound with equality, i.e., for k<n/2, their square dimension is much smaller than one expects from a random code. Actually, this fact is, e.g., utilized by [14, 33] to build an effective distinguisher, yielding a structural attack on the GRS-based McEliece cryptosystem.
Looking at the definition of the square code, we observe that it is generated by all possible Schur-products of every pair of (nonnecessarily distinct) codewords in the given linear code. Therefore, it is natural to expect that the dimension of the square code is “as large as possible.” In other words, for a randomly chosen linear codeℛ, we expect that inequality (16) is actually an equality with very high probability.
Let us consider the recent work [34] which reported that it might possibly exist as a heuristic distinguisher, if given two specific weakly decreasing sets. However, in the case of our polarRLCE scheme, such sets could not be found easily because of the extended public codes by inserting random columns.
To illustrate the square attack, we performed simulation by generating 10,000 random sets of the public key matrix. Our experimental result shows that, as in the case of the proposed polarRLCE scheme, the square code of the public code can always reach the maximal dimension bound. Considering the choice of parameters (with 128-bit security) such thatn=2048, k=500, and w=50. So, we can obtain the k×n+w public key matrix Gpub. Denote the extended public code as Cpub. Hence, from inequality (16), we have(18)dimCpub2=dimSGpub≤minn+w,12kk+1.
For the proposed parameters, we observed experimentally that the dimension of the public matrix by the square product always reach maximum, that is to say,(19)dimSGpub=n+w=2098.
Furthermore, after perform random puncturing operations,PIGpub, alternatively, we can obtain(20)dimSPIGpub=n+w−I.
On the basis of the observations made as stated above, we claim that the technique of square attack regarding our polarRLCE could not be used to distinguish from random codes.


## 4.3. Key-Recovery Attack

The key-recovery attack is one of the important ways of structural attack, consists in recovering the private key from the public key. In this case, the methods are specific to the code family. In order to compute the private key of a given public key, it is often reduced to solve the code equivalence problem.Definition 7.
LetG and G∗ be the generating matrix for two n,k binary linear codes. Given G and G∗, there exist a k×k binary invertible matrix S and n×n permutation matrix P such that G∗=SGP?.
This problem was first studied by Petrank and Roth [35] over the binary field. And the most common algorithm used to solve this problem is the support splitting algorithm (SSA) [36]. SSA is very efficient in the random case, but it cannot be used in the case of codes with large hulls or codes with large permutation group such as Goppa codes and polar codes.
However, a very effective structural attack on the variant [23] using polar codes was introduced by Bardet et al. in [24]. Firstly, they managed to determine exactly the structure of the minimum weight codeword of the original polar codes. Then, they solved the code equivalence problem for polar codes with respect to decreasing monomial codes. Notice that this attack is very specific to the simple usage of polar codes in [23].
Regarding our proposal, there is a really effective way of protecting the scheme since the structure of the private code is someway shattered by inserting random elements. Thus, even though one can find enough low-weight codewords, while they are not subject to the original polar code, because that these codewords possess an extended lengthn+w which is generated by the public key matrix Gpub. The natural way is to perform puncturing operations, but an exponential number of codewords need to check since there are (21)n+ww=209850=2336.68.
On the other hand, the adversary cannot identify the inserted positions by distinguishing attack or square attack as stated on Section4.2. So, the code equivalence problem becomes even more complicated to solve in this case. Therefore, the attack by [24, 34] does not apply directly to our proposed polarRLCE scheme.
Finally, we notice that very recently, Couvreur et al. [20] presented a key-recovery attack on half the parameter sets proposed in the RLCE scheme [19]. They showed that it is possible to distinguish some keys from random codes by computing the square of some shortened public codes. The set of positions 1,…,n+w splitted into four parts based on the fact that the entry of any GRS codeword satisfies a specific expression formalization, i.e., dimGRSkx,y2=2k−1, and then recognizes the twin positions. While polar codes are used for the aforementioned situation because of the different structure between polar codes and GRS codes.
According to the aforementioned analysis and the fact that we found no other distinguishing methods for our proposal, we claim that it is indeed able to avoid the key-recovery attack.


## 4.4. Message-Decoding Attack

Message-decoding attack is an important issue in code-based cryptography. The problem of recovering the private message from a ciphertext is directly related to the hardness of generic decoding for the linear code. One possibility attack to recover the message is information set decoding (ISD) algorithm, which means to decode a random linear code without exploiting any structural property of the code. The ISD algorithm searches for an information set such that the error positions are all out of the information set. The work factor of ISD clearly increases with the number of errors added in the encryption process. Thus, when choosing parameters, we will focus mainly on defeating attacks of the ISD family.This technique was first introduced by Prange [37]. Hereafter, numerous different algorithmic techniques have been explored to improve complexity of ISD algorithm. Among several variants [26, 38–40] and generalizations, it is noteworthy that most modern ISD algorithms are based on Stern’s [38] algorithm, which incorporates collision search methods to speed up decoding.Thus, we will move on to analyze the complexity of Stern’s algorithm. Similarly, they try to find at-weight codeword in an n,k linear code C generated by F2k×n. More precisely, apart from the generator matrix G, the algorithm takes as input additional integer parameters p and l such that 0≤p≤t and 0≤l≤n−k. Each iteration consists of the steps described in Algorithm 1.Algorithm 1: Stern’s ISD algorithm.
Input: Generator matrix G∈F2k×n, with parameters t, p, and l.
Output: Codeword c∈C, s.t. wHc=t.
1 Select a random information setℐ from 1,2,…,n and divide it into two equal size subsets X and Y. Moreover, select a size-l subset Z of 1,2,…,n\ℐ.
2 PermutateG randomly, and let Gsys denote the systematic form: Gsys=IQJ
whereI is the k×k identity matrix, Q is a k×l matrix and J is a k×n−k−l matrix.
3 Letu run through all p-weight vectors of length k/2. Then, put all vectors x=u0Gsys in a sorted list ℒ1, sorted according to index ϕx, with ϕx being the value of a vector x in positions k+1 to k+l, i.e., ϕx=xk+1,xk+2,…,xk+l.
4 Then, construct another listℒ2 sorted according to ϕx, containing all vectors x=0uGsys, where u run through all p-weight vectors of length k/2.
5 Add all pairs of vectorsx∈ℒ1 and x′∈ℒ2 for which ϕx=ϕx′ and put in a new list ℒ.
6if there exists x∈ℒ, s.t. wHx=t−2p then
7 return the codewordc∈C corresponding to x.
8else
9 go back to Step 1;
10end(22)
P
stern
=
k
/
2
p
2
n
−
k
−
l
t
−
2
p
n
t
.Then, the probability of success in one single iteration isAnd the cost of one iteration of Stern’s algorithm is as follows:(23)n−k2n+k+k2−p+1+2lk2p+4pt−2p+1k2p22−l.We refer to the improved version of ISD attack algorithm in [26, 39], which is a generalization of Stern’s algorithm [38]. And they pointed out that for small fields (e.g., in our case, F2), choosing the new algorithm parameters c and r 1<r≤c should be taken into account, which can yield good speedups on the Gaussian elimination cost of each iteration. Furthermore, they offer an improved tool, which allows to compute a rough approximation of the security level of a code-based cryptosystem against information set decoding attacks.For a practical evaluation of the ISD running times and corresponding security level, similarly, most of the NIST PQCrypto code-based submissions exploited this complexity computation tool to determine the security level of their proposals, and we also use this tool to indicate the security level of our implementation. Note that the ciphertext length should ben+w instead of n in our case. According to this computation tool, we test different input parameters to classify expected bit security level κ≔128,192,256, respectively (see Section 4.6 for more details).


## 4.5. The KEM of polarRLCE Scheme

Key-encapsulation mechanisms (KEMs) are a common stepping stone aiming for the strong security goal, i.e., indistinguishability against adaptive chosen-ciphertext attacks (IND-CCA2). We also suggest a key-encapsulation mechanism (KEM) version of our polarRLCE scheme, consisting of three algorithms:KEM=KeyGen,Encaps,Decaps, by applying a transformation of Eaton et al.’s [29] observation. A favorable feature of this proposal is that the process of polarRLCE is convenient, and it enables our KEM-DEM version to achieve the negligible decryption failure rate within the corresponding security parameters. Let G, ℋ, and K be hash functions, typically SHA-3 as advised by NIST. Here, we show the KEM-DEM version below.KeyGen (pk,sk): exactly the same as polarRLCE key generation (Section 3), and generate a public/secret key pair pk,sk.Encaps (c,K): encapsulate a shared key K in ciphertext c as follows:(i)
Pick a seeds∈0,1k and set parallel degree P(ii)
Fori∈1,2,…,P, let ei=Gsi(iii)
Computexi=s+ℋeii, and the corresponding ciphertext ci = Enc.(pk, xi, ei)(iv)
Output the shared keyK=Ks and c=c1,…,cPDecaps (K): decapsulate the shared key K from ciphertext c with sk.(i)
Decrypt ciphertextc to get xi∗,ei∗, where i∈1,2,…,P.(ii)
Letj=i when the last step successfully decrypt for the current status, then compute s=xj+ℋejj.(iii)
Computeci∗ = Enc·(pk, xi∗, ei∗), obtain c∗ and verify that c∗=c. If so, return the shared key K=Ks.The same construction was proven to have IND-CCA2 guarantees in the work by [29]. More details regarding the security reduction can be found in [29].To provide IND-CCA2 for a given security level2κ, it is required for the decapsulation to have a correctness error δ≤2−κ. Recall that the DFR of our polarRLCE scheme is no more than 2−14. The resulting ciphertext includes several independent encapsulations with the same key so that a decapsulation failure occurs only if a decryption failure occurs in every instance of the underlying polarRLCE scheme. Willing to target a DFR of 2−κ, we can select the parallel degree P=10,14,19, respectively. Thus, our KEM version achieves the desired negligible target DFR value 2−140, 2−196, and 2−266.


## 4.6. Suggested Parameters for polarRLCE

In this section, we give the suggested parameters in 1 for our polarRLCE scheme, with the three most relevant standard security levels, 128-bit, 192-bit, and 256-bit. Besides, a comparison of the public key size for our suggested parameters with RLCE [19] (the secure second group parameters) and the original McEliece [26] scheme (under binary Goppa codes) is given in 2, together with the state-of-the-art NTS-KEM [41] and Classic-McEliece [42], which are moving on to the 2nd round of the NIST PQC standardization process.For convenience, we introduce the following notations of each column list in the tables:(i)
κ: security level(ii)
w: the number of inserted columns(iii)
n,k,t: code length n, code dimension k, and t is the error-correcting ability(iv)
PK: public-key size in kB(v)
SK: private-key size in KBytes(vi)
CT: ciphertext size in Bytes(vii)
WISD: the work factor of ISD attack algorithmTable 1
Set of parameters for polarRLCE scheme.
κ
n
,
k
,
t
w
PK
SK
CT
W
ISD
128
2
11
,
500,285
50
97.53
30.54
262.25
130.62
192
2
12
,
585,760
75
256.08
41.81
531.38
193.84
256
2
12
,
960,610
100
379.22
112.55
524.50
257.35Table 2
Public-key size comparison (in KBytes).
κ
Our
McEliece
RLCE
NTS-KEM
Classic-McEliece
128
97.53
187.69
187.53
312
255
192
256.08
489.4
446.36
907.97
511.88
256
379.22
936.02
1212.86
1386.43
1326We remark that the parameters given in Table1 may be vulnerable to the attack under the quantum random oracle model (QROM [43]). Here, we present the parameters solely to illustrate the rationality of our construction which, to our best knowledge, are secure against current known attacks.From Table2, we can see that our scheme can reduce the public key size of the original McEliece scheme by at least 52%. It has the apparent advantage to decrease the key size, especially on the high-security level. However, compared to the candidates based on hamming (rank) quasi-cyclic (QC) codes, the public key size of our proposal is inferior to them. Nevertheless, a new type of statistical analysis, called reaction attacks [44, 45], are threatening these schemes with a specific QC structure of the underlying codes [46, 47]. As a final remark, it would be required to consider the impact of reaction attacks even without the QC structure in our proposal.


## 5. Conclusion

To summarize, we have proposed a new variant of the code-based encryption scheme by exploring polar codes, benefitting the lower encoding and decoding complexity. We show that, for the proper choice of parameters together with the state-of-the-art cryptanalysis, it is still possible to design secure schemes to achieve the intended security level while keeping a reasonably small key size, using polar code.However, the disadvantage though is that the information rate is low. We can solve this issue by putting some information data in the error pattern, as shown by Biswas and Sendrier [48]. That is, some additional information bits are mapped into an error vector to be added in the encryption phase. Furthermore, future work in attempting to transfer our scheme to obtain a signature scheme may also be an interesting problem.



---

*Source: 3086975-2019-12-26.xml*