nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType > Class Template Reference

#include <sp_pcd_circuits.hpp>

+ Collaboration diagram for nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >:

Public Types

typedef CurveType::scalar_field_type FieldType
 

Public Member Functions

void generate_r1cs_constraints ()
 
void generate_r1cs_witness (const r1cs_ppzksnark_verification_key< other_curve< CurveType >> &translation_step_pcd_circuit_vk, const r1cs_pcd_compliance_predicate_primary_input< FieldType > &compliance_predicate_primary_input, const r1cs_pcd_compliance_predicate_auxiliary_input< FieldType > &compliance_predicate_auxiliary_input, const std::vector< r1cs_ppzksnark_proof< other_curve< CurveType >>> &incoming_proofs)
 
r1cs_auxiliary_input< FieldTypeget_auxiliary_input () const
 
r1cs_constraint_system< FieldTypeget_circuit () const
 
r1cs_primary_input< FieldTypeget_primary_input () const
 
 sp_compliance_step_pcd_circuit_maker (const r1cs_pcd_compliance_predicate< FieldType > &compliance_predicate)
 

Static Public Member Functions

static std::size_t field_capacity ()
 
static std::size_t field_logsize ()
 
static std::size_t input_capacity_in_bits ()
 
static std::size_t input_size_in_bits ()
 
static std::size_t input_size_in_elts ()
 

Public Attributes

variable< FieldTypearity
 
std::shared_ptr< block_variable< FieldType > > block_for_outgoing_message
 
std::vector< block_variable< FieldType > > blocks_for_incoming_messages
 
blueprint< FieldTypebp
 
r1cs_pcd_compliance_predicate< FieldTypecompliance_predicate
 
std::shared_ptr< component_from_r1cs< FieldType > > compliance_predicate_as_component
 
blueprint_variable_vector< FieldTypecp_witness
 
std::vector< crh_with_field_out_component< FieldType > > hash_incoming_messages
 
std::shared_ptr< crh_with_field_out_component< FieldType > > hash_outgoing_message
 
std::vector< blueprint_variable_vector< FieldType > > incoming_message_payloads
 
std::vector< variable< FieldType > > incoming_message_types
 
std::vector< blueprint_variable_vector< FieldType > > incoming_message_vars
 
std::vector< blueprint_variable_vector< FieldType > > incoming_messages_bits
 
blueprint_variable_vector< FieldTypelocal_data
 
blueprint_variable_vector< FieldTypeoutgoing_message_bits
 
blueprint_variable_vector< FieldTypeoutgoing_message_payload
 
variable< FieldTypeoutgoing_message_type
 
blueprint_variable_vector< FieldTypeoutgoing_message_vars
 
std::vector< blueprint_variable_vector< FieldType > > padded_translation_step_vk_and_incoming_messages_digests
 
blueprint_variable_vector< FieldTypepadded_translation_step_vk_and_outgoing_message_digest
 
std::vector< r1cs_ppzksnark_proof_variable< CurveType > > proof
 
blueprint_variable_vector< FieldTypesp_compliance_step_pcd_circuit_input
 
std::shared_ptr< r1cs_ppzksnark_verification_key_variable< CurveType > > sp_translation_step_vk
 
std::vector< blueprint_variable_vector< FieldType > > sp_translation_step_vk_and_incoming_message_payload_digest_bits
 
std::vector< blueprint_variable_vector< FieldType > > sp_translation_step_vk_and_incoming_message_payload_digests
 
blueprint_variable_vector< FieldTypesp_translation_step_vk_bits
 
std::vector< multipacking_component< FieldType > > unpack_incoming_messages
 
std::shared_ptr< multipacking_component< FieldType > > unpack_outgoing_message
 
std::vector< multipacking_component< FieldType > > unpack_sp_translation_step_vk_and_incoming_message_payload_digests
 
variable< FieldTypeverification_result
 
std::vector< blueprint_variable_vector< FieldType > > verifier_input
 
std::vector< r1cs_ppzksnark_verifier_component< CurveType > > verifiers
 
variable< FieldTypezero
 

Detailed Description

template<typename CurveType>
class nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >

A compliance-step PCD circuit.

The circuit is an R1CS that checks compliance (for the given compliance predicate) and validity of previous proofs.

Member Typedef Documentation

◆ FieldType

template<typename CurveType >
typedef CurveType::scalar_field_type nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::FieldType

Constructor & Destructor Documentation

◆ sp_compliance_step_pcd_circuit_maker()

Member Function Documentation

◆ field_capacity()

template<typename CurveType >
std::size_t nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::field_capacity
static

◆ field_logsize()

template<typename CurveType >
std::size_t nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::field_logsize
static

◆ generate_r1cs_constraints()

template<typename CurveType >
void nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::generate_r1cs_constraints

◆ generate_r1cs_witness()

template<typename CurveType >
void nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::generate_r1cs_witness ( const r1cs_ppzksnark_verification_key< other_curve< CurveType >> &  translation_step_pcd_circuit_vk,
const r1cs_pcd_compliance_predicate_primary_input< FieldType > &  compliance_predicate_primary_input,
const r1cs_pcd_compliance_predicate_auxiliary_input< FieldType > &  compliance_predicate_auxiliary_input,
const std::vector< r1cs_ppzksnark_proof< other_curve< CurveType >>> &  incoming_proofs 
)

◆ get_auxiliary_input()

template<typename CurveType >
r1cs_auxiliary_input< typename CurveType::scalar_field_type > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::get_auxiliary_input

◆ get_circuit()

template<typename CurveType >
r1cs_constraint_system< typename CurveType::scalar_field_type > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::get_circuit

◆ get_primary_input()

template<typename CurveType >
r1cs_primary_input< typename CurveType::scalar_field_type > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::get_primary_input

◆ input_capacity_in_bits()

template<typename CurveType >
std::size_t nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::input_capacity_in_bits
static

◆ input_size_in_bits()

template<typename CurveType >
std::size_t nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::input_size_in_bits
static

◆ input_size_in_elts()

template<typename CurveType >
std::size_t nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::input_size_in_elts
static

Member Data Documentation

◆ arity

template<typename CurveType >
variable<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::arity

◆ block_for_outgoing_message

template<typename CurveType >
std::shared_ptr<block_variable<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::block_for_outgoing_message

◆ blocks_for_incoming_messages

template<typename CurveType >
std::vector<block_variable<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::blocks_for_incoming_messages

◆ bp

template<typename CurveType >
blueprint<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::bp

◆ compliance_predicate

template<typename CurveType >
r1cs_pcd_compliance_predicate<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::compliance_predicate

◆ compliance_predicate_as_component

template<typename CurveType >
std::shared_ptr<component_from_r1cs<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::compliance_predicate_as_component

◆ cp_witness

template<typename CurveType >
blueprint_variable_vector<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::cp_witness

◆ hash_incoming_messages

template<typename CurveType >
std::vector<crh_with_field_out_component<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::hash_incoming_messages

◆ hash_outgoing_message

template<typename CurveType >
std::shared_ptr<crh_with_field_out_component<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::hash_outgoing_message

◆ incoming_message_payloads

template<typename CurveType >
std::vector<blueprint_variable_vector<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::incoming_message_payloads

◆ incoming_message_types

template<typename CurveType >
std::vector<variable<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::incoming_message_types

◆ incoming_message_vars

template<typename CurveType >
std::vector<blueprint_variable_vector<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::incoming_message_vars

◆ incoming_messages_bits

template<typename CurveType >
std::vector<blueprint_variable_vector<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::incoming_messages_bits

◆ local_data

template<typename CurveType >
blueprint_variable_vector<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::local_data

◆ outgoing_message_bits

template<typename CurveType >
blueprint_variable_vector<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::outgoing_message_bits

◆ outgoing_message_payload

template<typename CurveType >
blueprint_variable_vector<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::outgoing_message_payload

◆ outgoing_message_type

template<typename CurveType >
variable<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::outgoing_message_type

◆ outgoing_message_vars

template<typename CurveType >
blueprint_variable_vector<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::outgoing_message_vars

◆ padded_translation_step_vk_and_incoming_messages_digests

template<typename CurveType >
std::vector<blueprint_variable_vector<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::padded_translation_step_vk_and_incoming_messages_digests

◆ padded_translation_step_vk_and_outgoing_message_digest

template<typename CurveType >
blueprint_variable_vector<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::padded_translation_step_vk_and_outgoing_message_digest

◆ proof

template<typename CurveType >
std::vector<r1cs_ppzksnark_proof_variable<CurveType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::proof

◆ sp_compliance_step_pcd_circuit_input

template<typename CurveType >
blueprint_variable_vector<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::sp_compliance_step_pcd_circuit_input

◆ sp_translation_step_vk

template<typename CurveType >
std::shared_ptr<r1cs_ppzksnark_verification_key_variable<CurveType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::sp_translation_step_vk

◆ sp_translation_step_vk_and_incoming_message_payload_digest_bits

template<typename CurveType >
std::vector<blueprint_variable_vector<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::sp_translation_step_vk_and_incoming_message_payload_digest_bits

◆ sp_translation_step_vk_and_incoming_message_payload_digests

template<typename CurveType >
std::vector<blueprint_variable_vector<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::sp_translation_step_vk_and_incoming_message_payload_digests

◆ sp_translation_step_vk_bits

template<typename CurveType >
blueprint_variable_vector<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::sp_translation_step_vk_bits

◆ unpack_incoming_messages

template<typename CurveType >
std::vector<multipacking_component<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::unpack_incoming_messages

◆ unpack_outgoing_message

template<typename CurveType >
std::shared_ptr<multipacking_component<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::unpack_outgoing_message

◆ unpack_sp_translation_step_vk_and_incoming_message_payload_digests

template<typename CurveType >
std::vector<multipacking_component<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::unpack_sp_translation_step_vk_and_incoming_message_payload_digests

◆ verification_result

template<typename CurveType >
variable<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::verification_result

◆ verifier_input

template<typename CurveType >
std::vector<blueprint_variable_vector<FieldType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::verifier_input

◆ verifiers

template<typename CurveType >
std::vector<r1cs_ppzksnark_verifier_component<CurveType> > nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::verifiers

◆ zero

template<typename CurveType >
variable<FieldType> nil::crypto3::zk::snark::sp_compliance_step_pcd_circuit_maker< CurveType >::zero

The documentation for this class was generated from the following file: