4. Encrypting QAP
Encrypting QAP
We now have:
Irrespective of the fact that this is expressed in matrix form, its really an equality between polynomials - and said polynomials will be evaluated at some random point. If the equality holds upon evaluation, verification is cleared.
Currently there are two problems we need to address:
The first problem with this is that its not zero-knowledge; we need to encrypt it via elliptic curve points
The second is that the prover could create a proof based on 3 arbitrary values such that
a.b = c
, with no relation to the original claim.Remember, the only thing the verifier does is check equality of the proof through some elliptic curve and mapping action.
For a trivial proof of
1*1 = 1
, the verifier’s computations would clear and reflect that the equality is correct and consistent.
In this section we will address the first problem of encryption. Elliptic curve generator points are used to obfuscate the witness values provided by the user.
Consider U.a
U.a
After substituting the witness values, the polynomial is evaluated at some random value, tau(Ï„).
tau(Ï„) is generated during the trusted setup phase
Now we could proceed to evaluate the polynomial at x = Ï„, to verify the equality
However, this would not be very ZK of us. Therefore, instead of x = Ï„, we will use x = Ï„[G]
In the case of U.a
,
where G1 is the elliptic curve generator point of group 1.
In similar vein,
From this arrangement, is should be clear to the reader that
where A,B and C are elliptic curve points of order 1, 2 and 1 respectively.
Therefore, we will need to transform h(x) and t(x) into elliptic curve points as well
t(x) is evaluated within the trusted setup.
h(x), however, is handled by the prover.
Evaluating t(x)
Since we need to do point addition with [C]/(W.a)
, we have to use G1
.
Essentially, we are just doing point (scalar) multiplication of the G1 point. (Or addition; all multiplication is addition if you are audacious enough).
Evaluating h(x)
h(x) is evaluated as such:
What this means is that h(x) is not independently evaluated on its own like t(x). Rather it is evaluated by requiring as input:
Trusted setup: powers of tau
The trusted setup generates both a proving key and a verifier key. We will talk about the verifier key in a later section.
The proving key, which is generated at this stage comprises of the following powers of tau:
→ for obtaining
[A]
and[C]
→ for obtaining
[B]
→ for obtaining
[HT]
The degree to which tau is raised is dictated by the polynomial which is in turn determined by the number of constraints.
Using the proving key and the witness values provided by the user, the prover will generate elliptic curve points: [A]
, [B]
, [C]
, [HT]
.
This generated proof is handed to the verifier, which simply checks for equality after raising the points to the G12 group via bilinear mapping.
Like so:
Note that here, [C] = [C] + [HT]
; all of which are group 1 EC points.
Ï„, Tau is not communicated to the prover
Prover receives proving key, which are the powers of tau
Tau is therefore obfuscated through ECC and the discrete log problem.
Tau is toxic waste that must be disposed; cannot be revealed. If revealed will allow for creation of fake proofs.
Last updated
Was this helpful?