Docsity

Security for Multiple Messages - Lecture Notes | CMSC 858K, Study notes of Computer Science

Toggle sidebar
bg1
CMSC 858K — Advanced Topics in Cryptography February 3, 2004
Lecture 3
Lecturer: Jonathan Katz Scribe(s):
Abheek Anand
Gelareh Taban
Radostina Koleva
1 Introduction
In the last lecture, we introduced the notion of semantic security and gave a formal definition
for semantic security with respect to public-key encryption schemes. It was shown that given
the existence of hard-core bits, it is possible to construct a semantically secure public-key
encryption scheme for messages of length one bit. In this lecture, we introduce the hybrid
technique and use it to prove that semantic security of the constructed encryption scheme
can be extended to polynomially-many messages (of arbitrary polynomial length).
We begin by reviewing the construction of a semantically-secure public-key encryption
scheme from a trapdoor permutation. Let F= (Gen,Eval,Invert) be a trapdoor permutation
family and H={hk}be a hard-core bit for F. Then we can construct the following public-
key encryption scheme PK E = (KeyGen,E,D) for the encryption of 1-bit messages:
KeyGen(1k): (f, f −1)←Gen(1k)
P K = (f, hk)
SK =f−1
EP K (m): r← {0,1}k
output hf(r), hk(r)⊕mi
DSK (hy, bi): output b⊕hk(f−1(y))
We showed in class last time that the encryption scheme above is semantically secure. In
particular, this implies the following theorem:
Theorem 1 Assuming trapdoor permutations exist, there exists a public-key encryption
scheme achieving semantic security (or security in the sense of indistinguishability).
2 Security for Multiple Messages
The encryption scheme above is semantically secure for messages of length one bit. Would
the scheme remain secure if it is applied (in the natural bit-by-bit fashion1) to messages
of length longer than one bit? Equivalently, is the scheme still secure if it is used to
encrypt multiple messages, each of length one bit? If the adversary is able to eavesdrop
1Here, encryption of m=m1···m`(with mi∈ {0,1}) is given by EPK (m1)· · · EP K (m`). The only
subtlety here is that independent random coins must be used for every invocation of the encryption algorithm.
3-1
pf3
pf4
pf5

Partial preview of the text

Download Security for Multiple Messages - Lecture Notes | CMSC 858K and more Study notes Computer Science in PDF only on Docsity!

CMSC 858K — Advanced Topics in Cryptography February 3, 2004

Lecture 3

Lecturer: Jonathan Katz Scribe(s):

Abheek Anand Gelareh Taban Radostina Koleva

1 Introduction

In the last lecture, we introduced the notion of semantic security and gave a formal definition for semantic security with respect to public-key encryption schemes. It was shown that given the existence of hard-core bits, it is possible to construct a semantically secure public-key encryption scheme for messages of length one bit. In this lecture, we introduce the hybrid technique and use it to prove that semantic security of the constructed encryption scheme can be extended to polynomially-many messages (of arbitrary polynomial length). We begin by reviewing the construction of a semantically-secure public-key encryption scheme from a trapdoor permutation. Let F = (Gen, Eval, Invert) be a trapdoor permutation family and H = {hk } be a hard-core bit for F. Then we can construct the following public- key encryption scheme P KE = (KeyGen, E, D) for the encryption of 1-bit messages:

KeyGen(1k): (f, f −^1 ) ← Gen(1k^ ) P K = (f, hk) SK = f −^1

EP K (m): r ← { 0 , 1 }k output 〈f (r), hk(r) ⊕ m〉

DSK (〈y, b〉): output b ⊕ hk(f −^1 (y))

We showed in class last time that the encryption scheme above is semantically secure. In particular, this implies the following theorem:

Theorem 1 Assuming trapdoor permutations exist, there exists a public-key encryption scheme achieving semantic security (or security in the sense of indistinguishability).

2 Security for Multiple Messages

The encryption scheme above is semantically secure for messages of length one bit. Would the scheme remain secure if it is applied (in the natural bit-by-bit fashion^1 ) to messages of length longer than one bit? Equivalently, is the scheme still secure if it is used to encrypt multiple messages, each of length one bit? If the adversary is able to eavesdrop (^1) Here, encryption of m = m 1 · · · m(with mi ∈ { 0 , 1 }) is given by EP K (m 1 ) · · · EP K (m). The only subtlety here is that independent random coins must be used for every invocation of the encryption algorithm.

on these messages, will she obtain extra information (perhaps correlated information about the various messages) and be able to break the semantic security of the encryption scheme? To model this stronger attack scenario where the adversary can intercept multiple mes- sages via eavesdropping, we introduce the concept of an encryption oracle EP K,b(·, ·) which the adversary can query as many times as it wants. This oracle takes as input two messages

m 0 , m 1 of equal length, and we define EP K,b(m 0 , m 1 ) def = EP K (mb) (where new random coins are used to encrypt mb each time the oracle is invoked). A scheme is secure if the adversary cannot guess the value of the bit b used by the encryption oracle (with much better than probability 1/2). A formal definition follows.

Definition 1 A public-key encryption scheme P KE = (KeyGen, E, D) is secure in the sense of left-or-right indistinguishability if the following is negligible (in k ) for any ppt adversary:

∣ ∣∣Pr^ [ (P K, SK) ← KeyGen(1k (^) ); b ← { 0 , 1 } : AEP K,b (·,·)(P K) = b^ ] − 1 / 2

Theorem 2 If a public-key encryption scheme P KE = (KeyGen, E, D) is semantically se- cure, then it is also secure in the sense of left-or-right indistinguishability.

Proof To prove this theorem, the hybrid argument is introduced. This technique plays a central role in demonstrating the indistinguishability of complex ensembles based on the indistinguishability of simpler ensembles. However, before we define the technique and prove the more general case, we will show that a semantically secure encryption scheme (for one message) is secure in the sense of left-or-right indistinguishability when two messages are encrypted. This is represented by allowing the adversary to have oracle access to the encryption oracle twice. We will, as usual, perform a proof by contradiction: assume toward a contradiction that P KE is semantically secure but not left-or-right secure. This means that we have a ppt adversary A that can break the P KE in the left-or-right indistinguishability sense with non-negligible probability. Using this adversary we will construct a ppt algorithm that breaks the semantic security of the P KE with non-negligible probability. This is a contradiction as according to the theorem P KE is semantically secure. In what follows we will let the key generation step be implicit in order to make the notation more readable. Construct adversary Aˆ 1 that can access the encryption oracle just once, and tries to break semantic security as follows:

AˆE 1 P K,b (·,·)(P K) Run A(P K) At some point A asks for EP K,b(m 0 , m 1 ) Aˆ 1 queries its own encryption oracle and returns c ← EP K,b(m 0 , m 1 ) to A Later, A requests a second encryption EP K,b(m′ 0 , m′ 1 ) Aˆ 1 returns c′^ ← EP K (m′ 0 ) to A (i.e., it encrypts m′ 0 itself ) Aˆ 1 outputs the final output of A

· Pr

[

(P K, SK) ← KeyGen(1k^ ) : AEP K,^1 (·,·),EP K,^1 (·,·)(P K) = 1

]

· Pr

[

(P K, SK) ← KeyGen(1k) : AEP K,^1 (·,·),EP K,^0 (·,·)(P K) = 0

]

· Pr

[

(P K, SK) ← KeyGen(1k) : AEP K,^1 (·,·),EP K,^0 (·,·)(P K) = 1

]

· Pr

[

(P K, SK) ← KeyGen(1k) : AEP K,^0 (·,·),EP K,^0 (·,·)(P K) = 0

]

where we use the fact (from basic probability theory) that

Pr

[

AEP K,^1 (·,·)EP K,^0 (·,·)(P K) = 0

]

  • Pr

[

AEP K,^1 (·,·)EP K,^0 (·,·)(P K) = 1

]

Continuing, we obtain:

AdvA ≤

∣∣^1

· Pr

[

(P K, SK) ← KeyGen(1k) : AEP K,^1 (·,·),EP K,^1 (·,·)(P K) = 1

]

· Pr

[

(P K, SK) ← KeyGen(1k^ ) : AEP K,^1 (·,·),EP K,^0 (·,·)(P K) = 0

]

· Pr

[

(P K, SK) ← KeyGen(1k) : AEP K,^1 (·,·),EP K,^0 (·,·)(P K) = 1

]

· Pr

[

(P K, SK) ← KeyGen(1k^ ) : AEP K,^0 (·,·),EP K,^0 (·,·)(P K) = 0

]

= Adv (^) Aˆ 2 + Adv (^) Aˆ 1.

Since (by our initial assumption) AdvA was non negligible, the above implies that at least one of Adv (^) Aˆ 1 or Adv (^) Aˆ 2 must be non negligible. However, this would imply that at least

one of Aˆ 1 or Aˆ 2 violate the semantic security of the encryption scheme, contradicting the assumption of the theorem.

2.1 The Hybrid Argument

We can generalize the proof technique used above so that it applies to any indistinguishable distributions (the technique is referred to as the “hybrid argument”). We formalize this idea now by first defining computational indistinguishability.

Definition 2 Let X = {Xk} and Y = {Yk} be ensembles of distributions, where for all k, Xk and Yk are distributions over the same space. X and Y are computationally

indistinguishable (written X

c ≡ Y) if the following is negligible (in k) for all ppt A:

|Pr [x ← Xk; A(x) = 1] − Pr [y ← Yk; A(y) = 1]|. (4)

♦

We will sometimes be informal and refer to “distributions” instead of “ensembles of distri- butions”.

As an example of how this notation may be used, we give an equivalent definition of semantic security (for a single bit) in terms of computational indistinguishability. Namely, let Xk^ def = {(P K, SK) ← KeyGen(1k); C ← EP K (0) : (P K, C)}

and Yk^ def = {(P K, SK) ← KeyGen(1k); C ← EP K (1) : (P K, C)}.

Then encryption scheme (KeyGen, E, D) is semantically-secure (for encryption of a single

bit) if and only if {Xk}

c ≡ {Yk}. Before continuing with our discussion of the “hybrid argument”, we note the following useful properties of computational indistinguishability:

Claim 3 If X

c ≡ Y and Y

c ≡ Z then X

c ≡ Z.

Sketch of Proof (Informal) The proof relies on the triangle inequality (namely, the fact that for any real numbers a, b, c we have |a − b| ≤ |a − b| + |b − c|) and the fact that the sum of two negligible functions is negligible.

In fact, we can extend this claim as follows:

Claim 4 (Transitivity) Given polynomially many distributions X 1 ,... , X`(k) for which

Xi

c ≡ Xi+1 for i = 1,... , `(k) − 1 , then X 1

c ≡ X`(k)

Sketch of Proof (Informal) The proof again uses the triangle inequality along with the fact that the sum of a polynomial number of negligible functions remains negligible.

Note that the claim does not hold for a super-polynomial number of distributions. We now formalize the hybrid argument.

Claim 5 (Hybrid argument) Let X 1 , X 2 , Y^1 , Y^2 be efficiently sampleable^3 distributions

for which X 1

c ≡ Y^1 and X 2

c ≡ Y^2. Then (X 1 , X 2 )

c ≡ (Y^1 , Y^2 ). (Note: if X = {Xk} and Y = {Yk} are two distribution ensembles, the notation (X , Y) refers to the distribution ensemble {(Xk , Yk)} where the distribution (Xk, Yk) is defined by {x ← Xk; y ← Yk : (x, y)}.)

Proof Instead of proving this by contradiction, we prove it directly. Let A be an arbi- trary ppt algorithm trying to distinguish (X 1 , X 2 ) and (Y^1 , Y^2 ). We may construct a ppt adversary A 1 trying to distinguish X 1 and Y^1 as follows:

A 1 (1k^ , z) Choose random x ← X k^2 output A(z, x)

Clearly, A 1 runs in polynomial time (here is where we use the fact that all our distributions

are efficiently sampleable). Since X 1

c ≡ Y^1 we therefore know that the following must be (^3) A distribution ensemble X = {Xk } is efficiently-sampleable if we can generate an element according to

distribution Xk in time polynomial in k.

Strictly speaking, Claim 5 is not quite enough to yield Theorem 2 directly. The problem is the following: recall that if (KeyGen, E, D) is a semantically-secure encryption scheme for a single bit then the following ensembles are computationally indistinguishable:

Xk def = {(P K, SK) ← KeyGen(1k^ ); C ← EP K (0) : (P K, C)} Yk^ def = {(P K, SK) ← KeyGen(1k); C ← EP K (1) : (P K, C)}.

But then applying the hybrid argument directly only tells us that the following are indis- tinguishable:

(Xk, Xk ) =

(P K, SK), (P K′, SK′) ← KeyGen(1k^ ) C ← EP K (0); C′^ ← EP K′ (0) :^ (P K, C, P K

′, C′)

(Yk, Yk) =

(P K, SK), (P K′, SK′) ← KeyGen(1k^ ) C ← EP K (1); C′^ ← EP K′^ (1)

: (P K, C, P K′, C′)

here, encryption is done with respect to two different public keys, not a single key as desired. Even so, the hybrid technique is essentially what is used to prove Theorem 2 and we therefore refer to it as such. As a final remark, note that it is crucial in the proof of Theorem 2 that an adversary can generate random encryptions^4 as can be done in any public-key encryption scheme. In particular, an analogue of Theorem 2 does not hold for the case of private-key encryption, where an adversary may be unable to generate legal ciphertexts corresponding to an unknown key.

(^4) In fact, this directly parallels the requirement in Claim 5 that the distribution ensembles be efficiently

sampleable.