|Thomas Kerber 7b2329c64b Disable print statement if profiling info is inhibited.||1 year ago|
|depends||2 years ago|
|libff||1 year ago|
|.gitignore||2 years ago|
|.gitmodules||2 years ago|
|.travis.yml||2 years ago|
|AUTHORS||2 years ago|
|CMakeLists.txt||1 year ago|
|LICENSE||3 years ago|
|README.md||1 year ago|
The directory structure is as follows:
The libsnark library currently provides three options:
an instantiation based on an Edwards curve, providing 80 bits of security.
an instantiation based on a Barreto-Naehrig curve, providing 128
bits of security. The underlying curve implementation is
[ate-pairing], which has incorporated our patch that changes the
BN curve to one suitable for SNARK applications.
This implementation uses dynamically-generated machine code for the curve arithmetic. Some modern systems disallow execution of code on the heap, and will thus block this implementation.
For example, on Fedora 20 at its default settings, you will get the error
zmInit ERR:can't protect when running this code. To solve this,
sudo setsebool -P allow_execheap 1 to allow execution,
make CURVE=ALT_BN128 instead.
an alternative to
bn128, somewhat slower but avoids dynamic code generation.
bn128 requires an x86-64 CPU while the other curve choices
should be architecture-independent.
The library has the following dependencies:
The library has been tested on Linux, but it is compatible with Windows and Mac OS X.
On Ubuntu 14.04 LTS:
sudo apt-get install build-essential git libboost-all-dev cmake libgmp3-dev libssl-dev libprocps3-dev pkg-config
Fetch dependencies from their GitHub repos:
git submodule init && git submodule update
To compile, starting at the project root directory, create the build directory and Makefile:
mkdir build && cd build && cmake ..
Optionally, you can specify the install location by providing the desired install path prefix:
cmake .. -DCMAKE_INSTALL_PREFIX=/install/path
Then, to compile and install the library, run this within the build directory:
make make install
This will install
/install/path/lib; so your application should be linked using
-L/install/path/lib -lff. It also installs the requisite headers into
/install/path/include; so your application should be compiled using
To execute the tests for this library, run: