1. Introduction
The
r-round Even–Mansour (EM) block cipher, suggested by Bogdanov
et al. [
1], encrypts an
n-bit plaintext
m by
where
are secret keys and
are publicly known permutations, which are selected uniformly and independently at random, from the set of permutations of
. The confidentiality of the EM cipher is achieved even though the permutations
are made public. For
, Equation (1) reduces to the classical Even–Mansour construction [
2].
As a practical example, Bogdanov et al. defined the 128-bit block cipher AES2, which is an instantiation of the 2-round EM cipher where the two public permutations are AES with two publicly known “arbitrary” keys (they chose the binary digits of the constant π). The complexity of the best (meet-in-the-middle) attack they showed uses cipher revaluations. Consequently, they conjectured that AES2 offers 128-bit security.
Understanding the security of the EM cipher has been a topic of extended research. First, Even and Mansour [
2] proved, for
, that an adversary needs to make
oracle queries before he can decrypt a new message with high success probability. Daemen [
3] showed that this bound is tight, by demonstrating a chosen-plaintext key-recovery attack after
evaluations of
and the encryption oracle. Bogdanov
et al. [
1] showed, for the
r-round EM cipher,
, that an adversary who sees only
chosen plaintext-ciphertext pairs cannot distinguish the encryption oracle from a random permutation of
. This result has been recently improved by Chen and Steinberger [
4], superseding intermediate progress made by Steinberger [
5] and by Lampe, Patarin and Seurin [
6]. They showed that for every
r, an adversary needs
chosen plaintext-ciphertext pairs before he can distinguish the
r-round EM cipher from a random permutation of
. This bound is tight, by Bogdanov
et al.’s [
1] distinguishing attack after
queries.
Nikolić
et al. [
7] demonstrated a chosen-plaintext key-recovery attack on the single key variant (
) of the 2-round EM cipher. Subsequently, Dinur
et al. [
8] produced additional key-recovery attacks on various other EM variants. All the attacks in [
7,
8] are only slightly better than a brute force approach. For example, the attack ([
8]) on the single key variant of the 2-round EM cipher has time complexity
, and the attack ([
8]) on AES
2 (with three different keys) has complexity of
(still better than Bogdanov
et al. [
1], thus enough to invalidate their that AES
2 has
security).
The above attacks are based on the astute observation, made in [
7], that for a “typical” permutation
P of
, the distribution of
over uniformly chosen
is not uniform. Currently, this observation yields only weak attacks, but the unveiled asymmetry may have the potential to lead to stronger results.
This motivates the following question. Call a permutation P of “balanced” if the distribution of , over uniformly chosen , is uniform. Can we construct a block cipher based on balanced permutations? We point out that, a priori, it is not even clear that there exists a family of such permutations, that is large enough to support a block cipher construction.
In this work, we show how to generate a large family of balanced permutations of
, by observing that a 2-round Luby–Rackoff construction with any two identical
permutations of
, always yields a balanced permutation (of
). We use these permutations in an EM setup (illustrated in
Figure 2, top panel), to construct a block cipher with block size of
bits. Note that in this EM setup, the permutations
are not chosen uniformly at random from the set of all permutations of
. They are selected from a particular subset of the permutations of
, and defined via a random choice of two permutations of
, as the paper describes.
For the security of the resulting
bits block cipher, we would ideally like to maintain the security of the EM cipher (on blocks of
bits ). This would be guaranteed if we replaced the random permutation in the EM cipher, with an indifferentiable block cipher (as defined in [
9]). However, the balanced permutations we use in the EM construction are 2-round Luby–Rackoff permutations, and it was shown in [
10] that even the 5-round Luby–Rackoff construction does not satisfy indifferentiability. Therefore, it is reasonable to expect weaker security properties in our cipher. Indeed, we demonstrate a distinguishing (not a key recovery) attack that uses
queries. On the other hand, we prove that a smaller number of chosen plaintext-ciphertext queries is not enough to distinguish the block cipher from a random permutation of
.
We comment that the combination of EM and Luby–Rackoff constructions have already been used and analyzed. Gentry and Ramzan [
11] showed that the internal permutation of the Even–Mansour construction for
-bits block size can be securely replaced by a 4-round Luby–Rackoff scheme with public round functions. They proved that the resulting construction is secure up to
queries. Lampe and Seurin [
12] discuss
r-round Luby–Rackoff constructions where the round functions are of the form
,
is a public random function, and
is a (secret) round key. For an even number of rounds, this can be seen as a
-round EM construction, where the permutations are 2-round Luby–Rackoff permutations. They show that this construction is secure up to
queries, where
for non-adaptive chosen-plaintext adversaries, and
for adaptive chosen-plaintext and ciphertext adversaries. These works bare some similarities to ours, but the new feature in our construction is the emergence of balanced permutations.
The paper is organized as follows. In
Section 2, we discuss balanced permutations and balanced permutations EM ciphers.
Section 3 provides general background for the security analysis given in
Section 4. In
Section 5, we demonstrate the distinguishing attack. A practical use of our construction is a 256-bit block cipher is based on AES.
Section 6 defines this cipher and discusses its performance characteristics. We conclude with a discussion in
Section 7.
3. Security Preliminaries and Definitions
Let
A be an oracle adversary which interacts with one or more oracles. Suppose that
and
are two oracles (or a tuple of oracles) with the same domain and range spaces. We define the distinguishing advantage of
A distinguishing
and
as
The maximum advantage over all adversaries with complexity θ (which includes query, time complexities etc.) is denoted by . When we consider computationally unbounded adversaries (which is done in this paper), the time and memory parameters are not present and so we only consider query complexities. In the case of a single oracle, θ is the number of queries, and in the case of a tuple of oracles, θ would be of the form where denotes the number of queries to the oracle. While we define security advantages of , we usually choose to be an ideal candidate, such as the random permutation Π or a random function. The Pseudo Random Permutation advantage (PRP-advantage) of A against a keyed construction is . The maximum PRP-advantage with query complexity θ is denoted as .
In this paper, we always assume that queries to an oracle
are allowed in both directions,
i.e., to
as well. We denote
The Symmetric Pseudo Random Permutation advantage ( SPRP-advantage) of a keyed construction
(where the adversary has access to both the encryption
and its decryption
) is defined by
When a construction is based on one or more ideal permutations or random permutations and a key K, we define SPRP-advantage of a distinguisher A, in the presence of ideal candidates, as where Π is sampled independently of . We denote the maximum advantage by which we call SPRP-advantage in the ideal model. The complexity parameters of the above advantages depend on the number of oracles, and will be explicitly declared in specific instances.
We state two simple observations on the distinguishing advantages for oracles (we skip the proofs of these observations, as these are straightforward).
Observation 1. If
,
and
are three independent oracles, then
Observation 2. If
is an oracle construction, then (by using standard reduction)
where
r is the number of queries to
, needed to simulate one query to the construction
.
Note that in the Observation 2, we do not need to assume any kind of independence of the oracles. Analogous observations, up to obvious changes, hold for the case where are tuples of oracles.
3.1. Coefficient-H Technique
Patarin’s coefficient-H technique [
13] (see also [
14]) is a tool for showing an upper bound for the distinguishing advantage. Here is the basic result of the technique.
Theorem 1 (Patarin [
13])
. Let
and
be two oracle algorithms with domain
D and range
R. Suppose there exist a set
and
such that the following conditions hold:
For all
, …,
,
(the above probabilities are called interpolation probabilities).
For all A making at most q queries to , where , and denote the query and response of A to .
The above result can be applied for more than one oracle. In such cases, we split the parameter q into where denotes the maximum number of queries to the oracle. Moreover, if we have an oracle and its inverse , then the interpolation probability for both and can be simply expressed through the interpolation probability of only. For example, if an adversary makes a query y to and obtains the response x, we can write . Therefore, under the conditions of Theorem 1, we also have .
3.2. Known Related Results
3.2.1. The Security of Even–Mansour Cipher
It is known that the Even–Mansour cipher
is SPRP secure in the ideal model, in the following sense:
. The same is true for the single key variant
. In
Section 4, we provide (using Patarin’s coefficient-H technique) a simple proof of this result (Lemma 2) and a more general result (Lemma 3).
3.2.2. The Security of Luby–Rackoff Encryption
The 3-round Luby–Rackoff construction is PRP secure and the 4-round Luby–Rackoff construction is SPRP secure, when the underlying functions are PRPs (or Pseudo Random Functions). We use the following quantified version of the SPRP security of the 4-round case.
Theorem 2 (Piret [
15])
. Let
be four independent random permutations of
, and let Π be a random permutation of
. Then,
is SPRP secure in the following sense:
The above bound
is tight (see [
16]). In the proof of Theorem 7, we use the following, more general, result.
Theorem 3 (Nandi [
17])
. Let
, and let
be a sequence of numbers from
such that
. Let
be
t independent random permutations of
, and let Π be a random permutation of
. Then,
is SPRP secure in the following sense:
6. A Practical Construction of a 256-Bit Cipher
In this section, we demonstrate a practical construction of a 256-bit block cipher based on the 2-round BPEM cipher, where the underlying permutation is AES.
Definition 4 (
: a 256-bit block cipher)
. Let and be two 128-bit keys and let be three 256-bit secret keys (assume are selected uniformly and independently at random). Let the permutations and be the AES encryption using and as the AES key, respectively.
The 256-bit block cipher is defined as the associated instantiation of the 2-round BPEM cipher .
Usage of
:
and are determined during the setup phase, and can be made public (e.g., sent from the sender to the receiver as an IV).
are selected per encryption session.
The single key EM256AES is the special case where a single value and a single value are selected uniformly and independently at random, and the EM256AES cipher uses and .
Hereafter, we use the single key EM256AES. To establish security properties for
, we make the standard assumption about AES with a secret key that is selected (uniformly at random): an adversary has negligible advantage in distinguishing AES from a random permutation of
even after seeing a (very) large number of plaintext-ciphertext pairs (
i.e., the assumption is that AES satisfies its design goals ([
19],
Section 4). This assumption is certainly reasonable if the number of blocks that are encrypted with the same keys is limited to be much smaller than
(note that AES can also be argued to be secure in a known-key setting, although this property is not part of the design goals of AES [
20,
21]). Therefore, in our context, we can consider assigning the randomly selected key
ℓ at setup time, as an approximation for a random selection of the permutations
and
(which are identical). Under this assumption, we can rely on the result of Theorem 7 for the security of
.
Efficiency
An encryption session between two parties requires exchanging a 256-bit secret key and transmitting a 128-bit IV (). One key (and IV) can be used for N blocks as long as we keep . Computing one (256-bit) ciphertext involves four AES computations (with the as the AES key) plus a few much cheaper XOR operations. Let us assume that the encryption is executed on a platform that has the capability of computing AES at some level of performance. If the encryption (decryption) is done in a serial mode, we can estimate the encryption rate to be roughly half the rate of AES (serial) computation on that platform (4 AES operations per one 256-bit block). Similarly, if the encryption is done in a parallelized mode, we can estimate the throughput to be roughly half the throughput of AES.
Performance
To test the actual performance of
, and validate our predictions, we coded an optimized implementation of
. Its performance is reported here. The performance was measured on an Intel® Core
TM i7-4700MQ (microarchitecture Codename Haswell) where the enhancements (Intel® Turbo Boost Technology, Intel® Hyper-Threading Technology, and Enhanced Intel Speedstep® Technology) were disabled. The code used the AES instructions (AES-NI) that are available on such modern processors. On this platform, we point out the following baseline: the performance of AES (128-bit key) in a parallelized mode (CTR) is
C/B, and in a serial mode (CBC encryption) it is
cycles per byte (C/B hereafter). The measured performance of our
implementation was
C/B for the parallel mode, and
C/B for the serial mode. The measured performance clearly matches the predictions. It is also interesting to compare the performance of
to another 256-bit cipher. To this end, we prepared an implementation of Rijndael256 cipher [
22] (we point out that although AES is based on the Rijndael block cipher, the AES standardizes only a 128 block size, while the Rijndael definitions support both 128-bit and 256-bit blocks). For details on how to code Rijndael256 with AES-NI, see [
23]). Rijndael256 (in ECB mode) turned out to be much slower than
, performing at
C/B.
7. Conclusions
In this work, we showed how to construct a large family of balanced permutations, and analyzed the resulting new variation, BPEM, of the EM cipher.
The resulting -bit block cipher is obtained by using a permutation of as a primitive. The computational cost of encrypting (decrypting) one -bit block is four evaluations of a permutation of (plus a relatively small overhead). Note that this makes BPEM readily useful in practice, for example to define a 256-bit cipher, because “good” permutations of are available. We demonstrated the specific cipher , which is based on AES, and showed that its throughput is (only) half the throughput of AES (and times faster than Rijndael256).
A variation on the way by which BPEM can be used, would make it a tweakable -bit block cipher. Here, the public IV (=ℓ) can be associated with each encrypted block as an identifier, to be viewed as the tweak. The implementation would switch this tweak for each block. To randomize the keys for the (public) permutations, an additional encryption (using some secret key) is necessary.
The expression of the advantage in Theorem 4 behaves linearly with the number of queries to the public permutations, and quadratically with the number of queries to the encryption/decryption oracle. This reflects the intuition that the essential limitations on the number of adversary queries should be on the encryption/decryption invocations, while weaker (or perhaps no) limitations should be imposed on the number of queries to the public permutations. It also suggests the following protocol, where the secret keys are changed more frequently than the random permutations. Choose the public permutations for a period of, say, blocks, divided into sessions of blocks. Change the secret keys every session. This way, the relevant information on the block cipher, from a specific choice of keys, is limited to a session, while the adversary can accumulate relevant information from replies to the public permutations across sessions. Therefore, is limited to , while is limited to . Theorem 4 guarantees that this usage is secure.