libsnark
libsnark copied to clipboard
C++ library for zkSNARKs
``` → CXX=clang make all CURVE=BN128 LOWMEM=1 DEBUG=1 clang -o src/gadgetlib2/examples/tutorial.o src/gadgetlib2/examples/tutorial.cpp -c -MMD -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wno-comment -Wfatal-errors -O2 -march=native -mtune=native -DUSE_ASM -DMONTGOMERY_OUTPUT -DCURVE_BN128 -Idepinst/include -Isrc -DBN_SUPPORT_SNARK -DLOWMEM...
Currently we have a bunch of #define flags fed by the makefile as `g++ -D...` arguments during the build. But after we build a library file (`libsnark.a` or `libsnark.so`), the...
(bn128 again) If you attempt `e(P, Q)` where `P` or `Q` are points at infinity, an internal assumption (during the miller loop if I remember correctly) that the points are...
I would like to try out a different Barreto-Naehrig pairing. How would I go about computing the curve parameters used in libsnark such as the Frobenius_coeffs, the ate_loop_count, the final_exponent,...
Recent research (https://ellipticnews.wordpress.com/2016/05/02/kim-barbulescu-variant-of-the-number-field-sieve-to-compute-discrete-logarithms-in-finite-fields/) suggests that a 448-bit field size may be necessary to achieve sufficient security. In any case, it may be necessary to change BN128, and echoing #27 make...
For us, ALT_BN128 r1cs proofs are 304 bytes in size, with point compression and binary serialization enabled.
From what I remember, these formats are different, which is a roadblock for using both at the same time in different contexts.
For example: ```c++ alt_bn128_G1 alt_bn128_G1::operator-() const { return alt_bn128_G1(this->X, -(this->Y), this->Z); } ``` `-G1::zero()` thus has an invalid jacobian representation. I doubt any code outside of this will be reading...
Currently the binary serialization format (BINARY_OUTPUT) is not compatible across machine with different word size. This is documented, but should be fixed. The format may be endianness-dependent as well. One...
I'm running Debian x86_64 trying to get libsnark to install completely, but been unable to get past this point ? Any suggestions are appreciated. Mel