Skip to content

GRT-Ltd/groth16

 
 

Repository files navigation

ark-groth16

The arkworks ecosystem consist of Rust libraries for designing and working with zero knowledge succinct non-interactive arguments (zkSNARKs). This repository contains an efficient implementation of the zkSNARK of [Groth16].

This library is released under the MIT License and the Apache v2 License (see License).

WARNING: This is an academic proof-of-concept prototype, and in particular has not received careful code review. This implementation is NOT ready for production use.

Build guide (modified by GRT )

The library compiles on the stable toolchain of the Rust compiler. To install the latest version of Rust, first install rustup by following the instructions here, or via your platform's package manager. Once rustup is installed, install the Rust toolchain by invoking:

rustup install stable

After that, use cargo (the standard Rust build tool) to build the library:

git clone https://github.com/GRT-Ltd/groth16.git

Run bench by cpu

cargo bench

Run bench by gpu

cargo bench --features "cuda"

Lastly, this library is instrumented with profiling infrastructure that prints detailed traces of execution time. To enable this, compile with

Run bench by cpu for tracking logs

cargo bench --features "print-trace"

Run bench by gpu for tracking logs

cargo bench --features "cuda print-trace"

Add CUDA code to FFT, MSM, tracking logs, detailed code can be found in the project is as follows:

// GRT modify

License

This library is licensed under either of the following licenses, at your discretion.

Unless you explicitly state otherwise, any contribution submitted for inclusion in this library by you shall be dual licensed as above (as defined in the Apache v2 License), without any additional terms or conditions.

Acknowledgements

This work was supported by: a Google Faculty Award; the National Science Foundation; the UC Berkeley Center for Long-Term Cybersecurity; and donations from the Ethereum Foundation, the Interchain Foundation, and Qtum.

An earlier version of this library was developed as part of the paper "ZEXE: Enabling Decentralized Private Computation".

About

A Rust implementation of the Groth16 zkSNARK

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Cuda 53.1%
  • C++ 24.1%
  • Rust 22.3%
  • Other 0.5%