arnaucube / go-snark-study

zkSNARK library implementation in Go from scratch (compiler, setup, prover, verifier)
GNU General Public License v3.0
255 stars 57 forks source link

help #2

Closed whiteJadeSoup closed 5 years ago

whiteJadeSoup commented 5 years ago

where are these parameters of the bn128 curve from? any references? thank you for your help.

arnaucube commented 5 years ago

The bn128 parameters are from zcash libsnark: https://github.com/zcash/zcash/tree/master/src/snark/libsnark/algebra/curves/alt_bn128

whiteJadeSoup commented 5 years ago

thanks

whiteJadeSoup commented 5 years ago

sorry to bother you。 could I ask a stupid question? Any specification about the process of setup、proof and verify? I've studied through the Pinocchio paper (aka PGHR13), but I am confused about your code. such as kbeta,kgamma、rhoA and other stuff。Looks like magic to me.

whiteJadeSoup commented 5 years ago

And in PGHR13 implementation, it looks like that they use a symmetric bilinear map, not an asymmetric bilinear map.

arnaucube commented 5 years ago

hi, There is not much literature about snarks out there, I've done this to learn about it reading multiple papers and articles, and also the code of some of the existing implementations, but I hope to found more documents in near future. About the rhoA, rhoB, etc stuff appears also in this document https://blog.coinfabrik.com/wp-content/uploads/2017/03/zkSNARK-explained_basic_principles.pdf For me this document was the more clear about all the process, from trusted setup to verification of proofs. Hope that also works for you :) If you want to talk more deeply or share any more doubts (probably I'll not able to answer them.. but we can research together) can send me an email Best regards

whiteJadeSoup commented 5 years ago

thank you,genuinely