您当前的位置: 首页 >  ar

mutourend

暂无认证

  • 2浏览

    0关注

    661博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

zk-SNARKs中input和witness size的权衡

mutourend 发布时间:2019-06-19 15:10:56 ,浏览量:2

主要来源 https://blog.ethereum.org/2016/12/05/zksnarks-in-a-nutshell/ 中“Tradeoff between Input and Witness Size”段落

论文GGPR12中,生成的proof只有7个elements of a group. Verifier主要需要计算pairing等式的成立(如 W := E(w(s)),W’ := E(α w(s)),则e(W’, E(1)) = e(E(α w(s)), E(1)) = e(g,g)αw(s) = e(gw(s),gα) = e(E(w(s)), E(α)) = e(W, E(α)))以及计算E(vin(s))。 计算E(vin(s))的时效与input size的大小呈线性关系。 在verification时,witness string size和验证QSP都不会有任何影响。 也就是说,因为SNARK在做verify时仅仅是check多项式at a single point而不是计算整个多项式,所以SNARK在verify复杂问题和简单问题都需要相同的时效。

影响SNARK verification时效的因素主要有:

  • the level of security(如 the size of the group)
  • the maximum size for the inputs

所以,降低input size的大小,转移input的信息至witness,是一种可行的办法: 在这里插入图片描述

关注
打赏
1664532908
查看更多评论
立即登录/注册

微信扫码登录

0.0433s