Zeth - Zerocash on Ethereum
0.8
Reference implementation of the Zeth protocol by Clearmatics
|
#include <circuit_wrapper.hpp>
Public Types | |
using | Field = libff::Fr< ppT > |
using | joinsplit_type = joinsplit_gadget< Field, HashT, HashTreeT, NumInputs, NumOutputs, TreeDepth > |
using | input_hasher_type = mimc_input_hasher< Field, HashTreeT > |
Public Member Functions | |
circuit_wrapper () | |
circuit_wrapper (const circuit_wrapper &)=delete | |
circuit_wrapper & | operator= (const circuit_wrapper &)=delete |
snarkT::keypair | generate_trusted_setup () const |
const libsnark::r1cs_constraint_system< Field > & | get_constraint_system () const |
extended_proof< ppT, snarkT > | prove (const Field &root, const std::array< joinsplit_input< Field, TreeDepth >, NumInputs > &inputs, const std::array< zeth_note, NumOutputs > &outputs, const bits64 &vpub_in, const bits64 &vpub_out, const bits256 &h_sig_in, const bits256 &phi_in, const typename snarkT::proving_key &proving_key, std::vector< Field > &out_public_data) const |
const std::vector< Field > & | get_last_assignment () const |
Wrapper around the joinsplit circuit, using parameterized schemes for hashing, and a snark scheme for generating keys and proofs.
Definition at line 27 of file circuit_wrapper.hpp.
using libzeth::circuit_wrapper< HashT, HashTreeT, ppT, snarkT, NumInputs, NumOutputs, TreeDepth >::Field = libff::Fr<ppT> |
Definition at line 30 of file circuit_wrapper.hpp.
using libzeth::circuit_wrapper< HashT, HashTreeT, ppT, snarkT, NumInputs, NumOutputs, TreeDepth >::input_hasher_type = mimc_input_hasher<Field, HashTreeT> |
Definition at line 40 of file circuit_wrapper.hpp.
using libzeth::circuit_wrapper< HashT, HashTreeT, ppT, snarkT, NumInputs, NumOutputs, TreeDepth >::joinsplit_type = joinsplit_gadget< Field, HashT, HashTreeT, NumInputs, NumOutputs, TreeDepth> |
Definition at line 39 of file circuit_wrapper.hpp.
libzeth::circuit_wrapper< HashT, HashTreeT, ppT, snarkT, NumInputs, NumOutputs, TreeDepth >::circuit_wrapper | ( | ) |
|
delete |
snarkT::keypair libzeth::circuit_wrapper< HashT, HashTreeT, ppT, snarkT, NumInputs, NumOutputs, TreeDepth >::generate_trusted_setup | ( | ) | const |
const libsnark::r1cs_constraint_system<Field>& libzeth::circuit_wrapper< HashT, HashTreeT, ppT, snarkT, NumInputs, NumOutputs, TreeDepth >::get_constraint_system | ( | ) | const |
const std::vector<Field>& libzeth::circuit_wrapper< HashT, HashTreeT, ppT, snarkT, NumInputs, NumOutputs, TreeDepth >::get_last_assignment | ( | ) | const |
|
delete |
extended_proof<ppT, snarkT> libzeth::circuit_wrapper< HashT, HashTreeT, ppT, snarkT, NumInputs, NumOutputs, TreeDepth >::prove | ( | const Field & | root, |
const std::array< joinsplit_input< Field, TreeDepth >, NumInputs > & | inputs, | ||
const std::array< zeth_note, NumOutputs > & | outputs, | ||
const bits64 & | vpub_in, | ||
const bits64 & | vpub_out, | ||
const bits256 & | h_sig_in, | ||
const bits256 & | phi_in, | ||
const typename snarkT::proving_key & | proving_key, | ||
std::vector< Field > & | out_public_data | ||
) | const |