MIT 6.875 & Berkeley CS276 Foundations of Cryptography Lecture - - PowerPoint PPT Presentation
MIT 6.875 & Berkeley CS276 Foundations of Cryptography Lecture - - PowerPoint PPT Presentation
MIT 6.875 & Berkeley CS276 Foundations of Cryptography Lecture 16 Today: Non-Interactive Zero-Knowledge (NIZK) In Two Days: An Application of NIZK NP Proofs For the NP-complete problem of graph 3-coloring Proof = Verifier V checks:
Today: Non-Interactive Zero-Knowledge (NIZK) In Two Days: An Application of NIZK
NP Proofs
Proof = For the NP-complete problem of graph 3-coloring Prover P has a witness, the 3-coloring of G Verifier V checks: (a) only 3 colors are used & (b) any two vertices connected by an edge are colored differently.
Zero-Knowledge (Interactive) Proof
Commitments ๐ โ ๐น Because NP proofs reveal too much
Zero-Knowledge (Interactive) Proof
Because NP proofs reveal too much
- 1. Completeness: For every ๐ป โ 3COL, V accepts Pโs proof.
- 2. Soundness: For every ๐ป โ 3COL and any cheating ๐โ, V
rejects ๐โโs proof with probability โฅ 1 โ neg(๐)
- 3. Zero Knowledge: For every cheating ๐โ, there is a PPT simulator
S such that for every G โ 3COL, S simulates the view of ๐โ.
TODAY: Can we make proofs non-interactive again?
Why? 1. V does not need to be online during the proof process. 2. Proofs are not ephemeral, can stay into the future.
TODAY: Can we make proofs non-interactive again?
NO!
YES, WE CAN!
Non-Interactive ZK is Impossible ๐
Suppose there were an NIZK proof system for 3COL.
Graph G Graph G
Step 1. When G is in 3COL, V accepts the proof ๐. (Completeness)
Non-Interactive ZK is Impossible
! ๐
Suppose there were an NIZK proof system for 3COL.
Graph G Graph G
Step 2. PPT Simulator S, given only G in 3COL, produces an indistinguishable proof " ๐ (Zero Knowledge). In particular, V accepts # ๐.
Non-Interactive ZK is Impossible " ๐
Suppose there were an NIZK proof system for 3COL.
Graph G Graph G
Step 3. Imagine running the Simulator S on a ๐ป โ 3COL. It produces a proof " ๐ which the verifier still accepts! (WHY?! Because S and V are PPT. They together cannot tell if the input graph is 3COL or not)
Non-Interactive ZK is Impossible ๐
Suppose there were an NIZK proof system for 3COL.
Graph G Graph G
Step 4. Therefore, S is a cheating prover! Produces a proof for a ๐ป โ 3COL that the verifier nevertheless accepts. Ergo, the proof system is NOT SOUND!
THE END Or, is it?
Enter: The Common Random String ๐
Graph G Graph G
010111000101010010 CRS
Enter: The Common Reference String ๐
Graph G Graph G
๐ท๐๐ โ ๐ธ
(e.g., CRS = product of two primes)
NIZK in the CRS Model ๐
Graph G Graph G
010111000101010010 CRS
- 1. Completeness: For every ๐ป โ 3COL, V accepts Pโs proof.
- 2. Soundness: For every ๐ป โ 3COL and any โproofโ ๐โ,
๐(๐ท๐๐, ๐โ) accepts with probability โค neg(๐)
NIZK in the CRS Model ๐
Graph G Graph G
010111000101010010 CRS
- 3. Zero Knowledge: There is a PPT simulator S such that for
every G โ 3COL, S simulates the view of the verifier V. ๐(๐ป) โ (๐ท๐๐ โ ๐ธ, ๐ โ ๐(๐ป, ๐๐๐๐๐ ๐ก))
NIZK in the CRS Model ๐
Graph G Graph G
010111000101010010 CRS
- 3. Zero Knowledge: There is a PPT simulator S such that for every
๐ฆ โ L and witness ๐ฅ, S simulates the view of the verifier V. ๐(๐ฆ) โ (๐ท๐๐ โ ๐ธ, ๐ โ ๐(๐ฆ, ๐ฅ))
HOW TO CONSTRUCT NIZK IN THE CRS MODEL
- 1. Blum-Feldman-Micaliโ88 (quadratic residuosity)
- 2. Feige-Lapidot-Shamirโ90 (factoring)
- 3. Groth-Ostrovsky-Sahaiโ06 (bilinear maps)
- 4. Canetti-Chen-Holmgren-Lombardi-Rothblum!-Wichsโ19
and Peikert-Shiehianโ19 (learning with errors)
- 1. Blum-Feldman-Micaliโ88 (quadratic residuosity)
HOW TO CONSTRUCT NIZK IN THE CRS MODEL
Step 1. Review our number theory hammers & polish them. Step 2. Construct NIZK for a special NP language, namely quadratic non-residuosity. Step 3. Bootstrap to NIZK for 3SAT, an NP-complete language.
Quadratic Residuosity
Let ๐ = ๐๐ be a product of two large primes. ๐พ๐๐"# ๐พ๐๐$# ๐%
โ
{๐ฆ: ๐ฆ ๐ = โ1} {๐ฆ: ๐ฆ ๐ = +1}
Quadratic Residuosity
Let ๐ = ๐๐ be a product of two large primes. ๐พ๐๐"# ๐พ๐๐$# ๐%
โ
{๐ฆ: ๐ฆ ๐ = โ1} {๐ฆ: ๐ฆ ๐ = +1}
๐ฒ๐๐ divides ๐๐ถ
โ evenly unless N is a perfect square.
Quadratic Residuosity
Let ๐ = ๐๐ be a product of two large primes. ๐พ๐๐"# ๐พ๐๐$# ๐%
โ
{๐ฆ: ๐ฆ ๐ = โ1} {๐ฆ: ๐ฆ ๐ = +1}
Surprising fact: Jacobi symbol (
% = ( ) ( * is
computable in poly time without knowing ๐ and ๐.
Quadratic Residuosity
Let ๐ = ๐๐ be a product of two large primes. ๐พ๐๐$# ๐ ๐% is the set of squares mod ๐ and ๐ ๐๐% is the set
- f non-squares mod ๐ with Jacobi symbol +1.
๐ ๐% ๐ ๐๐%
So: ๐ ๐! = {๐ฆ:
" # = " $ = +1}
๐ ๐๐! = {๐ฆ:
" # = " $ = โ1}
Quadratic Residuosity
๐พ๐๐$# ๐ ๐% is the set of squares mod ๐ and ๐ ๐๐% is the set
- f non-squares mod ๐ with Jacobi symbol +1.
๐ ๐% ๐ ๐๐% Exactly half residues even if ๐ถ = ๐๐๐๐, ๐, ๐ โฅ ๐, ๐จ๐ฉ๐ฎ ๐๐ฉ๐ฎ๐ข ๐๐ฐ๐๐จ.
Quadratic Residuosity
๐พ๐๐$# IMPORTANT PROPERTY: If ๐ง# and ๐ง! are both in ๐ ๐ถ๐, then their product ๐ง#๐ง! is in ๐ ๐. ๐ ๐% ๐ ๐๐% Exactly half residues even if ๐ = ๐8๐9, ๐, ๐ โฅ 1, not both even.
Quadratic Residuosity
๐พ๐๐$# ๐ ๐% ๐ ๐๐% The fraction of residues smaller if ๐ถ has three or more prime factors! IMPORTANT PROPERTY: If ๐ง# and ๐ง! are both in ๐ ๐ถ๐, then their product ๐ง#๐ง! is in ๐ ๐.
Quadratic Residuosity
Let ๐ = ๐๐ be a product of two large primes. Quadratic Residuosity Assumption (QRA) No PPT algorithm can distinguish between a random element of ๐ ๐% from a random element of ๐ ๐๐% given only ๐.
HOW TO CONSTRUCT NIZK IN THE CRS MODEL
Step 1. Review our number theory hammers & polish them. Step 2. Construct NIZK for a special NP language, namely quadratic non-residuosity. Step 3. Bootstrap to NIZK for 3SAT, an NP-complete language.
NIZK for Quadratic Non-Residuosity
Define the NP language ๐ป๐๐๐ธ with instances (๐ถ, ๐) where
- ๐ is good: has exactly two prime factors and is not a
perfect square; and
- ๐ง โ ๐ ๐๐% (that is, ๐ง has Jacobi symbol +1
but is not a square mod ๐) ๐พ๐๐"# ๐พ๐๐$# ๐%
โ
๐ ๐% ๐ ๐๐%
NIZK for Quadratic Non-Residuosity
๐ท๐๐ = (๐
#, ๐ !, โฆ , ๐ :) โ (๐พ๐๐% $#):
(๐, ๐ง) (๐, ๐ง) If ๐ถ is good and ๐ โ ๐น๐ถ๐บ๐ถ: either ๐๐ is in ๐น๐บ๐ถ or ๐๐๐ is in ๐น๐บ๐ถ so I can compute ๐๐ or ๐๐๐. If not โฆ Iโll be stuck!
NIZK for Quadratic Non-Residuosity
๐ท๐๐ = (๐
#, ๐ !, โฆ , ๐ :) โ (๐พ๐๐% $#):
(๐, ๐ง) (๐, ๐ง) โ๐: ๐
8 OR ๐ง๐ "
Check:
- ๐ is not a prime power,
- ๐ is not a perfect square; and
- I received either a mod-N
square root of ๐
8 or ๐ง๐ 8
NIZK for Quadratic Non-Residuosity
๐ท๐๐ = (๐
#, ๐ !, โฆ , ๐ :) โ (๐พ๐๐% $#):
(๐, ๐ง) (๐, ๐ง) โ๐: ๐
8 OR ๐ง๐ "
Soundness (what if ๐ has more than 2 prime factors) No matter what ๐ง is, for half the ๐
8, both ๐ 8 and ๐ง๐ 8 are
not quadratic residues.
NIZK for Quadratic Non-Residuosity
๐ท๐๐ = (๐
#, ๐ !, โฆ , ๐ :) โ (๐พ๐๐% $#):
(๐, ๐ง) (๐, ๐ง) โ๐: ๐
8 OR ๐ง๐ "
Soundness (what if ๐ has more than 2 prime factors) No matter what ๐ง is, for half the ๐
8, both ๐ 8 and ๐ง๐ 8 are
not quadratic residues.
NIZK for Quadratic Non-Residuosity
๐ท๐๐ = (๐
#, ๐ !, โฆ , ๐ :) โ (๐พ๐๐% $#):
(๐, ๐ง) (๐, ๐ง) โ๐: ๐
8 OR ๐ง๐ "
Soundness (what if ๐ง is a residue) Then, if ๐
8 happens to be a non-residue, both ๐ 8 and ๐ง๐ 8
are not quadratic residues.
NIZK for Quadratic Non-Residuosity
๐ท๐๐ = (๐
#, ๐ !, โฆ , ๐ :) โ (๐พ๐๐% $#):
(๐, ๐ง) (๐, ๐ง) โ๐: ๐8 = ๐
8 OR ๐ง๐ "
(Perfect) Zero Knowledge Simulator S: First pick the proof ๐8 to be random in ๐%
โ .
Then, reverse-engineer the CRS, letting ๐
8 = ๐8 ! or ๐ 8 =
๐8
!/๐ง randomly.
NIZK for Quadratic Non-Residuosity
๐ท๐๐ = (๐
#, ๐ !, โฆ , ๐ :) โ (๐พ๐๐% $#):
(๐, ๐ง) (๐, ๐ง) CRS depends on the instance N. Not good. Soln: Let CRS be random numbers. Interpret them as elements of ๐%
โ and both
the prover and verifier filter out ๐พ๐๐%
"#.
NEXT LECTURE
Step 1. Review our number theory hammers & polish them. Step 2. Construct NIZK for a special NP language, namely quadratic non-residuosity. Step 3. Bootstrap to NIZK for 3SAT, an NP-complete language.