CPSC 467: Cryptography and Computer Security

Similar documents
CPSC 467: Cryptography and Computer Security

CPSC 467b: Cryptography and Computer Security

CPSC 467b: Cryptography and Computer Security

Lecture Notes, Week 10

CPSC 467: Cryptography and Computer Security

Lecture 10: Zero-Knowledge Proofs

CPSC 467: Cryptography and Computer Security

Lecture 10. Public Key Cryptography: Encryption + Signatures. Identification

CPSC 467: Cryptography and Computer Security

YALE UNIVERSITY DEPARTMENT OF COMPUTER SCIENCE

Lecture 1: Introduction to Public key cryptography

Lecture 15 - Zero Knowledge Proofs

Winter 2011 Josh Benaloh Brian LaMacchia

Lecture Notes, Week 6

CPSC 467b: Cryptography and Computer Security

Notes on Zero Knowledge

CPSC 467b: Cryptography and Computer Security

1 Recap: Interactive Proofs

Cryptography CS 555. Topic 23: Zero-Knowledge Proof and Cryptographic Commitment. CS555 Topic 23 1

Zero-Knowledge Proofs and Protocols

COS433/Math 473: Cryptography. Mark Zhandry Princeton University Spring 2018

Introduction to Modern Cryptography. Benny Chor

CPSC 467b: Cryptography and Computer Security

Privacy and Computer Science (ECI 2015) Day 4 - Zero Knowledge Proofs Mathematics

CPSC 467b: Cryptography and Computer Security

CPSC 467b: Cryptography and Computer Security

Introduction to Cryptography Lecture 13

CPSC 467: Cryptography and Computer Security

Lecture 3,4: Multiparty Computation

Notes for Lecture 25

Lecture Notes 20: Zero-Knowledge Proofs

CPSC 467: Cryptography and Computer Security

Introduction to Cryptography. Lecture 8

Lecture 15: Interactive Proofs

Theory of Computation Chapter 12: Cryptography

Lecture th January 2009 Fall 2008 Scribes: D. Widder, E. Widder Today s lecture topics

Lecture 18 - Secret Sharing, Visual Cryptography, Distributed Signatures

III. Authentication - identification protocols

Lecture 22. We first consider some constructions of standard commitment schemes. 2.1 Constructions Based on One-Way (Trapdoor) Permutations

Cryptographical Security in the Quantum Random Oracle Model

The Laws of Cryptography Zero-Knowledge Protocols

CPSC 467: Cryptography and Computer Security

Cryptography and Security Final Exam

CPSC 467: Cryptography and Computer Security

Cryptographic Protocols Notes 2

Lecture 11: Hash Functions, Merkle-Damgaard, Random Oracle

14 Diffie-Hellman Key Agreement

Lecture 18: Zero-Knowledge Proofs

Introduction to Modern Cryptography. Benny Chor

1 Recommended Reading 1. 2 Public Key/Private Key Cryptography Overview RSA Algorithm... 2

Interactive protocols & zero-knowledge

1 What are Physical Attacks. 2 Physical Attacks on RSA. Today:

Interactive proof and zero knowledge protocols

Lecture 10 - MAC s continued, hash & MAC

Lecture Notes 17. Randomness: The verifier can toss coins and is allowed to err with some (small) probability if it is unlucky in its coin tosses.

Question 1. The Chinese University of Hong Kong, Spring 2018

Lecture 9 Julie Staub Avi Dalal Abheek Anand Gelareh Taban. 1 Introduction. 2 Background. CMSC 858K Advanced Topics in Cryptography February 24, 2004

Public-Key Cryptosystems CHAPTER 4

CS151 Complexity Theory. Lecture 13 May 15, 2017

Cryptographic Protocols. Steve Lai

Introduction to Modern Cryptography Lecture 11

Notes on Complexity Theory Last updated: November, Lecture 10

Lecture 1: Perfect Secrecy and Statistical Authentication. 2 Introduction - Historical vs Modern Cryptography

Introduction to Modern Cryptography. Benny Chor

Secret Sharing Schemes

1 Secure two-party computation

6.080/6.089 GITCS Apr 15, Lecture 17

March 19: Zero-Knowledge (cont.) and Signatures

CS 282A/MATH 209A: Foundations of Cryptography Prof. Rafail Ostrovsky. Lecture 9

U.C. Berkeley CS276: Cryptography Luca Trevisan February 5, Notes for Lecture 6

CPSC 467: Cryptography and Computer Security

Session 4: Efficient Zero Knowledge. Yehuda Lindell Bar-Ilan University

CPSC 467b: Cryptography and Computer Security

Public Key Cryptography

RSA RSA public key cryptosystem

Zero-Knowledge Against Quantum Attacks

Lecture 5. 1 Review (Pairwise Independence and Derandomization)

CS 282A/MATH 209A: Foundations of Cryptography Prof. Rafail Ostrovsky. Lecture 10

ASYMMETRIC ENCRYPTION

SIGNATURE SCHEMES & CRYPTOGRAPHIC HASH FUNCTIONS. CIS 400/628 Spring 2005 Introduction to Cryptography

YALE UNIVERSITY DEPARTMENT OF COMPUTER SCIENCE

Simple Math: Cryptography

Lecture 3: Interactive Proofs and Zero-Knowledge

Interactive protocols & zero-knowledge

Lecture 15 & 16: Trapdoor Permutations, RSA, Signatures

Crypto math II. Alin Tomescu May 27, Abstract A quick overview on group theory from Ron Rivest s course in Spring 2015.

Authentication. Chapter Message Authentication

Cryptography and RSA. Group (1854, Cayley) Upcoming Interview? Outline. Commutative or Abelian Groups

Lecture 26: Arthur-Merlin Games

Cryptography and Network Security Prof. D. Mukhopadhyay Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur

Entity Authentication

Topics in Complexity

Notes for Lecture 17

CHALMERS GÖTEBORGS UNIVERSITET. TDA352 (Chalmers) - DIT250 (GU) 11 April 2017, 8:30-12:30

Lecture 14: Secure Multiparty Computation

Cryptography and Security Final Exam

Solutions for week 1, Cryptography Course - TDA 352/DIT 250

Quantum Cryptography

Round-Efficient Multi-party Computation with a Dishonest Majority

Tutorial on Quantum Computing. Vwani P. Roychowdhury. Lecture 1: Introduction

Transcription:

CPSC 467: Cryptography and Computer Security Michael J. Fischer Lecture 19 November 8, 2017 CPSC 467, Lecture 19 1/37

Zero Knowledge Interactive Proofs (ZKIP) ZKIP for graph isomorphism Feige-Fiat-Shamir Authentication Protocol Abstraction from two ZKIP examples Information Splitting Public Key Infrastructure (PKI) and Trust CPSC 467, Lecture 19 2/37

Zero Knowledge Interactive Proofs (ZKIP) CPSC 467, Lecture 19 3/37

Zero knowledge interactive proofs (continued) Last time we saw two examples of zero knowledge interactive proofs: Simplified Feige-Fiat-Shamir authentication protocol. Secret cave protocol. We now look at ZKIP s in greater detail. CPSC 467, Lecture 19 4/37

Isomorphism Graph isomorphism problem Two undirected graphs G and H are said to be isomorphic if there exists a bijection π from vertices of G to vertices of H that preserves edges. That is, {x, y} is an edge of G iff {π(x), π(y)} is an edge of H. The graph isomorphism problem is, given graphs G and H, to determine whether or not G and H are isomorphic. CPSC 467, Lecture 19 5/37

Isomorphism Graph Isomorphism Graph G Graph H Isomorphism π π(a) = 1 π(b) = 6 π(c) = 8 π(d) = 3 π(g) = 5 π(h) = 2 π(i) = 4 π(j) = 7 From Wikipedia, https://en.wikipedia.org/wiki/graph isomorphism CPSC 467, Lecture 19 6/37

Isomorphism Complexity of graph isomorphism No polynomial time algorithm for solving graph isomorphism is known, but this problem is also not known to be NP-hard. It follows that there is no known polynomial time algorithm for finding the isomorphism π given two isomorphic graphs G and H. Why? László Babai claims that graph isomorphism is in quasipolynomial time, that is, time of the form 2 O(log(n)c ) for some constant c. This is a huge improvement over the best prior result. (See László Babai Graph Isomorphism.) CPSC 467, Lecture 19 7/37

Isomorphism A zero-knowledge proof for isomorphism Suppose G 0 and G 1 are public graphs, and Alice knows an isomorphism π : G 0 G 1. Using a zero-knowledge proof, Alice can prove to Bob that she knows π without revealing any information about π. In particular, she convinces Bob that the graphs really are isomorphic. However, the proof is non-transferrable, so Bob cannot turn around and convince Carol of that fact. CPSC 467, Lecture 19 8/37

Isomorphism Interactive proof of graph isomorphism Alice 1. Simultaneously choose a random isomorphic copy H of G 0 and an isomorphism τ : G 0 H. 2. 3. If b = 0, let σ = τ. If b = 1, let σ = τ π 1. H Bob b Choose random b {0, 1}. σ Check σ(g b ) = H. CPSC 467, Lecture 19 9/37

Isomorphism Validity of isomorphism IP The protocol is similar to the simplified Feige-Fiat-Shamir protocol If both Alice and Bob follow this protocol, Bob s check always succeeds. When b = 0, Alice send τ in step 3, and Bob checks that τ is an isomorphism from G 0 to H. When b = 1, the function σ that Alice computes is an isomorphism from G 1 to H. This is because π 1 is an isomorphism from G 1 to G 0 and τ is an isomorphism from G 0 to H. Composing them gives an isomorphism from G 1 to H, so again Bob s check succeeds. CPSC 467, Lecture 19 10/37

Isomorphism Isomorphism IP is zero knowlege The protocol is zero knowledge (at least informally) because all Bob learns is a random isomorphic copy H of either G 0 or G 1 and the corresponding isomorphism. This is information that he could have obtained by himself without Alice s help. What convinces him that Alice really knows π is that in order to repeatedly pass his checks, the graph H of step 1 must be isomorphic to both G 0 and G 1. Moreover, Alice knows isomorphisms σ 0 : G 0 H and σ 1 : G 1 H since she can produce them upon demand. Hence, she also knows an isomorphism π from G 0 to G 1, since σ 1 1 σ 0 is such a function. CPSC 467, Lecture 19 11/37

Feige-Fiat-Shamir Reprise: A simplified one-round FFS protocol Recall: n = pq, where p and q are distinct large primes. v QR n. s is the smallest square root of v 1 (mod n). n and v are public. s is Alice s secret. FFS protocol: Alice 1. Choose random r Z n. Compute x = r 2 mod n. 2. 3. Compute y = rs b mod n. x b Bob Choose random b {0, 1}. y Check x = y 2 v b mod n. CPSC 467, Lecture 19 12/37

Feige-Fiat-Shamir Properties of FFS protocol We make three claims for the FFS protocol. 1. [Completeness] When both Alice and Bob are honest, Bob s check always succeeds. 2. [Soundness] If Mallory attempts to impersonate Alice without knowing her secret s, Bob s check will fail with probability at least 1/2. 3. [Zero knowledge] Anything that Mallory can compute while interacting with Alice in the FFS protocol could also be computed without Alice s involvement. In particular, if Mallory can find Alice s secret s after running the FFS protocol, then he could have found s without ever talking to Alice. CPSC 467, Lecture 19 13/37

Feige-Fiat-Shamir Completeness We claimed last time that when both parties are honest, Bob s check x = y 2 v b mod n. succeeds because y 2 v b (rs b ) 2 v b r 2 (s 2 v) b x(v 1 v) b x (mod n). In a little more detail, we consider the two cases separately: b = 0: Then y = r and y 2 r 2 x (mod n). b = 1: Then y rs (mod n) and s 2 v 1 (mod n), so y 2 v r 2 s 2 v r 2 v 1 v r 2 x (mod n). CPSC 467, Lecture 19 14/37

Feige-Fiat-Shamir Soundness Theorem Suppose Mallory doesn t know a square root of v 1. Then Bob s verification will fail with probability at least 1/2. Proof. To successfully fool Bob, Mallory must come up with x in step 1 and y in step 3 satisfying x = y 2 v b mod n. Mallory sends x in step 1 before Bob chooses b, so she does not know which value of b to expect. When Mallory receives b, she responds by sending a value y b to Bob. We consider two cases. (continued... ) CPSC 467, Lecture 19 15/37

Feige-Fiat-Shamir Proof: case 1 Proof (continued). Case 1: There is at least one b {0, 1} for which y b fails to satisfy x = y 2 v b mod n. Since b = 0 and b = 1 each occur with probability 1/2, this means that Bob s verification will fail with probability at least 1/2, as desired. (continued... ) CPSC 467, Lecture 19 16/37

Feige-Fiat-Shamir Proof: case 2 Proof (continued). Case 2: y 0 and y 1 both satisfy the verification equation, so x = y0 2 mod n and x = y 1 2 v mod n. We can solve these equations for v 1 to get v 1 y 2 1 x 1 y 2 1 y 2 0 (mod n) But then y 1 y 1 0 mod n is a square root of v 1. Since Mallory was able to compute both y 1 and y 0, then she was also able to compute a square root of v 1, contradicting the assumption that she doesn t know a square root of v 1. CPSC 467, Lecture 19 17/37

Feige-Fiat-Shamir Successful cheating with probability 1/2 We remark that it is possible for Mallory to cheat with success probability 1/2. She guesses the bit b that Bob will send her in step 2 and generates a pair (x, y). If she guesses b = 0, then she chooses x = r 2 mod n and y = r mod n, just as Alice would have done. If she guesses b = 1, then she chooses y arbitrarily and x = y 2 v mod n. She proceeds to send x in step 1 and y in step 3. The pair (x, y) is accepted by Bob if Mallory s guess of b turns out to be correct, which will happen with probability 1/2. CPSC 467, Lecture 19 18/37

Feige-Fiat-Shamir Zero knowledge We now consider the case of an honest Alice interacting with a dishonest Mallory pretending to be Bob, or simply a dishonest Bob who wants to capture Alice s secret. Alice would like assurance that her secret is protected if she follows the protocol, regardless of what Mallory (or Bob) does. Consider what Mallory knows at the end of the protocol. CPSC 467, Lecture 19 19/37

Feige-Fiat-Shamir Mallory sends b = 0 Suppose Mallory sends b = 0 in step 2. Then she ends up with a pair (x, y), where y is a random number and x is its square modulo n. Neither of these numbers depend in any way on Alice secret s, so Mallory gets no direct information about s. It s also of no conceivable use to Mallory in trying to find s by other means, for she can compute such pairs by herself without involving Alice. If having such pairs would allow her find a square root of v 1, then she was already able to compute square roots, contrary to the assumption that finding square roots modulo n is difficult. CPSC 467, Lecture 19 20/37

Feige-Fiat-Shamir Mallory sends b = 1 Suppose Mallory sends b = 1 in step 2. Now she ends up with the pair (x, y), where x = r 2 mod n and y = rs mod n. While y might seem to give information about s, observe that y itself is just a random element of Z n. This is because r is random, and the mapping r rs mod n is one-to-one for all s Z n. Hence, as r ranges through all possible values, so does y = rs mod n. Mallory learns nothing from x that she could not have computed herself knowing y, for x = y 2 v mod n. Again, all she ends up with is a random number (y in this case) and a quadratic residue x that she can compute knowing y. CPSC 467, Lecture 19 21/37

Feige-Fiat-Shamir Mallory learns nothing from (x, y) In both cases, Mallory ends up with information that she could have computed without interacting with Alice. Hence, if she could have discovered Alice s secret by talking to Alice, then she could have also done so on her own, contradicting the hardness assumption for computing square roots. This is the sense in which Alice s protocol releases zero knowledge about her secret. CPSC 467, Lecture 19 22/37

Abstraction FFS authentication and isomorphism IP We have seen two examples of zero knowledge interactive proofs of knowledge of a secret. In the simplified Feige-Fiat-Shamir authentication scheme, Alice s secret is a square root of v 1. In the graph isomorphism protocol, her secret is the isomorphism π. In both cases, the protocol has the form that Alice sends Bob a commitment string x, Bob sends a query bit b, and Alice replies with a response y b. Bob then checks the triple (x, b, y b ) for validity. CPSC 467, Lecture 19 23/37

Abstraction FFS/Isomorphism comparison (continued) In both protocols, neither triple (x, 0, y 0 ) nor (x, 1, y 1 ) alone give any information about Alice s secret, but y 0 and y 1 can be combined to reveal her secret. In the FFS protocol, y 1 y 1 0 mod n is a square root of v 1. (Note: Since v 1 has four square roots, the revealed square root might not be the same as Alice s secret, but it is equally valid as a means of impersonating Alice.) In the graph isomorphism protocol, y 1 1 y 0 is an isomorphism mapping G 0 to G 1. CPSC 467, Lecture 19 24/37

Abstraction Other materials on zero knowledge Here are some links to other interesting materials on zero knowledge. How to explain zero-knowledge protocols to your children gives a different version of the Secret Cave protocol along with other stories illustrating other aspects of zero knowledge, such as non-transferrability of proof. Using a zero-knowledge protocol to prove you can solve a sudoku is a video of a Skype session in which Katie Steckles proves her sudoku-solving ability to Christian Perfect. Cryptographic and Physical Zero-Knowledge Proof Systems for Solutions of Sudoku Puzzles is the paper describing the sudoku solution protocol upon which the video above is based. CPSC 467, Lecture 19 25/37

Information Splitting CPSC 467, Lecture 19 26/37

Another viewpoint One way to view these protocols is that Alice splits her secret into two parts, y 0 and y 1. By randomization, Alice is able to convince Bob that she really has (or could produce on demand) both parts, but in doing so, she is only forced to reveal one of them. Each part by itself is statistically independent of the secret and hence gives Bob no information about the secret. Together, they can be used to recover the secret. CPSC 467, Lecture 19 27/37

Secret splitting This is an example of secret splitting or secret sharing, an important topic in its own right. We have already seen other examples of secret sharing. In the one-time pad cryptosystem, the message m is split into two parts: the key k are the ciphertext c = m k. Bob, knowing both k and c, recovers m from by computing c k. Assuming k is picked randomly, then both k and c are uniformly distributed random bit strings, which is why Eve learns nothing about m from k or c alone. What s different with zero knowledge proofs is that Bob has a way to check the validity of the parts that he gets during the protocol. CPSC 467, Lecture 19 28/37

The Big Picture Much of cryptography is concerned with splitting a piece of information s into a collection of shares s 1,..., s r. Certain subsets of shares allow s to be easily recovered; other subsets are insufficient to allow any useful information about s to be easily obtained. In the simplest form, s is split into two shares a and b. Neither share alone gives useful information about s, but together they reveal s. CPSC 467, Lecture 19 29/37

Examples of information splitting One-time pad: s is broken into a key k and a ciphertext c, where k = c and s = k c. AES: s is broken into a short key k and a long ciphertext c, where s = D k (c). Secret splitting: s is broken into equal-length shares s 1 and s 2, where s = s 1 s 2. CPSC 467, Lecture 19 30/37

Public Key Infrastructure (PKI) and Trust CPSC 467, Lecture 19 31/37

Share distribution A key problem (pun intended) in any use of cryptography is how the various parties to a protocol obtain their respective shares. For conventional symmetric cryptography, this is known as the key distribution problem. For public key systems, the public shares are provided through a public key infrastructure (PKI). CPSC 467, Lecture 19 32/37

Desired properties of a PKI A PKI should allow any user to obtain the correct public key (and perhaps other information) for a user. The information provided must be correct. The user must trust that it is correct. CPSC 467, Lecture 19 33/37

Centralized PKI The first idea for a PKI is a centralized database run by a trusted 3rd party, e.g., the government. Problems: Centralized systems are brittle. Difficult to find a single entity that is universally trusted. CPSC 467, Lecture 19 34/37

Hierarchy of trust The most widely used PKI today is based on X.509 certificates and the hierarchy of trust. A certificate is a package of information that binds a user to a public key. To be trusted, a certificate must be signed by a trusted certificate authority (CA). To validate the signature, one must obtain and validate a trusted certificate of the signing CA. CPSC 467, Lecture 19 35/37

Where does trust stop? The roots of the PKI hierarchy are trusted CA s that are well-known. Your browser is distributed with trusted certificates for the root CA s. Any other certificate can be valided by obtaining a chain of trust leading to a root certificate. For this scheme to work, one relies on the CA s to take reasonable care not to issue bogus certificates. Recent revelations show that not all root CA s are trustworthy. Even a single bad root CA can break the entire system. CPSC 467, Lecture 19 36/37

Web of trust A variant PKI is the web of trust. Here, the trust relationship is a graph, not a tree. The basic rule is to trust a certificate if it is signed by one or more trusted parties. Anyone can act as a CA, so one must only trust the signatures of trustworthy signers. CPSC 467, Lecture 19 37/37