dev0x1 / arkwork-examples

arkwork-rs library zk-SNARKS circuit examples

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

arkwork-rs library examples

Overview

Few basic examples showing how to use arkwork-rs libraries to construct zk-SNARKS circuits. Examples use Groth16 and Marlin zk-SNARKs system.

Examples are:

  • Prover claims that she knows "Two values a and b such that a * b == c where c is a public value".
  • Prover claims that she knows "A x such that x^3 + x + 5 == 35". This example is based on Christian Lundkvist's libsnark tutorial.
    • Implemented as arkworks circuit style, also as arkworks gadget style.
  • Example demonstrating concept of universal SRS(setup parameters) in Marlin, here we use 2 circuits with same setup parameter.

Build and Run

cargo build
cargo test

About

arkwork-rs library zk-SNARKS circuit examples

License:Apache License 2.0


Languages

Language:Rust 100.0%