venillalemon

January 26, 2026 · Notion export

Polynomial Commitment Schemes and Fiat-Shamir


Polynomial commitment based on discrete-log and pairing

KZG: pairing

We have GG as a group of prime order pp with generator gg. We have a bilinear map e:G×GGTe:G\times G\to G_T where GGTCpG\cong G_T\cong C_p are pp-order cyclic groups. We use F=Fpd[X]\mathcal{F}=\mathbb{F}_p^{\leq d}[X], and the public parameters gpgp are generated as

(g,gτ,gτ2,,gτd)setup(λ,F;τ)(g,g^\tau,g^{\tau^2},\dots,g^{\tau^d})\leftarrow\mathsf{setup}(\lambda,\mathcal{F};\tau)

where τ\tau is a random element in Fp\mathbb{F}_p; after computing, abort the random τ\tau. To commit to a polynomial f(X)=i=0dfiXif(X)=\sum_{i=0}^d f_iX^i, we compute

i=0d(gτi)ficommit(gp,f).\prod_{i=0}^d (g^{\tau^i})^{f_i}\leftarrow\mathsf{commit}(gp, f).

In the evaluation phase, with input uu, the prover sends vv and a proof π\pi for the verifier to verify f(u)=vf(u)=v using π\pi. The idea is if f(u)=vf(u)=v, then f(X)vf(X)-v is divisible by XuX-u. Let q(X)=(f(X)v)/(Xu)q(X)=(f(X)-v)/(X-u), then the proof is written as π=gq(τ)\pi=g^{q(\tau)} and (v,π)open(gp,f,u)(v,\pi)\leftarrow\mathsf{open}(gp,f,u). The verifier checks if e(gτu,π)=e(comfgv,g)e\left(g^{\tau-u},\pi\right)=e\left(\frac{\mathsf{com}_f}{g^{v}}, g\right). The verifier knows gτug^{\tau-u} because it knows gτg^\tau from the global parameter and it can compute gug^u from uu.

Time: commit O(d)O(d) group exponentiations, open (including computing qq) O(d)O(d) group exponentiations and O(d)O(d) group multiplications, verify O(1)O(1) pairings. Size: proof and commitment are both O(1)O(1) group elements.

The completeness is trivial. For soundness, if the prover outputs another (v,π)(v',\pi') such that f(u)vf(u)\not=v' and e(gτu,π)=e(comfgv,g)e\left(g^{\tau-u},\pi'\right)=e\left(\frac{\mathsf{com}_f}{g^{v'}}, g\right), then we have (denote δ=f(u)v\delta=f(u)-v'):

e(comfgv,g)=e(gf(τ)f(u)+δ,g)=e(gq(τ)+δτu,gτu)=e(gτu,π)e\left(\frac{\mathsf{com}_f}{g^{v'}}, g\right)=e\left(g^{f(\tau)-f(u)+\delta}, g^{}\right)=e\left(g^{q(\tau)+\frac{\delta}{\tau-u}}, g^{\tau-u}\right)=e\left(g^{\tau-u},\pi'\right)

so as a result

e(g,g)δτu=e(g,π)e(g,g)q(τ)e\left(g, g\right)^{\frac{\delta}{\tau-u}}=\frac{e\left(g,\pi'\right)}{e\left(g, g\right)^{q(\tau)}}

where the operations on the exponent are in Fp\mathbb{F}_p which corresponds to the multiplication in the groups GG and GTG_T. This is the qq-Strong Bilinear Diffie-Hellman** assumption, which says that it is hard to compute e(g,g)1τue(g,g)^{\frac{1}{\tau-u}} given (p,G,g,GT,e)(p,G,g,G_T,e) and gp=(g,gτ,,gτd)gp=(g,g^\tau,\dots,g^{\tau^d}).

Knowledge Soundness

The plain KZG is not knowledge soundness without assumptions like KoE or GGM. We will discuss the assumptions in the PCP-based SNARK.

Zero-Knowledge-ness

The plain KZG is not zk since the commit algorithm is deterministic. For example, you can use gf(τ)g^{f(\tau)} to test if ff is a zero polynomial. Here, we denote the protocol modified to zk in the graph below.

Setup: sample τ,η$Fp and compute gp(g,gτ,,gτd,gη); then delete τ,η.ProverVerifierr$Fp,comf=gf(τ)+rηcommit(gp,f;r)comfr$Fp,vf(u),π=(gq(τ)+rη,grr(τu))open(gp,f,u,r;r)uFp  v,π  e(π1,gτu)e(π2,gη)=?e(comfgv,g)\begin{align*} &\text{Setup: sample }\tau,\eta\xleftarrow{\$}\mathbb{F}_p\text{ and compute }gp←(g,g^{\tau},\dots,g^{\tau^d},g^\eta);\text{ then delete }\tau,\eta.\\ &\text{Prover}&&&\text{Verifier}\\ &r\xleftarrow{\$}\mathbb{F}_p,\mathsf{com}_f=g^{f(\tau)+r\eta}\leftarrow\mathsf{commit}(gp, f; r)&\xrightarrow{\mathsf{com}_f}&&\\ &r'\xleftarrow{\$}\mathbb{F}_p,v\leftarrow f(u),\pi=\left(g^{q(\tau)+r'\eta},g^{r-r'(\tau-u)}\right)\leftarrow\mathsf{open}(gp, f, u, r;r')&\xleftarrow{u\in\mathbb{F}_p}&\;&\\ &&\xrightarrow{v,\pi}&\;&e\left(\pi_1,g^{\tau-u}\right)e\left(\pi_2,g^{\eta}\right) \stackrel{?}{=} e\left(\frac{\mathsf{com}_f}{g^{v}}, g\right) \end{align*}

The polynomial is hidden by the random rr'.

Variants of KZG

  • For multivariate poly: f(x1,,xk)f(u1,,uk)=i[k](xiui)qi(x1,,xk)f(x_1,\dots,x_k)-f(u_1,\dots,u_k)=\sum_{i\in[k]}(x_i-u_i)q_i(x_1,\dots,x_k) . Prover computes and sends πi=gqi(τ1,,τn)\pi_i=g^{q_i(\tau_1,\dots,\tau_n)} . Prover time is O(km)O(km) group exponentials where m2km\leq 2^k is the number of terms of ff . [Chopin] claims to reduce the prover time to m+O(m)m+O(\sqrt{m}) MSMs (compute jgjaj\prod_j g_j^{a_j} ).
  • For batch query on u1,,umu_1,\dots,u_m: f(x)h(x)=q(x)i[m](xui)f(x)-h(x)=q(x)\prod_{i\in[m]}(x-u_i) where h(x)h(x) is the extrapolation of (ui,f(ui))(u_i,f(u_i))’s.
  • For multi-party, each party has a private number for setup, and the public parameters are (for example, 2-party) gp=(g,gst,,g(st)d)gp=\left(g,g^{st},\dots,g^{(st)^d}\right). The parameters can be generated party after party, since g(st)i=(gsi)tig^{(st)^i}=\left(g^{s^i}\right)^{t^i}.

And it is worth noting that PLONK uses univariate KZG and plonk IOP, while vSQL uses multivariate KZG and sum-check protocol.

Bulletproofs: discrete-log

KZG requires trusted setup. Here we present Bulletproofs which has transparent setup. The goal of the prover is to convince the verifier that f(u)=vf(u)=v where f=i=0d+1fixiFp[X]f=\sum_{i=0}^{d+1}f_ix^i\in\mathbb{F}_p[X]. The setup phase is just a random gp=(gp0,0,,gp0,d)Ggp=(gp_{0,0},\dots,gp_{0,d})\in G and we assume d+1=2kd+1=2^k is some exponential of 22. Then the prover and verifier go through a interaction shown below:

ProverVerifiercomf=i=02k1gp0,ificommit(gp,f)comf,vround 1:  f=f0fL+u2k1fR,L=i=02k11gp0,i+2k1f0,i,R=i=2k12k1gp0,i2k1f0,i,vL=fL(u),vR=fR(u)L,R,vL,vR  “I verify f0(u)=v ”: v=?vL+vRu2k1f1rfL+fRgp1,rgp1(gp0,ir1gp0,i+2k1)i[0,2k1),r$Fp[X],v1rvL+vR,comf1LrRr1comfround 2:  f1fL+u2k2fR,L=i=02k21gp1,i+2k2f1,i,R=i=2k22k11gp1,i2k2f1,i,vL=fL(u),vR=fR(u)L,R,vL,vR“ I verify f1(u)=v1”: v1=?vL+vRu2k2.........round k:  fk1fL+ufR,L=gpk1,1fk1,0,R=gpk1,0fk1,1,vL=fL(u),vR=fR(u)L,R,vL,vR  “I verify fk1(u)=vk1 ”: vk1=?vL+vRufkFprfL+fRgpk,rgpk(gpk1,0r1gpk1,1),r$Fp[X],vkrvL+vR,comfkLrRr1comfk1final :  “ I verify fk=vk as a constant polynomial ”: comfk=?gpkvk\begin{align*} &\text{Prover} & & &\text{Verifier}\\ &\mathsf{com}_f=\prod_{i=0}^{2^k-1}gp_{0,i}^{f_i}\leftarrow\mathsf{commit}(gp, f) &\xrightarrow{\mathsf{com}_f,v} & &\\ \text{round }1:\; &f=f_0\rightarrow f_L+u^{2^{k-1}}f_R,L=\prod_{i=0}^{2^{k-1}-1}gp_{0,i+2^{k-1}}^{f_{0,i}},R=\prod_{i=2^{k-1}}^{2^k-1}gp_{0,i-2^{k-1}}^{f_{0,i}},v_L=f_L(u),v_R=f_R(u) &\xrightarrow{L,R,v_L,v_R} & &\;\text{``I verify } f_0(u)=v \text{ '': }v\stackrel{?}{=}v_L+v_Ru^{2^{k-1}}\\ &f_1\leftarrow rf_L+f_R &\xleftarrow{gp_1,r} & &gp_1\leftarrow (gp_{0,i}^{r^{-1}}gp_{0,i+2^{k-1}})_{i\in[0,2^{k-1})},r\xleftarrow{\$}\mathbb{F}_p[X],v_1\leftarrow rv_L+v_R,\mathsf{com}_{f_1}\leftarrow L^rR^{r^{-1}}\mathsf{com}_f\\ \text{round }2:\; &f_1\rightarrow f_L+u^{2^{k-2}}f_R,L=\prod_{i=0}^{2^{k-2}-1}gp_{1,i+2^{k-2}}^{f_{1,i}},R=\prod_{i=2^{k-2}}^{2^{k-1}-1}gp_{1,i-2^{k-2}}^{f_{1,i}},v_L=f_L(u),v_R=f_R(u) &\xrightarrow{L,R,v_L,v_R} & &\text{`` I verify } f_1(u)=v_1 \text{'': }v_1\stackrel{?}{=}v_L+v_Ru^{2^{k-2}}\\ &... &... & &...\\ \text{round }k:\; &f_{k-1}\rightarrow f_L+uf_R,L=gp_{k-1,1}^{f_{k-1,0}},R=gp_{k-1,0}^{f_{k-1,1}},v_L=f_L(u),v_R=f_R(u) &\xrightarrow{L,R,v_L,v_R} & &\;\text{``I verify } f_{k-1}(u)=v_{k-1} \text{ '': }v_{k-1}\stackrel{?}{=}v_L+v_Ru\\ &f_k\in\mathbb{F}_p\leftarrow rf_L+f_R &\xleftarrow{gp_k,r} & &gp_k\leftarrow (gp_{k-1,0}^{r^{-1}}gp_{k-1,1}),r\xleftarrow{\$}\mathbb{F}_p[X],v_k\leftarrow rv_L+v_R,\mathsf{com}_{f_k}\leftarrow L^rR^{r^{-1}}\mathsf{com}_{f_{k-1}}\\ \text{final }:\; & & & &\text{`` I verify } f_{k}=v_{k} \text{ as a constant polynomial '': }\mathsf{com}_{f_k}\stackrel{?}{=}gp_{k}^{v_k}\\ \end{align*}

The rr’s at every round is sampled randomly and independently. Then we apply Fiat-Shamir to the protocol. The gpgp’s should be computed by the verifier to prevent backdoor in parameters.

Time analysis

  • Setup: O(d)O(d) sampling
  • Commit: O(d)O(d) group exponentiations
  • Prover: O(d)O(d) group exponentiations
  • Verifier: O(d)O(d) group exponentiations

The proof size is O(logd)O(\log d) group elements, and the commitment size is O(1)O(1) group elements (this is the first commitment comf\mathsf{com}_f. Other commitments are computed by the verifier).

Soundness analysis.

Statistical soundness: we assume the prover does not know the correct vv. The final fkf_k is a multilinear polynomial of all the random rr’s, say fk=gf(r1,,rk)f_k=g_f(r_1,\dots,r_{k}) and the function gfg_f is deterministic. Note that every ff corresponds to a unique gfg_f.

So, conditioned on the prover does not know the correct vv but send a vvv^*\not=v instead, we can say v=f(u)v^*=f^*(u) for some fff^*\not=f. Thus by the Schwartz-Zippel lemma, we have

Prr1,,rkFp[fkvk=g(r1,,rk)g(r1,,rk)=0|vv]kp\mathbf{Pr}_{r_1,\dots,r_k\sim \mathbb{F}_p}\left[f^*_k-v_k=g^*(r_1,\dots,r_k)-g(r_1,\dots,r_k)=0\middle|v^*\not=v\right]\leq\frac{k}{p}

Since vkFpv_k\in\mathbb{F}_p, fk=vkf^*_k=v_k if and only if comfk=gpkvk\mathsf{com}_{f_k}=gp_{k}^{v_k}, so the soundness error is at most kp=logdp\frac{k}{p}=\frac{\log d}{p}.

Polynomial commitment based on linear codes

The motivations to develop code-based commitment scheme are:

  • post-quantum secure
  • no group exponentiations (only hash, addition and multiplication)
  • small global parameters

but the new commitment scheme has larger proof sizes; additionally, without the algebraic structure, it is not homomorphic and harder to aggregate.

The goal of the prover is to prove f(u)=vf(u)=v where fFp[X]f\in\mathbb{F}_p[X] is a degree-d1d-1 polynomial. The value f(u)f(u) equals a quadratic form

f(u)=[1uud1][f0,0f0,d1f1,0f1,d1fd1,0fd1,d1][1udu(d1)d]f(u)= \begin{bmatrix}1&u&\dots&u^{\sqrt{d}-1}\end{bmatrix} \begin{bmatrix}f_{0,0}&\cdots&f_{0,\sqrt{d}-1}\\f_{1,0}&\cdots&f_{1,\sqrt{d}-1}\\\vdots&\ddots&\vdots\\f_{\sqrt{d}-1,0}&\cdots&f_{\sqrt{d}-1,\sqrt{d}-1}\end{bmatrix} \begin{bmatrix}1\\ u^{\sqrt{d}}\\ \vdots\\ u^{(\sqrt{d}-1)\sqrt{d}}\end{bmatrix}

because f(u)=uTFu=i=0d1j=0d1fi,juid+jf(u)=\mathbf{u}^T\mathbf{F}\mathbf{u}'=\sum_{i=0}^{\sqrt{d}-1}\sum_{j=0}^{\sqrt{d}-1} f_{i,j}u^{i\sqrt{d}+j}.

Setup phase samples a random hash function. Then in commit phase, the prover encode each row of F\mathbf{F} with a [n,d][n,\sqrt{d}] linear code (this encoding is a public algorithm, e.g. Reed-Solomon code), represented by a matrix CFpd×n\mathbf{C}\in\mathbb{F}_p^{\sqrt{d}\times n}. The result is a matrix of d×n\sqrt{d}\times n:

P=[f0Cf1Cfd1C].\mathbf{P}=\begin{bmatrix}\mathbf{f}_0\mathbf{C}\\\mathbf{f}_1\mathbf{C}\\\vdots\\\mathbf{f}_{\sqrt{d}-1}\mathbf{C}\end{bmatrix}.

After encoding, use Merkle tree to generate the commitment with the hash function in the global parameters. The leaf nodes are the nn columns of the matrix P\mathbf{P}. The root hash is the commitment of the function.

Then the prover and verifier go through the following interaction to verify f(u)=xf(u)=x:

ProverVerifierrr$FpdwrTF  (originally we send encoded version rTP, this is for optimization)w  wwC is indeed a codewords  s$FpGenerate Merkle proof π that the s-th column of P equals to vFpdπ,v  verify the proof π, and verify rTv=ws, then repeat sampling s multiple timeswuTFw  wwC is indeed a codewords  s$FpGenerate Merkle proof π that the s-th column of P equals to vFpdπ,v  verify the proof π, and verify rTv=ws, then repeat sampling s multiple times  wu=?x\begin{align*} &\text{Prover}&&&\text{Verifier}\\ & &\xleftarrow{\mathbf{r}} & &\mathbf{r}\xleftarrow{\$}\mathbb{F}_p^{\sqrt{d}}\\ &\mathbf{w}\leftarrow\mathbf{r}^T\mathbf{F}\;(\text{originally we send encoded version }\mathbf{r}^T\mathbf{P}\text{, this is for optimization}) &\xrightarrow{\mathbf{w}} &\; &\mathbf{w}\leftarrow\mathbf{w}\mathbf{C}\text{ is indeed a codeword}\\ & &\xleftarrow{s} &\; &s\xleftarrow{\$}\mathbb{F}_p\\ &\text{Generate Merkle proof }\pi\text{ that the }s\text{-th column of }\mathbf{P}\text{ equals to }\mathbf{v}\in\mathbb{F}_p^{\sqrt{d}} &\xrightarrow{\pi,\mathbf{v}} &\; &\text{verify the proof }\pi\text{, and verify }\mathbf{r}^T\mathbf{v}=\mathbf{w}_s\text{, then repeat sampling }s\text{ multiple times}\\ &\mathbf{w}'\leftarrow\mathbf{u}^T\mathbf{F} &\xrightarrow{\mathbf{w}'} &\; &\mathbf{w}'\leftarrow\mathbf{w}'\mathbf{C}\text{ is indeed a codeword}\\ & &\xleftarrow{s} &\; &s\xleftarrow{\$}\mathbb{F}_p\\ &\text{Generate Merkle proof }\pi\text{ that the }s\text{-th column of }\mathbf{P}\text{ equals to }\mathbf{v}\in\mathbb{F}_p^{\sqrt{d}} &\xrightarrow{\pi,\mathbf{v}} &\; &\text{verify the proof }\pi\text{, and verify }\mathbf{r}^T\mathbf{v}=\mathbf{w}'_s\text{, then repeat sampling }s\text{ multiple times}\\ & & &\; &\mathbf{w}'\mathbf{u}'\stackrel{?}{=}x \end{align*}

Analysis of the protocol is as follows:

  • Keygen: O(1)O(1), transparent
  • Commit:
    • Encoding: O(dlogd)O(d \log d) field multiplications using Reed-Solomon code, O(d)O(d) using linear-time encodable code
    • Merkle tree: O(d)O(d) hashes, O(1)O(1) commitment size
  • Prover time: O(d)O(d) field multiplications
  • Proof size: O(d)O(\sqrt{d})
  • Verifier time: O(d)O(\sqrt{d})

Fast Reed-Solomon IOPP

Intro: Merkle trees for univariate poly-commitment

An intuitive attempt is to commit to a vector of evaluations of a given polynomial fFpd[X]f\in\mathbb{F}_p^{\leq d}[X]. The leaves of the tree are {f(x):xFp}\{f(x):x\in\mathbb{F}_p\} and the tree hashes every neighboring 22 nodes to form a new layer. When VV requires f(r)f(r), the prover sends the hash values along the path up to the root.

The Merkle tree for commitment requires O(pd)O(pd) field multiplication (using Qin-Horner method) to commit, and the proof size is O(logp)O(\log p) hash values. The verifier takes O(logp)O(\log p) hashes. The setup only generates a hash function, so it is transparent.

There are 2 problems:

  • The field may be very large; and the time is linear to the max degree.
  • The verifier cannot know if ff has degree at most dd.

Fix the Problem 1

FRI commitment uses a multiplicative subset of Fp\mathbb{F}_p: Ω={ωi:ωn=1,i=0,1,,n1}\Omega=\{\omega^i:\omega^n=1,i=0,1,\dots,n-1\}, for example, {1,3,9,27,1,3,9,27}\{1,3,9,27,-1,-3,-9,-27\} in F41\mathbb{F}_{41}. The leaves of the Merkle tree will be the values f(ωi)f(\omega^i).

We call the rate ρ=dn\rho=\frac{d}{n} the FRI blowup factor.

Fix the Problem 2

ProverVerifierf0=f,degf0k1,Ω0={1,ω,,ωn1},n=ρ1kcom0=MerkleCommit(f0Ω0)round 1:  f0(X)=f0,e(X2)+Xf0,o(X2)r1r1$Fpf1(Z)=f0,e(Z)+r1f0,o(Z),degf1k21,Ω1={x2:xΩ0}com1=MerkleCommit(f1Ω1)round 2:  f1(X)=f1,e(X2)+Xf1,o(X2)r2r2$Fpf2(Z)=f1,e(Z)+r2f1,o(Z),degf2k41,Ω2={x2:xΩ1}com2=MerkleCommit(f2Ω2)......round log2k:  ft1(X)=ft1,e(X2)+Xft1,o(X2)rtrt$Fpft(Z)=ft1,e(Z)+rtft1,o(Z),degft=0,Ωt={x2log2k:xΩ0}comt=ftΩt verify that ftΩt is a constant vectorquery :  对于每个 jq,打开从第 t=log2k 层到第 0 层的路径:πt,jqMerkleOpen(comt,jq){jq}q=1s随机选择 j1,,js[0,Ωt1]πt1,jq+,πt1,jqMerkleOpen(comt1,对应的两个索引)...所有打开值+路径验证每条路径的一致性;同时,对于第 t 层: ft(ωtjq) 是常数对于第 i 层: 检查fi+1(z)=?ri+1+x2xfi(x)+ri+1x2xfi(x)其中 z=x2,x=ωij,ωi 是第 i 层的生成元\begin{align*} &\text{Prover} & & &\text{Verifier}\\ &f_0=f,\deg f_0\leq k-1,\Omega_0=\{1,\omega,\dots,\omega^{n-1}\},n=\rho^{-1}k &\xrightarrow{\mathsf{com}_0=\mathsf{MerkleCommit}(f_0|_{\Omega_0})} & &\\ \text{round }1:\; &f_0(X)=f_{0,e}(X^2)+Xf_{0,o}(X^2) &\xleftarrow{r_1} & &r_1\xleftarrow{\$}\mathbb{F}_p\\ &f_1(Z)=f_{0,e}(Z)+r_1f_{0,o}(Z),\deg f_1\leq\frac{k}{2}-1,\Omega_1=\{x^2:x\in\Omega_0\} &\xrightarrow{\mathsf{com}_1=\mathsf{MerkleCommit}(f_1|_{\Omega_1})} & &\\ \text{round }2:\; &f_1(X)=f_{1,e}(X^2)+Xf_{1,o}(X^2) &\xleftarrow{r_2} & &r_2\xleftarrow{\$}\mathbb{F}_p\\ &f_2(Z)=f_{1,e}(Z)+r_2f_{1,o}(Z),\deg f_2\leq\frac{k}{4}-1,\Omega_2=\{x^2:x\in\Omega_1\} &\xrightarrow{\mathsf{com}_2=\mathsf{MerkleCommit}(f_2|_{\Omega_2})} & &\\ &... & & &...\\ \text{round }\log_2k:\; &f_{t-1}(X)=f_{t-1,e}(X^2)+Xf_{t-1,o}(X^2) &\xleftarrow{r_t} & &r_t\xleftarrow{\$}\mathbb{F}_p\\ &f_t(Z)=f_{t-1,e}(Z)+r_tf_{t-1,o}(Z),\deg f_t=0,\Omega_t=\{x^{2^{\log_2k}}:x\in\Omega_0\} &\xrightarrow{\mathsf{com}_t=f_t|_{\Omega_t}\ } & &\text{verify that }f_t|_{\Omega_t}\text{ is a constant vector}\\ \text{query }:\; &\text{对于每个 }j_q,\text{打开从第 }t=\log_2k\text{ 层到第 }0\text{ 层的路径:}\pi_{t,j_q}\leftarrow\text{MerkleOpen}(\mathsf{com}_t,j_q)&\xleftarrow{\{j_q\}_{q=1}^s} & &\text{随机选择 }j_1,\dots,j_s\in[0,|\Omega_t|-1]\\ &\\ &\pi_{t-1,j_q^+},\pi_{t-1,j_q^-}\leftarrow\text{MerkleOpen}(\mathsf{com}_{t-1},\text{对应的两个索引})\\ &... &\xrightarrow{\text{所有打开值}+\text{路径}} & &\text{验证每条路径的一致性;同时,}\\ &&&& \text{对于第 }t\text{ 层: }f_t(\omega_t^{j_q})\text{ 是常数}\\ &&&& \text{对于第 }i\text{ 层: 检查}f_{i+1}(z)\stackrel{?}{=}\frac{r_{i+1}+x}{2x}f_i(x)+\frac{r_{i+1}-x}{-2x}f_i(-x)\\ &&&& \text{其中 }z=x^2,x=\omega_i^{j},\omega_i\text{ 是第 }i\text{ 层的生成元}\\ \end{align*}

Remark.

  • It is easy from fiΩif_i|_{\Omega_i} to fi+1Ωi+1f_{i+1}|_{\Omega_{i+1}}. This is because fi+1(x2)=fi,e(x2)+ri+1fi,o(x2)=fi(x)+fi(x)2+ri+1fi(x)fi(x)2xf_{i+1}(x^2)=f_{i,e}(x^2)+r_{i+1}f_{i,o}(x^2)=\frac{f_i(x)+f_i(-x)}{2}+r_{i+1}\frac{f_i(x)-f_i(-x)}{2x}. Also, the verifying process relies on this equation.
  • To analysis the soundness, we introduce the relative Hamming distance HamΩ(f,g)={xΩ:f(x)g(x)}Ω\mathsf{Ham}_{\Omega}(f,g)=\frac{|\{x\in\Omega:f(x)\not=g(x)\}|}{|\Omega|} and δ=minhFpk1[X](HamΩ(f,h))\delta=\min_{h\in\mathbb{F}_p^{\leq k-1}[X]}\left(\mathsf{Ham}_{\Omega}(f,h)\right), which is the distance on Ω\Omega of ff to the closest degree-(k1)(k-1) polynomial.
  • We consider ff such that δ1ρ\delta\leq 1-\sqrt{\rho}, which is to say, the ff is far from any degree-(k1)(k-1) polynomial.
  • A cheating prover has a high (>k1> k-1) degree polynomial ff. In case the prover is accepted, either it folds incorrectly, or it folds correctly and is lucky to have those rir_i’s that reduce the degree to 00 eventually. In the first case, the accept probability is (1δ)t\left(1-\delta\right)^t; in the second case, the accept probability is at most kp\frac{k}{p}. As a result, to reach an accept probability 2λ2^{-\lambda} (λ\lambda is the security parameter), ss should be Ω(λlogρ1)\Omega\left(\frac{\lambda}{\log\rho^{-1}}\right).

(The security proof is problematic.)

Polynomial commitment from FRI

The FRI introduces another two problems:

  • Prover has only committed to evaluations on a subset ΩFp\Omega\subset\mathbb{F}_p.
  • Verifier only knows that ff is close to a low-degree polynomial (in the sense of Hamming distance), but not necessarily a low-degree polynomial.

There is an attack to the first problem: the prover can commit to a polynomial gg that agrees with ff on TΩT\subset\Omega with much lower degree (T=k|T|=k). Then δ<1ρ<1ρ\delta<1-\rho<1-\sqrt{\rho} and the soundness is broken.

Then to confirm that f(r)=vf(r)=v where fFpd[X]f\in\mathbb{F}_p^{\leq d}[X], the prover applies FRI on the polynomial (f(x)v)/(xr)(f(x)-v)/(x-r), which has degree at most d1d-1.

Fiat-Shamir transform

Definition. (Interactive Security) A poly-commitment scheme runs at λ\lambda bits of interactive security if and only if: assume PP cannot find a collision of the hash function in the global parameters, then for every PP^*, the probability that PP^* can make the verifier accept a false claim is at most 2λ2^{-\lambda}.

To find out if a challenge is lucky, the prover should interact with the verifier at least 2λ2^\lambda times in average. It is unlikely that VV continues to interact after rejecting the same prover so many rounds. So following is the

Definition. (Non-interactive security) A poly-commitment scheme runs at λ\lambda bits of non-interactive security if and only if: for every PP^* willing to compute 2k2^k hashs, the probability that PP^* can make the verifier accept a false claim is at most 2kλ2^{k-\lambda}.

In this scheme, a lying PP can propose the grinding attack silently, without interacting. This definition is weaker than the interactive security, i.e., if a prover breaks the interactive security of one interactive protocol, then it can also break the non-interactive security of the Fiat-Shamir transform of that protocol.

We show that Fiat-Shamir transform may be insecure. Consider a protocol of the empty language. In this protocol, PP sends a nonce, and then VV sends a random bit rr, and accepts iff r=1r=1. The VV accepts iff every round it accepts, so the soundness error is 2λ2^{-\lambda} with λ\lambda rounds. However, the Fiat-Shamir transform of this protocol is insecure, since the prover can grind for a nonce 2 times per round in average, in order to find a nonce that leads to r=1r=1 for every round. The cost is 2λ2\lambda in average, which is much smaller than 2λ2^\lambda and the protocol does not satisfy the non-interactive security.

Applying Fiat-Shamir to a many-round interactive protocol can lead to a huge loss in security, whereby the resulting non-interactive protocol is totally insecure. So we need “round-by-round” soundness to describe the security of an interactive protocol, which means that for every prover in every round, if the prover is not “lucky” enough to make the verifier accept, then the probability that the prover can make the verifier accept in the next round is at most 2λ2^{-\lambda}.

The sum-check protocol is round-by-round sound, so its Fiat-Shamir transform is secure.