Practical Inner Product Encryption with Constant Private Key †

: Inner product encryption, ﬁrst introduced by Katz et al., is a type of predicate encryption in which a ciphertext and a private key correspond to an attribute vector and a predicate vector, respectively. Only if the attribute and predicate vectors satisfy the inner product predicate will the decryption in this scheme be correct. In addition, the ability to use inner product encryption as an underlying building block to construct other useful cryptographic primitives has been demonstrated in the context of anonymous identity-based encryption and hidden vector encryption. However, the computing cost and communication cost of performing inner product encryption are very high at present. To resolve this problem, we introduce an efﬁcient inner product encryption approach in this work. Speciﬁcally, the size of the private key is only one G element and one Z p element, and decryption requires only one pairing computation. The formal security proof and implementation result are also demonstrated. Compared with other state-of-the-art schemes, our scheme is the most efﬁcient in terms of the number of pairing computations for decryption and the private key length. decisional Difﬁe–Hellman assumption. Comparison and experimental results are also provided to illustrate that the size and computing cost of this scheme are small. In future works, we aim to improve the efﬁciency by reducing the ciphertext length and provide a security proof for stronger security concerns under standard assumptions. Because the proposed scheme is based on bilinear pairing, it cannot resist quantum attacks, unlike lattice-based IPE schemes. In future work, we will explore how to construct an efﬁcient and practical quantum-resistant IPE scheme.


Introduction
Inner product encryption (IPE), first introduced by Katz et al. [1], is a type of predicate encryption [2] in which a ciphertext and a private key correspond to an attribute vector x and a predicate vector y, respectively. In particular, the decryption will be correct if and only if the attribute vector and the predicate vector satisfy the inner product predicate, meaning that the inner product operation of x and y equals zero ( x, y = 0). Over the past decade, many IPE schemes have been proposed, such as those based on pairing [3][4][5][6][7] and lattice [8][9][10][11]. The security definition of an IPE scheme [1] can be naturally extended from the IND-CPA security of identity-based encryption [12][13][14]. More precisely, under the security approach of IPE, an adversary learns nothing about the encrypted message from a ciphertext associated with an attribute vector x if they do not own the private key associated with a predicate vector y such that x, y = 0. Such a definition is also called the IND-CPA security for IPE scheme in some papers [15] and is defined as the payload-hiding property in [1]. Alternatively, the security definition defined in [1], called the attribute-hiding property, states that a ciphertext reveals nothing about the corresponding ciphertext attribute x. However, we emphasize that the attribute-hiding property is not an absolutely necessary property for IPE. Many IPE schemes proposed in the literature achieve only IND-CPA security/payload hiding, such as that in [15][16][17].
In addition to their usefulness in fine-grained access control, IPE schemes can be used to construct various cryptographic primitives or can be converted to more complex primitives, such as identity-based encryption [12][13][14], hidden vector encryption [2,18] and subset predicate encryption [19,20]. We refer readers to the work presented in [1,19] for details.
Although many IPE schemes have been introduced, the computing cost and communication cost of these schemes are high. In particular, the pairing operation required by existing pairing-based IPE schemes is typically linearly related to the vector length; therefore, the computational efficiency of these schemes is low. Moreover, the size of the private key of most schemes is linearly related to vector lengths. However, although the existing lattice-based IPE schemes are considered quantum-resistant, the key size of almost all schemes is too large or the message space is too small. In addition, Internet of Things devices are gradually becoming common in daily life; however, the problems mentioned in the preceding discussion make the application of an IPE scheme impractical for these resource-constrained devices. Thus, an unresolved question remains: can we obtain an efficient IPE scheme by reducing the cost of decryption and optimizing the length of the private key?

Our Contributions
Herein, we resolve the aforementioned problem by introducing an effective IPE scheme. In particular, in the proposed scheme, the length of a private key is independent of the length of the predicate vector. In addition, the decryption only requires one pairing operation; thus, the decryption is also independent of the length of the predicate vector. Rigorous proofs are provided to demonstrate that, under a modified decisional Diffie-Hellman assumption, our proposed scheme is coselective IND-CPA secure. Moreover, our proposed scheme is more efficient than other advanced schemes, as listed in Tables 1 and 3.

Pairing-Based IPE Schemes
The first IPE scheme, introduced by Katz et al. [1], entails the evaluation of predicates over Z N using the inner product, where N is a composite number. After this pioneering work, many studies followed. For example, Okamoto and Takashima [3] proposed the first hierarchical predicate encryption method (or delegable predicate encryption) for inner product predicates; this provides a user with functionality to delegate more restrictive functionality to another user. Attrapadung and Libert [16] constructed an IPE scheme that solves the inefficiency problem of the previous scheme. More precisely, provided that the description of the ciphertext attribute vector is not included in the ciphertext, the ciphertext overhead of the scheme is reduced to O(1). By combining dual system encryption [21] and dual pairing vector spaces [3] carefully, Lewko et al. [22] obtained the first fully secure IPE scheme and hierarchical predicate encryption under the n-extended decisional Diffie-Hellman assumption. However, the security of all these previous studies was based on nonstandard assumptions. To resolve this issue, Park [23] developed the first IPE scheme under the standard assumptions (i.e., decisional bilinear Diffie-Hellman and decisional linear (DLIN) assumptions). Okamoto and Takashima [24] then introduced two nonzero inner product encryption schemes that support constant-size ciphertexts and a constant-size secret key, respectively, which are adaptively secure under the DLIN assumption in the standard model. The authors also proposed the first IPE scheme that is fully secure and fully attribute-hiding [25] as well as the first unbounded IPE scheme that is also fully secure and fully attribute-hiding in the standard model under the DLIN assumption [26]. Kawiai and Takashima [27] introduced a new notion, called IPE with ciphertext conversion, which considers the security of predicate-hiding. Zhenlin and Wei [28] then introduced another concept, called multiparty cloud computation IPE with multiplicative homomorphic property, which enables an IPE scheme to support multiparty cloud computation. Kim et al. [29] proposed a new efficient IPE scheme that only requires n exponentiation and three pairing computations for decryption. Huang et al. [30] proposed the first enabled-disabled IPE, which supports timed-release services and data self-destruction. Ramanna [15] constructed two IPE schemes using tag-based quasi-adaptive noninteractive zero knowledge, where the first and second both have the property of constant-size ciphertext but only the second has the property of attribute-hiding. Zhang et al. [7] recently proposed a new IPE scheme based on a double encryption system; it has been demonstrated to achieve adaptive security under a weak attribute-hiding model.
As discussed subsequently, extensive research has focused on the developed and proposed schemes; however, the private key length of most schemes is linearly dependent on the vector length or requires many pairing operations, making these schemes impractical. Thus, determining how to construct a more practical scheme remains a critical area of research.

Lattice-Based IPE Schemes
To fend off attack from quantum computers in the future, Agrawal et al. [8] proposed the first IPE scheme based on the lattice hard assumption (i.e., the learning with error assumption, which is believed to be able to withstand quantum attacks); to do so, they modified an identity-based encryption approach proposed by Agrawal et al. [31]. Xagawa [9], inspired by the work of Agrawal et al., proposed an improved lattice-based IPE scheme that reduced the size of public parameters and ciphertext. Li et al. [10] proposed a lattice-based IPE scheme that further reduced the size of public parameters and ciphertext. In contrast to [9], their work reduced the size by a factor of log n, where n is the security parameter. Wang et al. [11] recently proposed the first compact IPE scheme that employs an IPE scheme [9], fully homomorphic encryption [32] and vector-encoding schemes [33]. Although these constructions are thought to be able to withstand quantum computer attacks, they are based on the learning with errors assumption, resulting in key lengths that are still too large to be practical.

Organization
The remainder of this paper is organized as follows. In Section 2, we start by discussing some preliminaries on bilinear maps, complexity assumptions and the definition of IPE. In Section 3, we then propose our IPE scheme and demonstrate its correctness. In Section 4, we subsequently demonstrate security proofs using a modified decisional Diffie-Hellman problem, and then in Section 5, we compare our approach with other state-of-the-art schemes and reveal the implementation results. In Section 6, we finally conclude the paper.

Preliminaries
Herein, we present the necessary preliminaries, such as notations, complex assumptions, and the definition of an IPE scheme.

Notations
Throughout this paper, we use x $ ← − S to denote "choose an element x randomly and uniformly from the set S" and x ← A to denote "x is the output of the algorithm A". Moreover, we use a to denote a vector and use a i to denote the i-th entry of vector a. The inner product of these two vectors x, y is denoted as x, y . For a prime p, we use Z p to denote the set of integers modulo p. Finally, we use N and Z to denote the set of positive integers and integers, respectively.

Bilinear Maps
Let G and G T be an additive and a multiplicative cyclic group, respectively; here, the order of G and G T is a large prime p (i.e., |G| = |G T | = p). Then, let P be a generator of G. A bilinear map (pairing) e : G × G → G T is a mapping with the following properties: • Bilinearity: For a, b ∈ Z p , e(aP, bP) = e(P, P) ab . • Nondegeneracy: ∃P ∈ G, such that e(P, P) = 1 G T . • Computability: The mapping e is efficiently computable.
In this work, we take advantage of the generalized decisional Diffie-Hellman exponent (GDDHE) problem, based on [34]. The GDDHE problem is a generic framework within which new complexity assumptions can be created. We first give an overview of the GDDHE problem. Let • p be a prime; • s, n be two positive integers; • P, Q ∈ F p [X 1 , . . . , X n ] s be two s-tuple of n-variate polynomials over F p ; and • f be an n-variate polynomial in F p [X 1 , . . . , X n ].
Q, Q T are two ordered sets with multivariate polynomials, and thus, we define Q = (q 1 , q 2 , . . . , q s ) and R = (r 1 , r 2 , . . . , r s ). As stated in [34], we require p 1 = q 1 = 1 to be two constant polynomials. Consider a bilinear map e : G × G → G T with the generator P of G and g T = e(P, P) ∈ G T . For a vector (x 1 , x 2 , . . . , x n ) ∈ F n p , we define We say that f is independent of (Q, R) if f does not depend on (Q, R).
Then, for an algorithm A, the advantage of A in solving the (Q, R, f )-GDDHE problem is defined as and demonstrate that a large class of hard problems can be fit into the framework of the GDDHE problem; for instance, the DDH problem over G T . Definition 2 (The decisional Diffie-Hellman problem over G T (DDH G T problem)). Let g T = e(P, P) be a generator of G T . Given (P, or an random element from G T . Observe that no constants exist such that the linear combination of 1, a, b equals ab; therefore, f is independent of (Q, R). Given the result of Boneh et al., we conclude that no algorithm is available with which to solve the DDH G T problem with a nonnegligible advantage. See [34] for additional details.
Next, we present a modified version of the DDH G T problem, which will be used in the security proof. Definition 3 (The modified decisional Diffie-Hellman problem over G T (M-DDH G T problem)). Let g T = e(P, P) be a generator of G T . Given (P, T or a random element from G T . Theorem 1 (The modified decisional Diffie-Hellman assumption over G T (M-DDH G T assumption)).
We say that the M-DDH G T assumption holds if there is no algorithm D for solving the M-DDH G T problem with a nonnegligible advantage.
Proof. Compared with the DDH G T problem, the instance of the M-DDH G T problem contains an No constants exist such that the linear combination of the monomials (1 · a), 1, a, b equals the polynomial ab. Therefore, considering the the results of Boneh et al., we conclude that the M-DDH G T problem is hard. Moreover, we define the advantage for an algorithm D in solving the M-DDH G T problem as

Definition of Inner Product Encryption
An IPE scheme consists of four algorithms: Setup, KeyGen, Encrypt and Decrypt. The details of the algorithms are as follows: • Setup(1 λ , 1 ). Take as inputs the security parameters (1 λ , 1 ), where λ, ∈ N, and the algorithm outputs the system parameter params and the master secret key msk. The descriptions of the attribute vector space A and the predicate vector space P are implicitly included in params. Moreover, the inner product operation over A and P must be well defined. • Encrypt(params, x, M). Given the system parameter params, an attribute vector x ∈ A and a message M, the algorithm outputs a ciphertext C x for the attribute vector x. • KeyGen(params, msk, y). Given the system parameter params and a predicate vector y ∈ P, the algorithm outputs the private key K y for the predicate vector y. • Decrypt(params, C x , K y ). Given the system parameter params, a ciphertext C x and the private key K y , the algorithm outputs a message M or a error symbol ⊥.

Security Model
Here, we first introduce IND-CPA security for IPE. The IND-CPA game of IPE for the attribute vector space A and predicate vector space P is defined as an interactive game between a challenger C and an adversary A.
• Setup. The challenger C runs Setup(1 λ , 1 ) and sends the system parameter params to the adversary A.
• Query Phase 1. The challenger polynomially answers many private key queries for y ∈ P for the adversary A by returning K y ← KeyGen(params, msk, y). • Challenge. The adversary A submits an attribute vector x * ∈ A such that x * , y = 0 for all y that have been queried in Query Phase 1 and two messages M 0 , M 1 with the same length to challenger C. Then, C randomly chooses β ∈ {0, 1} and returns a challenge ciphertext C x * ← Encrypt(params, x * , M β ). • Query Phase 2. This phase is the same as Query Phase 1, except that the adversary is not allowed to make a query with y ∈ P such that x * , y = 0. • Guess. The adversary A outputs a bit β and wins the game if β = β.
The advantage of an adversary for winning the IND-CPA game is defined as

Definition 4 (IND-CPA Security for IPE).
We say that an IPE is IND-CPA secure if there is no probabilistic polynomial-time adversary A who wins the IND-CPA game with a nonnegligible advantage.
As we mentioned in Section 1, in some literature [1,23], the security notions for an IPE are defined with the notions "payload hiding" and "attribute hiding". Informally, payload-hiding (or attribute-hiding) is defined to argue that a ciphertext leaks no information about the encrypted message (or attribute vector). The IND-CPA security shown in this section is equivalent to payload-hiding. We emphasize that attribute-hiding is unnecessary for an IPE scheme; in [15][16][17], schemes have been proposed satisfying only payload hiding.
We next present the selective security and the coselective security [16,35] for IPE. The selective IND-CPA (sIND-CPA) game is defined the same as the IND-CPA game, except that the adversary A is forced to commit before the Setup phase to an attribute vector x * , and A is not allowed to make private key queries with y such that x * , y = 0 in both Query Phase 1 and Query Phase 2.
Definition 5 (sIND-CPA Security for IPE). An IPE scheme is said to be sIND-CPA secure if no probabilistic polynomial-time adversary wins the sIND-CPA game with a nonnegligible advantage.
The coselective IND-CPA (csIND-CPA) game is defined as equal to the IND-CPA game, except that the adversary A is forced to commit before the Setup phase q to predicate vectors y (1) , . . . , y (q) for the private key queries, where q is a polynomial in the security parameter λ and A is required to invoke the Challenge phase with an attribute vector x * such that x * , y (j) = 0 for j = 1, . . . , q.
Definition 6 (csIND-CPA Security for IPE). An IPE scheme is said to be csIND-CPA secure if no probabilistic polynomial-time adversary wins the csIND-CPA game with a nonnegligible advantage.
Coselective security can be understood as a complementary notion to selective security. In the selective security game, the adversary can learn the private key in accordance with its previous choices, whereas in the coselective security game, the adversary can choose its target after seeing the public parameter and learning the private keys of its choice. Although selective security and coselective security are weaker than full security, both notions are, by definition, incomparable in general by definition.

Proposed Inner Product Encryption Scheme
Our IPE scheme consists of four algorithms: Setup, KeyGen, Encrypt and Decrypt. The details of the proposed scheme are explained in the following.
1. Choose bilinear groups G, G T of prime order p > 2 λ . Let P and g T = e(P, P) be the generator of G and G T , respectively. 2. Set the predicate vector space and the attribute vector space to Z p .
• Encrypt(params, x, M). Given the system parameter params, a vector x = (x 1 , x 2 , . . . , x ) ∈ Z p , and a message M ∈ G T , the algorithm performs as follows.
• Decrypt(params, C x , K y ). Given the system parameter params, a ciphertext C x , and the private key K y , where y = (y 1 , y 2 , . . . , y ) the algorithm performs as follows.

Correctness
The correctness of the proposed scheme is shown as follows.

Security Analysis of the Proposed Scheme
We now provide the security proof for the coselective security of the proposed IPE scheme. In the subsequent proof, we view a vector as a row vector.

Theorem 2.
The proposed scheme is csIND-CPA secure for q private key queries, where q is a polynomial in the security parameter λ, under the M-DDH G T assumption.
Proof. Given (P, A = aP, g T , A = g a T , B = g b T , C), we build an algorithm C using the adversary A to solve the M-DDH G T problem as follows.
• Challenge. Upon receiving x * , where x * , y (i) = 0 for i = 1, . . . , q, and two equal-length messages M 0 , M 1 from A, the challenger C performs the following.
Here, we implicitly set the randomness of the encryption procedure to a. Therefore, if C = g ab T , then we have C 0 = aP, C 0 = g a T for i = 1, . . . , , Thus, the challenge ciphertext C * is a valid ciphertext.
• Query Phase 2. This phase is the same as Query Phase 1.
• Guess. The adversary A outputs a bit β . The challenger C outputs 1 if A wins the game and outputs a random bit otherwise.
Assume that the adversary A wins the game with advantage : If C = g ab T , then the view of the adversary is identical as that in real world. Thus, we have However, if C is a random element in G T , then the choice of β is independent from the adversary's view and we have Pr[C(P, A , g T , A, B, C 2 . Therefore, the advantage of C in solving the M-DDH G T problem is This means that if there is an adversary winning the game with nonadvantage , then there is an algorithm C solving the M-DDH G T problem with a probability greater than .

Efficiency Analysis and Implementation Results
Herein, we compare the efficiency of the proposed IPE scheme with the schemes proposed in [1,3,[5][6][7]15,16,[22][23][24][25][26][27][28][29][30]36] (Because [4,17] are the complete versions of [16,24], we only compare our work with [16,24]). As shown in Table 1, we compare our scheme to others in two aspects: the size of the private key and the number of pairing operations for decryption. The type of group order is also presented because the efficiency of prime order groups is higher than that of composite order bilinear groups.
As is evident in Table 1, our proposed scheme has the shortest private key length and smallest number of pairings. Moreover, both the private key length and the number of pairings in our proposed scheme are independent of the length of the predicate and attribute vectors. The most efficient existing scheme is [29], where the private key length is three group elements and three pairings are needed for decryption. In our scheme, the private key is only an element of G and an element of Z p , and only one pairing is necessary during decryption. Furthermore, in [5], the private key length (2m|G|) and the number of pairings (2m) are independent of the lengths of the vectors, where m is the leakage-resilience parameter. However, m must be at least equal to or greater than 2. Therefore, the private key length and pairing number are still larger than those obtained with our approach (this is because their scheme degenerates to a conventional IPE scheme without leakage resilience when m = 1). Table 1. Comparison of our scheme's efficiency with that of other schemes. The vector length for an IPE scheme is denoted by ; the bit lengths of the representations for an element in Z p and G are denoted by |Z p | and |G|, respectively; the leakage resilience parameter is denoted by m.

Scheme
Private Key Length Number of Pairings for Decryption Group Order [1] (2 + 1)|G| 2 + 1 Composite [3] ( + We also implemented our scheme and the schemes of [15,17,29] to compare efficiency. We chose these three schemes for the following reasons: • Among all the existing IPE schemes, the first scheme of [16] requires the smallest number of pairings for decryption (only two pairings required); • Among the schemes supporting constant private key length, the schemes of [15,29] require the smallest number of pairings for decryption (only three pairings required).
The environment of the implementation is presented in Table 2, and the implementation results are shown in Table 3. We implemented these schemes by using the Charm-Crypto library [37] and Python language. For schemes constructed over symmetric paring groups (the approach in [16] and our method), we selected the pairing group SS512 in [38] (also known as type A groups), and for the schemes constructed over asymmetric pairing groups (in [15,29]), we chose the pairing group BN254 in [39] (also known as type F groups). The SS512 group is a supersingular elliptic curve group where the size of the base field order is 512 bits and the embedding degree is two. For a bilinear map e : G × G → G T over the SS512 group, the bit lengths of elements in G and G T are 64 and 128 bytes, respectively. In the case of the BN254 group, the size of the base field order is 256 bits and the embedding degree is 12. For a bilinear map e : G 1 × G 2 → G T over the BN254 group, the bit lengths of elements in G 1 , G 2 , and G T are 64, 128, and 384 bytes, respectively. For the length of predicate and attribute vectors, we chose = 100. As evident in Table 3, the encryption and decryption algorithms of our scheme were highly efficient. For decryption and encryption, only 10 and 20 ms was required, respectively. Our encryption algorithm was 5, 8.5, and 13 times faster than that in [15,16,29], respectively, and our decryption algorithm was 10, 14, and 14 times faster than that in [15,16,29], respectively. Moreover, our private key length was 86, 2.6, and 4.3 times shorter than that in [15,16,29], respectively. However, as a trade-off, the length of the ciphertext in our scheme was the largest among these schemes.

Conclusions
In this work, an efficient IPE scheme in which the size of the private keys and the number of pairings for decryption are constant is introduced; moreover, this scheme is coselective IND-CPA secure under the modified decisional Diffie-Hellman assumption. Comparison and experimental results are also provided to illustrate that the size and computing cost of this scheme are small. In future works, we aim to improve the efficiency by reducing the ciphertext length and provide a security proof for stronger security concerns under standard assumptions. Because the proposed scheme is based on bilinear pairing, it cannot resist quantum attacks, unlike lattice-based IPE schemes. In future work, we will explore how to construct an efficient and practical quantum-resistant IPE scheme.

Conflicts of Interest:
The authors declare no conflict of interest.