The BGW is a secure multiparty computation protocol for polynomials over a finite field.
Model
Let p be a prime number, and let Fp be a finite field of order p.
In the setting, there are n parties, where the party i holds data bi,0∈Fp.
The objective is to compute a polynomial f(x1,…,xn) over Fp in a privacy-preserving manner.
Privacy Guarantee.
We assume all parties are curious but honest.
A protocol is considered t-private, if any set of up to t players cannot learn more from protocol's outcome than they could jointly infer from their own private inputs and outputs.
Protocol
We need the following protocol as a primitive for sharing information between the parties.
Shamir Secret Sharing Scheme S Partyi∈[n]:
Sample independent random primes bi,1,…,bi,t∈Fp.
Let bi≐(bi,0,bi,1,…,bi,t).
Let gbi(x)≐bi,0+bi,1⋅x+…+bi,t⋅xt.
For each user j∈[n]:
Send gbi(j) to user j
We call gbi(j) a share of the secret bi,0.
Privacy Guarantee. It is easy to verify that S is t-private.
The key result we would like to establish is that a polynomial f(x1,…,xn) can also be computed in a t-private manner.
Since a polynomial can be constructed through additions, scalar multiplication, and the multiplication of (smaller) polynomials, it is sufficient to demonstrate how these operations can be performed in a t-private manner.
We begin by discussing the addition protocol.
Protocols for subtraction and scalar multiplication can be derived using similar techniques.
Finally, we present the multiplication protocol.
Addition
We start with a simple protocol, which tries to add up bk,0 and bℓ,0, for some parties k,ℓ∈[n].
Adding bk,0 and bℓ,0:
Partyk:
Invoke S to send gbk(j) to each j∈[n].
Partyℓ:
Invoke S to send gbℓ(j) to each j∈[n].
Partyi∈[n]:
On receiving gbk(i) and gbℓ(i), compute gbk(i)+gbℓ(i).
The key observation is that the following relation holds for polynomials:
Thus, the addition operation can be viewed as a virtual party v holding data bk,0+bℓ,0, which is then shared with all parties i∈[n] via the Shamir Secret Sharing Scheme.
In this scheme, the polynomial coefficients are bk+bℓ.
Consequently, each party i receives a share of the secret, denoted as gbk+bℓ(i).
Virtual Party v:
Invoke S to send gbk+bℓ(j) to each j∈[n].
This alternative view facilitates a clearer understanding of composition.
For example, suppose we want to compute bk,0+bℓ,0+bm,0 for some parties k,ℓ,m∈[n]. First, we can apply the protocol described above to compute bk,0+bℓ,0.
Then, we consider two parties: a virtual party v holding data bk,0+bℓ,0, and party m with data bm,0. We can then invoke the addition protocol again to compute bk,0+bℓ,0+bm,0. Importantly, communication with the virtual party is not actually required, as after the first protocol invocation, each party i already possesses the secret share gbk+bℓ(j).
Privacy Guarantee.
After the addition protocol, each party i receives a share of the secret bk,0+bℓ,0, represented by gbk+bℓ(i).
Since gbk+bℓ(x) is a random polynomial of degree t, the output of the addition protocol remains t-private.
Note this is a random polynomial, in the sense that the coefficients of this polynomial are independent.
Therefore, the outputs gbk×bℓ(i)+∑j∈[n]gj(i),i∈[n] are 2t-private.
Remark.
It appears sufficient for one party i (if trusted) to generate a random polynomial gi and share gi(1),…,gi(n) with other parties.
Essentially, this adds a random coefficient to each coefficient of gbk×bℓ(x).
Truncation
To simplify notation, let
h(x)≐c0+c1⋅x+…+c2t⋅x2t
be a shorthand for the polynomial gbk×bℓ(x)+∑i∈[n]gi(x).
We have shown that c1,…,cn are random integers from Fp.
Our goal is to truncate its degree from 2t to t:
hˉ(x)≐c0+c1⋅x+…+ct⋅xt,
and for each party i∈[n], replaces its share h(i) by hˉ(i).
A naive approach is to reveal the secret shares of a set of 2t clients, for example h(1),…,h(2t), so that we can recover the entire polynomial h(x) (and therefore the secret value h(0)=c0).
Can we achieve this in a t-private manner?
The answer is "Yes"!
We are going to show that, there is a matrix T, s.t.,
Observe that, multiplying h1:n by T only involves addition and scalar multiplications of secret shares, which we have already shown can be performed in a t-private manner.
It remain to explain what T is.
Then h1:n=V×c, and hˉ1:n=V×cˉ.
We also know that there exists a projection matrix P, s.t., cˉ=Pc.
It follows that
hˉ1:n=V×cˉ=V×P×c=V×P×V−1×h1:n.
Taking T=V×P×V−1 computes the proof.
Remark. If we directly compute V−1×h1:n, we recover all coefficients of h(x).
The key trick is to compute (V×P×V−1)×h1:n instead, bypassing the explicit computation of V−1×h1:n.
Reference
[1] M. Ben-Or, S. Goldwasser, and A. Wigderson, “Completeness theorems for non-cryptographic fault-tolerant distributed computation,” in Providing Sound Foundations for Cryptography: On the Work of Shafi Goldwasser and Silvio Micali, New York, NY, USA: Association for Computing Machinery, 2019, pp. 351–371. Accessed: Nov. 07, 2024. Online Available.