From IPA to Bulletproofs

Inner product argument (IPA)

Construction of IPA

Public parameter: g , h ∈ G n \mathbf{g}, \mathbf{h} \in \mathbb{G}^n g,hGn
Prover input: a , b ∈ F p n \mathbf{a}, \mathbf{b} \in \mathbb{F}_p^n a,bFpn
Verifier input: C a = g a C_a = \mathbf{g}^{\mathbf{a}} Ca=ga, C b = h b C_b = \mathbf{h} ^ {\mathbf{b}} Cb=hb, c ∈ F p c \in \mathbb{F}_p cFp

To prove ⟨ a , b ⟩ = c \langle \mathbf{a}, \mathbf{b} \rangle = c a,b=c, the main idea is using a random challenge to fold the vector of length n n n into a vector of length n / 2 n/2 n/2, and recursively make inner product argument for vectors of length n / 2 n/2 n/2. Until the length is 1 1 1, the prover can directly send the single element to verifier.

The vector a \mathbf{a} a can be divided into a L ∣ ∣ a R \mathbf{a}_L || \mathbf{a}_R aL∣∣aR, where both a L \mathbf{a}_L aL and a R \mathbf{a}_R aR are of length n / 2 n / 2 n/2. So can b \mathbf{b} b be divided into b L ∣ ∣ b R \mathbf{b}_L || \mathbf{b}_R bL∣∣bR.

When combining short vectors with a random challenge x ∈ F x \in \mathbb{F} xF such that
a ′ = a L + x ⋅ a R b ′ = b L + x − 1 ⋅ b R \begin{align*} \mathbf{a'} &= \mathbf{a}_L + x \cdot \mathbf{a}_R \\ \mathbf{b'} &= \mathbf{b}_L + x^{-1} \cdot \mathbf{b}_R \end{align*} ab=aL+xaR=bL+x1bR
we can find ⟨ a ′ , b ′ ⟩ = ⟨ a L , b L ⟩ + ⟨ a R , b R ⟩ + x − 1 ⋅ ⟨ a L , b R ⟩ + x ⋅ ⟨ a R , b L ⟩ = ⟨ a , b ⟩ + x − 1 ⋅ ⟨ a L , b R ⟩ + x ⋅ ⟨ a R , b L ⟩ \langle \mathbf{a'}, \mathbf{b'} \rangle = \langle \mathbf{a}_L, \mathbf{b}_L \rangle + \langle \mathbf{a}_R, \mathbf{b}_R \rangle + x^{-1} \cdot \langle \mathbf{a}_L, \mathbf{b}_R \rangle + x \cdot \langle \mathbf{a}_R, \mathbf{b}_L \rangle = \langle \mathbf{a}, \mathbf{b} \rangle + x^{-1} \cdot \langle \mathbf{a}_L, \mathbf{b}_R \rangle + x \cdot \langle \mathbf{a}_R, \mathbf{b}_L \rangle a,b=aL,bL+aR,bR+x1aL,bR+xaR,bL=a,b+x1aL,bR+xaR,bL.

Prover can send ⟨ a L , b R ⟩ \langle \mathbf{a}_L, \mathbf{b}_R \rangle aL,bR, ⟨ a R , b L ⟩ \langle \mathbf{a}_R, \mathbf{b}_L \rangle aR,bL before receiving the challenge. Now, there is a problem to get commitment of g ′ a ′ \mathbf{g'}^{\mathbf{a'}} ga, h ′ b ′ \mathbf{h'}^{\mathbf{b'}} hb.

Since verifer has g L a L ⋅ g R a R \mathbf{g}_L^{\mathbf{a}_L} \cdot \mathbf{g}_R ^ {\mathbf{a}_R} gLaLgRaR at the beginning, prover can send g L a R \mathbf{g}_L^{\mathbf{a}_R} gLaR and g R a L \mathbf{g}_R^{\mathbf{a}_L} gRaL, so that verifier can construct
g ′ a ′ = g ′ a L + x ⋅ a R = g L a L + x ⋅ a R ⋅ ( g R x − 1 ) a L + x ⋅ a R = ( g L a R ) x ( g L a L ⋅ g R a R ) ( g R a L ) x − 1 \begin{align*} \mathbf{g'}^{\mathbf{a'}} &= \mathbf{g'}^{\mathbf{a}_L + x \cdot \mathbf{a}_R} \\ &= \mathbf{g}_L ^{\mathbf{a}_L + x \cdot \mathbf{a}_R} \cdot (\mathbf{g}_R^{x^{-1}})^{\mathbf{a}_L + x \cdot \mathbf{a}_R} \\ &= (\mathbf{g}_L^{\mathbf{a}_R})^x (\mathbf{g}_L^{\mathbf{a}_L} \cdot \mathbf{g}_R ^ {\mathbf{a}_R}) (\mathbf{g}_R^{\mathbf{a}_L})^{x^{-1}} \end{align*} ga=gaL+xaR=gLaL+xaR(gRx1)aL+xaR=(gLaR)x(gLaLgRaR)(gRaL)x1
with random challenge x x x. The construction of h ′ b ′ \mathbf{h'}^{\mathbf{b'}} hb is almost the same.

Here we show the construction of g ′ a ′ \mathbf{g'}^{\mathbf{a'}} ga is natural. Given vector v = ( g L a L , g L a R , g R a L , g R a R ) \mathbf{v} = (\mathbf{g}_L^{\mathbf{a}_L}, \mathbf{g}_L^{\mathbf{a}_R}, \mathbf{g}_R^{\mathbf{a}_L}, \mathbf{g}_R^{\mathbf{a}_R}) v=(gLaL,gLaR,gRaL,gRaR), the original C a C_a Ca can be regarded as inner product ( 1 , 0 , 0 , 1 ) (1, 0, 0, 1) (1,0,0,1) with v \mathbf{v} v, details neglected. Our objectivity is constructing inner product μ ( 1 , x , 0 , 0 ) + λ ( 0 , 0 , 1 , x ) \mu (1, x, 0, 0) + \lambda (0, 0, 1, x) μ(1,x,0,0)+λ(0,0,1,x) with v \mathbf{v} v, so choosing g L a R \mathbf{g}_L^{\mathbf{a}_R} gLaR, which is ( 0 , 1 , 0 , 0 ) (0, 1, 0, 0) (0,1,0,0) and g R a L \mathbf{g}_R^{\mathbf{a}_L} gRaL, which is ( 0 , 0 , 1 , 0 ) (0, 0, 1, 0) (0,0,1,0) is a really natural thought.
( 1 0 0 1 0 1 0 0 0 0 1 0 ) ⋅ ( 1 x x − 1 ) = ( 1 x x − 1 1 ) \left( \begin{matrix} 1 & 0 & 0 & 1 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 1 & 0 \end{matrix} \right) \cdot \left( \begin{matrix} 1 \\ x \\ x^{-1} \end{matrix} \right) = \left( \begin{matrix} 1 \\ x \\ x^{-1} \\ 1 \end{matrix} \right) 100010001100 1xx1 = 1xx11

Realistic IPA

In practice, the commited vector also has a random mask, and the inner product result may also be a secret. That is, Given commitments C a = u ρ a g a C_a = u^{\rho_a} \mathbf{g}^{\mathbf{a}} Ca=uρaga, C b = u ρ b h b C_b = u^{\rho_b} \mathbf{h}^{\mathbf{b}} Cb=uρbhb, C 0 = u ρ 0 g c C_0 = u^{\rho_0} g^{c} C0=uρ0gc, verifer need to be convinced that ⟨ a , b ⟩ = c \langle a, b \rangle = c a,b=c.

Prover can only change to send Pedersen commitments of ⟨ a L , b R ⟩ \langle \mathbf{a}_L, \mathbf{b}_R \rangle aL,bR, ⟨ a R , b L ⟩ \langle \mathbf{a}_R, \mathbf{b}_L \rangle aR,bL, instead of send them directly.

We also remark a trivial construction of IPA of a committed vector with a public vector can be derived, since verifier can construct commitment from public values on his own.

Add zero-knowledge

Previous construction doesn’t hold zero knowledge property. For example, an adversary knows the committed vector C a C_a Ca is either a 1 \mathbf{a}_1 a1 or a 2 \mathbf{a}_2 a2. He can simulate the folding procedure of two vectors with challenges each round, and checking the final folded result to discern a 1 \mathbf{a}_1 a1 or a 2 \mathbf{a}_2 a2.

We directly discuss the hardest problem: prove inner product result of two commited vectors a \mathbf{a} a, b \mathbf{b} b equals a committed value c 0 c_0 c0. To obtain a zero knowledge IPA, prover can use random vectors to mask secret vectors.

Before the first round, prover randomly choose s , t ∈ F p n , ρ s , ρ t ∈ F p \mathbf{s}, \mathbf{t} \in \mathbb{F}_p^n, \rho_s, \rho_t \in \mathbb{F}_p s,tFpn,ρs,ρtFp and commit C s = C o m ( s ; ρ s ) = u ρ s g s C_s = Com(\mathbf{s}; \rho_s) = u^{\rho_s}\mathbf{g}^{\mathbf{s}} Cs=Com(s;ρs)=uρsgs, C t = C o m ( t ; ρ t ) = u ρ t h t C_t = Com(\mathbf{t}; \rho_t) = u^{\rho_t}\mathbf{h}^{\mathbf{t}} Ct=Com(t;ρt)=uρtht to verifier.

Define l ( X ) = a + s ⋅ X l(X) = \mathbf{a} + \mathbf{s} \cdot X l(X)=a+sX r ( X ) = b + t ⋅ X r(X) = \mathbf{b} + \mathbf{t} \cdot X r(X)=b+tX. Define ⟨ l ( X ) , r ( X ) ⟩ = ⟨ a , b ⟩ + ( ⟨ s , b ⟩ + ⟨ a , t ⟩ ) X + ⟨ s , t ⟩ X 2 = c 0 + c 1 X + c 2 X 2 \langle l(X), r(X) \rangle = \langle \mathbf{a}, \mathbf{b} \rangle + (\langle \mathbf{s}, \mathbf{b} \rangle + \langle \mathbf{a}, \mathbf{t} \rangle) X + \langle \mathbf{s}, \mathbf{t} \rangle X^2 = c_0 + c_1 X + c_2 X^2 l(X),r(X)⟩=a,b+(⟨s,b+a,t⟩)X+s,tX2=c0+c1X+c2X2. For random x x x, prover can commit c 1 , c 2 c_1, c_2 c1,c2 and prove ⟨ l ( x ) , r ( x ) ⟩ = c 0 + c 1 x + c 2 x 2 \langle l(x), r(x) \rangle = c_0 + c_1 x + c_2 x^2 l(x),r(x)⟩=c0+c1x+c2x2.

More precisely, besides commitment C s C_s Cs and C t C_t Ct, prover also commit C 1 = C o m ( c 1 ; ρ 1 ) = u ρ 1 g c 1 C_1 = Com(c_1; \rho_1) = u^{\rho_1} g^{c_1} C1=Com(c1;ρ1)=uρ1gc1 and C 2 = C o m ( c 2 ; ρ 2 ) = u ρ 2 g c 2 C_2 = Com(c_2; \rho_2) = u^{\rho_2} g^{c_2} C2=Com(c2;ρ2)=uρ2gc2. After that, verifier sends random challenge x x x and prover proves ⟨ a + x s , b + x t ⟩ = c 0 + c 1 x + c 2 x 2 \langle \mathbf{a} + x\mathbf{s}, \mathbf{b} + x\mathbf{t}\rangle = c_0 + c_1 x + c_2 x^2 a+xs,b+xt=c0+c1x+c2x2 through IPA scheme. Due to homomorphism of Pedersen commitment, previous commitments ensure verifier can compute commitments of random linear combined vectors and inner product result.

Proof size

Each round, prover send pedersen commitment of ⟨ a L , b R ⟩ \langle \mathbf{a}_L, \mathbf{b}_R \rangle aL,bR, ⟨ a R , b L ⟩ \langle \mathbf{a}_R, \mathbf{b}_L \rangle aR,bL, and g L a R \mathbf{g}_L^{\mathbf{a}_R} gLaR, g R a L \mathbf{g}_R^{\mathbf{a}_L} gRaL, h L b R \mathbf{h}_L^{\mathbf{b}_R} hLbR, h R b L \mathbf{h}_R^{\mathbf{b}_L} hRbL. So the proof size is 6 log ⁡ n + O ( 1 ) 6\log n + O(1) 6logn+O(1).

Prover complexity is obvious O ( n ) O(n) O(n) and verifier complexity is also O ( n ) O(n) O(n), since verifier have to compute g ′ \mathbf{g'} g and h ′ \mathbf{h'} h each round, which incurs linear complexity.

Range proof

Zero knowledge IPA proposed above can be used to construct range proof, which plays an important role in confidential transactions (CT).

Take an example in Bitcoin. Alice wants to transfer 5 bucks to Bob, and she holds a UXTO, whose amout of money is committed use Pedersen commitment, denoted as C = u ρ g m C = u^{\rho}g^m C=uρgm. Subtract 5 bucks, her new UTXO’s commitment should be C ′ = C / g 5 = u ρ g m − 5 C' = C / g^{5} = u^{\rho}g^{m - 5} C=C/g5=uρgm5. However, if m < 5 m < 5 m<5, the transaction should not be allowed, but Alice don’t want to leak her UTXO’s money amount. Proving money amout represented by C ′ C' C belongs to [ 0 , N ] [0, N] [0,N] is range proof. Notice that N N N should smaller half of ∣ F p ∣ |\mathbb{F}_p| Fp.

To prove u ρ g m u^{\rho} g^m uρgm represents a m m m falls in [ 0 , 2 n − 1 ] [0, 2^n - 1] [0,2n1], prover first decomposes m m m into a bit vector a ∈ F p n \mathbf{a} \in \mathbb{F}_p^n aFpn such that ⟨ a , 2 n ⟩ = m \langle \mathbf{a}, \mathbf{2}^n \rangle = m a,2n=m, a ∘ ( a − 1 n ) = 0 n \mathbf{a} \circ (\mathbf{a} - \mathbf{1}^n) = \mathbf{0}^n a(a1n)=0n, where k n = ( 1 , k , k 2 , ⋯   , k n − 1 ) \mathbf{k}^n = (1, k, k^2, \cdots, k^{n-1}) kn=(1,k,k2,,kn1).

The hadamard product a ∘ ( a − 1 n ) = 0 n \mathbf{a} \circ (\mathbf{a} - \mathbf{1}^n) = \mathbf{0}^n a(a1n)=0n can be transformed into ⟨ a ∘ ( a − 1 n ) , y n ⟩ = ⟨ a , ( a − 1 n ) ∘ y n ⟩ = 0 \langle \mathbf{a} \circ (\mathbf{a} - \mathbf{1}^n), \mathbf{y}^n \rangle = \langle \mathbf{a}, (\mathbf{a} - \mathbf{1}^n) \circ \mathbf{y}^n \rangle = 0 a(a1n),yn=a,(a1n)yn=0.

Given the commitment of g a \mathbf{g}^{\mathbf{a}} ga, the commitment of ( a ) ∘ y n (\mathbf{a}) \circ \mathbf{y}^n (a)yn can be derived from setting h = g ( 1 / y ) n \mathbf{h} = \mathbf{g}^{(\mathbf{1/y})^n} h=g(1/y)n. Then
C o m ( a ∘ y n ) = h a ∘ y n = g ( 1 / y ) n ∘ a ∘ y n = g a = C o m ( a ) \begin{align*} Com(\mathbf{a} \circ \mathbf{y}^n) &= \mathbf{h}^{\mathbf{a} \circ \mathbf{y}^n} \\ &= \mathbf{g}^{(\mathbf{1/y})^n \circ \mathbf{a} \circ \mathbf{y}^n} \\ &= \mathbf{g}^{\mathbf{a}} = Com(\mathbf{a}) \end{align*} Com(ayn)=hayn=g(1/y)nayn=ga=Com(a)

After sending commitment C a = u ρ a g a C_a = u^{\rho_a}\mathbf{g}^\mathbf{a} Ca=uρaga and receiving random challenges y , z ∈ F p y, z \in \mathbb{F}_p y,zFp, prover use zkIPA to prove ⟨ a , 2 n + z ⋅ ( a − 1 n ) ⟩ = m \langle \mathbf{a}, \mathbf{2}^n + z \cdot (\mathbf{a} - \mathbf{1}^n) \rangle = m a,2n+z(a1n)⟩=m.

The total proof size is also 6 log ⁡ n + O ( 1 ) 6\log n + O(1) 6logn+O(1).

Bulletproofs

Bulletproofs mainly aims to deal with range proof with a smaller proof size. The main idea is commit a \mathbf{a} a and a − 1 n \mathbf{a} - \mathbf{1}^n a1n simultaneously.

Inner product argument

Different from IPA defined previously, Bulletproofs IPA commits two vector together instead of independently in the statement. Specifically, it proves the following relation:
( g , h ∈ G n , u , P ∈ G ; a , b ∈ F p n ) (\mathbf{g}, \mathbf{h} \in \mathbb{G}^n, u, P \in \mathbb{G}; \mathbf{a}, \mathbf{b} \in \mathbb{F}_p^n) (g,hGn,u,PG;a,bFpn)
such that P = g a h b ⋅ u ⟨ a , b ⟩ P = \mathbf{g}^{\mathbf{a}} \mathbf{h}^{\mathbf{b}} \cdot u^{\langle \mathbf{a}, \mathbf{b} \rangle} P=gahbua,b, where g , h , u , P \mathbf{g}, \mathbf{h}, u, P g,h,u,P are public instance, a , b \mathbf{a}, \mathbf{b} a,b are witness.

Similar with previous IPA, it folds vectors with random challenge into half in each round. Although previous scheme also applies, we will follow the folding result in Bulletproofs paper,
a ′ = x a L + x − 1 a R b ′ = x − 1 b L + x b R \begin{align*} \mathbf{a'} &= x \mathbf{a}_L + x^{-1} \mathbf{a}_R \\ \mathbf{b'} &= x^{-1} \mathbf{b}_L + x \mathbf{b}_R \end{align*} ab=xaL+x1aR=x1bL+xbR
Define H ( v 1 , v 2 , v 3 , v 4 , v ) = g L v 1 ⋅ g R v 2 ⋅ h L v 3 ⋅ h R v 4 ⋅ u v H(\mathbf{v}_1, \mathbf{v}_2, \mathbf{v}_3, \mathbf{v}_4, v) = \mathbf{g}_L^{\mathbf{v}_1} \cdot \mathbf{g}_R^{\mathbf{v}_2} \cdot \mathbf{h}_L^{\mathbf{v}_3} \cdot \mathbf{h}_R^{\mathbf{v}_4} \cdot u^v H(v1,v2,v3,v4,v)=gLv1gRv2hLv3hRv4uv
This time, prover firsly commit L , R L, R L,R to verifier, where
L = H ( 0 a L b R 0 ⟨ a L , b R ⟩ ) R = H ( a R 0 0 b L ⟨ a R , b L ⟩ ) P = H ( a L a R b L b R ⟨ a , b ⟩ ) \begin{matrix*} L = H(& \mathbf{0} & \mathbf{a}_L & \mathbf{b}_R & \mathbf{0} & \langle \mathbf{a}_L, \mathbf{b}_R \rangle &) \\ R = H(& \mathbf{a}_R & \mathbf{0} & \mathbf{0} & \mathbf{b}_L & \langle \mathbf{a}_R, \mathbf{b}_L \rangle &) \\ P = H(& \mathbf{a}_L & \mathbf{a}_R & \mathbf{b}_L & \mathbf{b}_R & \langle \mathbf{a}, \mathbf{b} \rangle &) \end{matrix*} L=H(R=H(P=H(0aRaLaL0aRbR0bL0bLbRaL,bRaR,bLa,b)))

Verifier can compute
L x 2 ⋅ P ⋅ R x − 2 = H ( x − 1 a ′ , x a ′ , x b ′ , x − 1 b ′ , ⟨ a ′ , b ′ ⟩ ) = ( g L x − 1 ∘ g R x ) a ′ ⋅ ( h L x ∘ h R x − 1 ) b ′ ⋅ u ⟨ a ′ , b ′ ⟩ L^{x^2} \cdot P \cdot R^{x^{-2}} = H(x^{-1} \mathbf{a'}, x \mathbf{a'}, x \mathbf{b'}, x^{-1}\mathbf{b'}, \langle \mathbf{a'}, \mathbf{b'} \rangle) = \left(\mathbf{g}_L^{x^{-1}} \circ \mathbf{g}_R^{x}\right) ^ {\mathbf{a'}} \cdot \left(\mathbf{h}_L^{x} \circ \mathbf{h}_R^{x^{-1}}\right) ^ {\mathbf{b'}} \cdot u^{\langle \mathbf{a'}, \mathbf{b'} \rangle} Lx2PRx2=H(x1a,xa,xb,x1b,a,b⟩)=(gLx1gRx)a(hLxhRx1)bua,b
Thus, the witness is halved. After log ⁡ n \log n logn rounds, it will be reduced to only 2 2 2 element. Proof size is only 2 group element each round, so total proof size is 2 log ⁡ n + O ( 1 ) 2\log n + O(1) 2logn+O(1), only 1/3 campared to previous IPA.

A proof of relation below can be constructed utilizing this inner product argument.

( g , h ∈ G n , P ∈ G , c ∈ F p ; a , b ∈ F p n ) (\mathbf{g}, \mathbf{h} \in \mathbb{G}^n, P \in \mathbb{G}, c \in \mathbb{F}_p; \mathbf{a}, \mathbf{b} \in \mathbb{F}_p^n) (g,hGn,PG,cFp;a,bFpn)
such that P = g a h b P = \mathbf{g}^{\mathbf{a}} \mathbf{h}^{\mathbf{b}} P=gahb and c = ⟨ a , b ⟩ c = \langle \mathbf{a}, \mathbf{b} \rangle c=a,b.

在这里插入图片描述

Range proof

In Bulletproofs range proof, prover commit bit decomposition of secret value a L \mathbf{a}_L aL and a R = a L − 1 n \mathbf{a}_R = \mathbf{a}_L - \mathbf{1}^n aR=aL1n together as A = r α g a L h a R A = r^{\alpha} \mathbf{g}^{\mathbf{a}_L} \mathbf{h}^{\mathbf{a}_R} A=rαgaLhaR. The secret value is committed as V = r γ g v V = r^{\gamma} g^v V=rγgv.

We need to prove three equations below
⟨ a L , 2 n ⟩ = v , ⟨ a L , a R ∘ y n ⟩ = 0 , a L = a R + 1 n \langle \mathbf{a}_L, \mathbf{2}^n\rangle = v, \qquad \langle \mathbf{a}_L, \mathbf{a}_R \circ \mathbf{y}^n \rangle = 0, \qquad \mathbf{a}_L = \mathbf{a}_R + \mathbf{1}^n aL,2n=v,aL,aRyn=0,aL=aR+1n

Only the second equation is easy to prove through Bulletproofs IPA directly, by setting h ′ = h ( 1 / y ) n \mathbf{h'} = \mathbf{h}^{(\mathbf{1/y})^n} h=h(1/y)n. The first and third isn’t quite simple.

However, due to ⟨ a L , a R ⟩ = 0 \langle \mathbf{a}_L, \mathbf{a}_R \rangle = 0 aL,aR=0, the first equation can be transformed into ⟨ a L , a R + z ⋅ 2 n ⟩ = z ⋅ v \langle \mathbf{a}_L, \mathbf{a}_R + z \cdot \mathbf{2}^n \rangle = z \cdot v aL,aR+z2n=zv for random z z z, which can prove straightforwardly. And the third equation can be transformed into ⟨ a L − a R − 1 n , y n ⟩ = 0 \langle \mathbf{a}_L - \mathbf{a}_R - \mathbf{1}^n, \mathbf{y}^n \rangle = 0 aLaR1n,yn=0 for random y y y, and it can be then transformed into
⟨ a L − 1 n , y n ∘ ( a R + 1 n ) ⟩ = ⟨ a L , y n ∘ a R ⟩ + ⟨ a L , y n ⟩ − ⟨ a R , y n ⟩ − ⟨ 1 n , y n ⟩ = ⟨ a L , y n ⟩ − ⟨ a R , y n ⟩ − ⟨ 1 n , y n ⟩ = ⟨ a L − a R − 1 n , y n ⟩ = 0 \begin{align*} \langle \mathbf{a}_L - \mathbf{1}^n, \mathbf{y}^n \circ (\mathbf{a}_R + \mathbf{1}^n) \rangle &= \langle \mathbf{a}_L, \mathbf{y}^n \circ \mathbf{a}_R \rangle + \langle \mathbf{a}_L, \mathbf{y}^n\rangle - \langle \mathbf{a}_R, \mathbf{y}^n\rangle - \langle \mathbf{1}^n, \mathbf{y}^n\rangle \\ &= \langle \mathbf{a}_L, \mathbf{y}^n\rangle - \langle \mathbf{a}_R, \mathbf{y}^n\rangle - \langle \mathbf{1}^n, \mathbf{y}^n\rangle = \langle \mathbf{a}_L - \mathbf{a}_R - \mathbf{1}^n, \mathbf{y}^n \rangle = 0 \end{align*} aL1n,yn(aR+1n)⟩=aL,ynaR+aL,ynaR,yn1n,yn=aL,ynaR,yn1n,yn=aLaR1n,yn=0

Up till now, we show three equations in range proof can be proved independently. As usual, they can be prove together through random linear combination. So the total prove size is only 2 log ⁡ n + O ( 1 ) 2\log n + O(1) 2logn+O(1).

We can see the bulletproofs now isn’t zero-knowledge. This problem can be easily dealt with by utilizating techniques in construction of zero knowlodge IPA. Detailed protocol can be seen in the whole paper.

Prover can aggregate multiple range proofs for m m m committed values. It’s straightforward that we can use a vector of length m ⋅ n m \cdot n mn to binary represent all m m m values. Proof size of aggregating range proof is log ⁡ ( m ⋅ n ) + O ( 1 ) \log (m \cdot n) + O(1) log(mn)+O(1).

Remarks

IPA of two commited vectors

Can we construct an IPA of two commited vectors through Bulletproofs IPA? It can reduce proof size of IPA to only 2 log ⁡ n + O ( 1 ) 2\log n + O(1) 2logn+O(1). Here’s my failure attempt below.

Given C a = g a , C b = h b , c = ⟨ a , b ⟩ C_a = \mathbf{g}^{\mathbf{a}}, C_b = \mathbf{h}^{\mathbf{b}}, c = \langle \mathbf{a}, \mathbf{b} \rangle Ca=ga,Cb=hb,c=a,b,verifier sends challenge x x x,then using Bulletproofs IPA prove knowledge of a ′ , b ′ \mathbf{a'}, \mathbf{b'} a,b such that u x , P = C a C b x u x 2 ⋅ c u^{x}, P = C_a C_b^x u^{x^2 \cdot c} ux,P=CaCbxux2c. Completeness holds since a ′ = a \mathbf{a'} = \mathbf{a} a=a, b ′ = x b \mathbf{b'} = x\mathbf{b} b=xb satisfy the relation.

However, soundness doesn’t hold. A simple counterexample is prover set C a = h b C_a = \mathbf{h}^{\mathbf{b}} Ca=hb, C b = g a C_b = \mathbf{g}^{\mathbf{a}} Cb=ga and c = ⟨ a , b ⟩ c = \langle \mathbf{a}, \mathbf{b} \rangle c=a,b. We can find a ′ = x a \mathbf{a'} = x\mathbf{a} a=xa, b ′ = b \mathbf{b'} = \mathbf{b} b=b satisfy the Bulletproofs IPA relation, but prover doesn’t possess a knowledge of an vector v \mathbf{v} v such that g v = C a \mathbf{g}^{\mathbf{v}} = C_a gv=Ca.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值