flyingnobita / semacaulk

Gas-efficient and blazing fast proving for private signaling

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Semacaulk

Semacaulk is a custom prover and verifier of set membership proofs which uses an on-chain polynomial commitment to enable cheap insertions, and techniques which make verification no more expensive than verifying a Groth16 proof.

For more information, please refer to this document. More documentation will be written and released soon.

Quick start

  1. Install Rust using these instructions.

  2. Install Foundry using these instructions.

  3. Clone this repository.

git clone https://github.com/geometryresearch/semacaulk.git && \
cd semacaulk
  1. Build the contracts
./build_contracts.sh
  1. Run tests
cargo test

Demo

The setup files 11.hex and lagrangeComms_11 are already in the repository. To run a demo of Semacaulk with a maximum capacity of 2 ^ 11 = 2048, first build the demo executable:

cargo build --release

Run the demo:

./target/release/demo 11 11.hex lagrangeComms_11

To run a demo with a different maximum capacity, first generate the .hex file with export-ptau-points, then use the setup executable to generate the lagrangeComms_n file. For example for a maximum capacity of 2 ^ 12:

./target/release/demo 12 12.hex lagrangeComms_12

Now, run:

./target/release/demo 12 12.hex lagrangeComms_12

A future release will integrate implement the functionality of export-ptau-points into the setup executable, so a separate step will not be needed.

About

Gas-efficient and blazing fast proving for private signaling


Languages

Language:Solidity 67.5%Language:Rust 32.4%Language:Shell 0.0%Language:Makefile 0.0%Language:Nix 0.0%