Core types and operations for the GROTH16 snark.
More...
#include <groth16_snark.hpp>
|
using | proving_key = libsnark::r1cs_gg_ppzksnark_proving_key< ppT > |
|
using | verification_key = libsnark::r1cs_gg_ppzksnark_verification_key< ppT > |
|
using | keypair = libsnark::r1cs_gg_ppzksnark_keypair< ppT > |
|
using | proof = libsnark::r1cs_gg_ppzksnark_proof< ppT > |
|
|
static keypair | generate_setup (const libsnark::protoboard< libff::Fr< ppT >> &pb) |
| Run the trusted setup and return the keypair for the circuit. More...
|
|
static proof | generate_proof (const proving_key &proving_key, const libsnark::protoboard< libff::Fr< ppT >> &pb) |
| Generate the proof (from the values set to the protoboard) More...
|
|
static proof | generate_proof (const proving_key &proving_key, const libsnark::r1cs_primary_input< libff::Fr< ppT >> &primary_input, const libsnark::r1cs_auxiliary_input< libff::Fr< ppT >> auxiliary_input) |
| Generate the proof (from given primary and auxiliary values) More...
|
|
static bool | verify (const libsnark::r1cs_primary_input< libff::Fr< ppT >> &primary_inputs, const proof &proof, const verification_key &verification_key) |
| Verify proof. More...
|
|
static void | verification_key_write_json (const verification_key &, std::ostream &) |
| Write verification as json. More...
|
|
static void | verification_key_write_bytes (const verification_key &, std::ostream &) |
| Write verification key as bytes. More...
|
|
static void | verification_key_read_bytes (verification_key &, std::istream &) |
| Read a verification key as bytes. More...
|
|
static void | proving_key_write_bytes (const proving_key &, std::ostream &) |
| Write proving key as bytes. More...
|
|
static void | proving_key_read_bytes (proving_key &, std::istream &) |
| Read proving key as bytes. More...
|
|
static void | proof_write_json (const proof &, std::ostream &) |
| Write proof as json. More...
|
|
static void | proof_write_bytes (const proof &, std::ostream &) |
| Write proof as bytes. More...
|
|
static void | proof_read_bytes (proof &, std::istream &) |
| Read proof as bytes. More...
|
|
static void | keypair_write_bytes (const keypair &, std::ostream &) |
| Write a keypair as bytes. More...
|
|
static void | keypair_read_bytes (keypair &, std::istream &) |
| Read a keypair from a stream. More...
|
|
|
static const std::string | name |
|
template<typename ppT>
class libzeth::groth16_snark< ppT >
Core types and operations for the GROTH16 snark.
Definition at line 15 of file groth16_snark.hpp.
◆ keypair
◆ proof
◆ proving_key
◆ verification_key
◆ generate_proof() [1/2]
Generate the proof (from the values set to the protoboard)
◆ generate_proof() [2/2]
template<typename ppT >
static proof libzeth::groth16_snark< ppT >::generate_proof |
( |
const proving_key & |
proving_key, |
|
|
const libsnark::r1cs_primary_input< libff::Fr< ppT >> & |
primary_input, |
|
|
const libsnark::r1cs_auxiliary_input< libff::Fr< ppT >> |
auxiliary_input |
|
) |
| |
|
static |
Generate the proof (from given primary and auxiliary values)
◆ generate_setup()
Run the trusted setup and return the keypair for the circuit.
◆ keypair_read_bytes()
Read a keypair from a stream.
◆ keypair_write_bytes()
Write a keypair as bytes.
◆ proof_read_bytes()
◆ proof_write_bytes()
◆ proof_write_json()
◆ proving_key_read_bytes()
Read proving key as bytes.
◆ proving_key_write_bytes()
Write proving key as bytes.
◆ verification_key_read_bytes()
Read a verification key as bytes.
◆ verification_key_write_bytes()
Write verification key as bytes.
◆ verification_key_write_json()
Write verification as json.
◆ verify()
◆ name
String name of this snark, corresponding to <SNARK> in the ZETH_SNARK_<SNARK> configuration variable.
Definition at line 25 of file groth16_snark.hpp.
The documentation for this class was generated from the following file: