MPC-based zero-knowledge proof protocol

references:

  1. Jawurek , M. , F. Kerschbaum , and C. Orlandi . 2013. “Zero-knowledge using garbled circuits: how to prove non-algebraic statements efficiently”. In: ACM CCS 13: 20th Conference on Computer and Communications Security . Ed. by A.-R. Sadeghi, VD Gligor, and M. Yung. ACM Press. 955–966.
  2. Evans D, Kolesnikov V, Rosulek M. A pragmatic introduction to secure multi-party computation[J]. Foundations and Trends® in Privacy and Security, 2018, 2(2-3): 70-246.
  3. Applied Cryptography: Protocols, Algorithms, and C Source Programs (Daheipi of Jigongshe)

CPC

The basic definition of the zero-knowledge proof protocol is in this article .

interactive

Recently I saw another expression describing ZKP:

  1. Verifier has a hard problem instance H 1 H_1H1, Prover declares that he owns H 1 H_1H1Solution S 1 S_1S1
  2. Prover use 1 11 random numberrrr , this puzzle instanceH 1 H_1H1, transforming into another isomorphic hard problem instance H 2 H_2H2. At the same time, according to S 1 S_1S1and rrr , get the corresponding solutionS 2 S_2S2
  3. Prover pair solution S 2 S_2S2Make a commitment, then assign the puzzle H 2 H_2H2and commitment value ccc are sent to Verifier
  4. Verifier randomly asks Prover to give Proof of one of the following two statements:
    1. Prover is required to prove that two puzzles are isomorphic, H 1 ≅ H 2 H_1 \cong H_2H1H2
    2. Ask Prover to disclose S 2 S_2S2, and prove that S 2 S_2S2is H 2 H_2H2the correct solution for
  5. Prover gives the required Proof, and Verifier verifies it
  6. Both execute nn repeatedlyn times step 1 ~ step 5, until Verifier believes that Prover does haveS 1 S_1S1(In general, n = 10 n=10n=10 is fine)

Completeness : Honest Prover has S 1 S_1S1, he can always give the two Proofs required in step 4, so Verifier will eventually believe him.

Reliability : A malicious Prover who doesn't have S 1 S_1S1, in order to pass the verification of step 4, he has to guess the choice of Verifier. If it is guessed that Verifier will execute step 4.1, then the adversary chooses a H 2 ≅ H 1 H_2 \cong H_1 in step 2H2H1, and he does not own the corresponding S 2 S_2S2. If it is guessed that Verifier will execute step 4.2, then the adversary randomly generates a difficult problem H 2 ′ H_2’ in step 2H2And the corresponding solution S 2 ′ S_2'S2, but at the same time he could not prove that H 1 ≅ H 2 ′ H_1 \cong H_2'H1H2

Zero-knowledge : A malicious Verifier cannot convince the third-party Alice of the validity of the above Proof. Assuming that the adversary uses a camera to record every step of the protocol, even if the video shows that Prover always gives the correct Proof, Alice can always question it: whenever Prover guesses correctly, Verifier keeps the video; whenever Prover guesses wrong , Verifier deletes the video. People cannot tell the difference between real records (in the real world) and fake records (in the ideal world)!

It has been proven that:

  1. Any NP proposition contains a ZKP
  2. Any mathematical proof can be transformed into a ZKP
  3. Anything that can be done with interactive proofs can also be done with interactive ZKPs

non-interactive

The reason why Alice does not believe it above is that she did not intervene in the interaction of the ZKP. In order for a Prover to convince anyone of his Proof, he needs a non-interactive ZKP . Whenever Prover releases Proof, anyone can verify whether the Proof is valid (identity authentication protocol, signature protocol).

Using the Hash function HHH replaces Verifier:

  1. Prover claims to own a hard problem instance HHH 's solutionSSS
  2. Prover utilizes nnn random numbers{ ri } \{r_i\}{ ri} , this puzzle instanceHHH , transformed into a randomnnn isomorphic problem instances{ H i } \{H_i\}{ Hi} . At the same time, according toSSS -sum{ ri } \{r_i\}{ ri} , get the corresponding solution{ S i } \{S_i\}{ Si}
  3. Prover pair solution { S i } \{S_i\}{ Si} make a commitment, then assign the hard problem{ H i } \{H_i\}{ Hi} and commitment value{ ci } \{c_i\}{ ci} are public
  4. Prover calculates b = H ( { ci } ) b = H(\{c_i\})b=H({ ci}) , intercept the frontnnn ratiob = b [ 1 : n ] b=b[1:n]b=b[1:n ] , then according tob [ i ] ∈ { 0 , 1 } b[i] \in \{0,1\}b[i]{ 0,1 } gives a Proof of one of the following two declarations:
    1. This b [ i ] = 0 b[i]=0b[i]=0 , Prover proves that the two problems are isomorphic,H ≅ H i H \cong H_iHHi
    2. This b [ i ] = 1 b[i]=1b[i]=1,Prover publicS i S_iSi, and prove that S i S_iSiIs H i H_iHithe correct solution for
  5. Prover announced the nn in step 4n Proofs, anyone can verify it: first according to{ ci } \{c_i\}{ ci} Calculatebbb , and then check theiiWhether the i Proof is aboutb [ i ] b[i]b [ i ] Legal proof of claim.

HH hereH playsan unbiased random bit generator. If the malicious Prover does not ownSSS , then he can only give at most one Proof in step 4, but not all Proofs at the same time, so in order to deceive, he must be able to predictHHoutput of H.

Of course, Prover (not Verifier) ​​picks the bbb , so the adversary can completely randomly guessbbex nnof bn bits, then try different{ S i } \{S_i\}{ Si} combination until all guessnnn bits. At this point, the adversary can give a legal Proof. In order to resist the adversary's exhaustive attack, we need to usennThe n setting is relatively large, such as64, 128 64,12864,128

JKO(2013)

ZKP can be used as a special malicious secure computation , according to the statement yyy constructs the circuitC ( ⋅ , y ) C(\cdot,y)C(,y) C ( x , y ) = 1    ⟺    ( x , y ) ∈ R C(x,y)=1 \iff (x,y) \in R C(x,y)=1(x,y)R ), where evidence xxis entered as a party to the Proverx , the Verifier side does not input anything, and the final circuit result isC ( x , y ) C(x,y)C(x,y ) output to Prover.

It is obvious that the aforementioned malicious adversary-safe two-party computation can always be achieved by using any cut-and-choose-based 2PC protocol . However, the 2PC protocol that directly uses C&C technology, the corresponding confusion circuit is too huge.

Jawurek, Kerschbaum and Orlandi observed: Since Verifier has no input, if he is asked to generate GC, then this GC can be used for checking and evaluation at the same time : to reverse the role, we let Verifier generate a Yao's Garbled Circuit , although Prover can Observing all the labels, you can theoretically obtain any plaintext input bits of the Verifier, but the Verifier has no privacy input at all. Therefore, it is only necessary to set the repetition factor as ρ = 1 \rho=1r=1. The size of the confusion circuit under C&C technology is greatly reduced.

The JKO agreement is as follows:

  1. Verifier P 1 P_1 P1Base C ( ⋅ , y ) C(\cdot,y)C(,y ) of1 11 obfuscation circuit GC, sent to ProverP 2 P_2P2
  2. P 2 P_2 P2Get xx with OT protocolFor the confusing input corresponding to x , the calculation circuit obtains the proof result v ∈ { 0 , 1 } v \in \{0,1\}v{ 0,1 } 's obfuscated outputkoutv k_{out}^vkoutv
  3. P 2 P_2 P2 k o u t v k_{out}^v koutvTo make a commit , only commit the value c = commit ( koutv , r ) c = commit(k_{out}^v,r)c=commit(koutv,r ) send toP 1 P_1P1
  4. received ccAfter c ,P 1 P_1P1Turn on GC, P 2 P_2P2to check that it is correct,
    1. If the circuit is correct, then P 2 P_2P2发送 ( k o u t v , r ) = d e c o m m i t ( c ) (k_{out}^v,r) = decommit(c) (koutv,r)=d eco mmit ( c ) forP 1 P_1P1
    2. If the circuit is wrong, then P 2 P_2P2Terminate the agreement (malicious Verifier found)
  5. P 1 P_1 P1Verify that the uncommitment is legal,
    1. If legal, P 1 P_1P1Output label koutv k_{out}^vkoutvThe corresponding plaintext output vvv(当v = 1 v=1v=1 ,P 1 P_1P1Believe P 2 P_2P2Prove that ( x , y ) ∈ R (x,y) \in R(x,y)R
    2. If illegal, P 1 P_1P1output 0 00 (malicious Prover found)

Obviously the above non-interactive ZKP protocol is complete. Its security is discussed below:

  1. secure against a cheating verifier (reliability): Before Verifier turns on GC, Prover has made a commitment to the output result, so it is difficult for a malicious Prover not to know xxIn the case of x, kout 1 k_{out}^1is calculatedkout1
  2. secure against a cheating prover (zero-knowledge): Only when the Prover verifies that this GC is indeed a circuit C ( ⋅ , y ) C(\cdot,y)C(,y ) before revealing the final calculation resultkoutv k_{out}^vkoutv, so Verifier cannot use the wrong circuit to learn about xxany information about x .

Guess you like

Origin blog.csdn.net/weixin_44885334/article/details/126804764