sha256_component.hpp
Go to the documentation of this file.
250 sha256_two_to_one_hash_component<FieldType> f(bp, hashes::sha2<256>::block_bits, input_variable,
276 std::vector<std::shared_ptr<sha256_compression_function_component<FieldType>>> blocks_components;
Definition: hash_io.hpp:84
std::size_t block_size
Definition: hash_io.hpp:86
void generate_r1cs_witness(const std::vector< bool > &contents)
Definition: hash_io.hpp:116
blueprint_variable_vector< FieldType > bits
Definition: hash_io.hpp:87
Definition: blueprint_linear_combination.hpp:115
Definition: blueprint_variable.hpp:57
void allocate(blueprint< field_type > &bp, const std::size_t n)
Definition: blueprint_variable.hpp:91
Definition: blueprint.hpp:46
Definition: component.hpp:37
Definition: hash_io.hpp:43
std::vector< bool > get_digest() const
Definition: hash_io.hpp:78
blueprint_variable_vector< FieldType > bits
Definition: hash_io.hpp:46
Definition: sha256_aux.hpp:40
Definition: hash_io.hpp:126
Definition: sha256_component.hpp:44
void generate_r1cs_constraints()
Definition: sha256_component.hpp:144
std::vector< blueprint_linear_combination_vector< FieldType > > round_a
Definition: sha256_component.hpp:46
digest_variable< FieldType > output
Definition: sha256_component.hpp:66
std::vector< blueprint_linear_combination_vector< FieldType > > round_d
Definition: sha256_component.hpp:49
std::vector< blueprint_linear_combination_vector< FieldType > > round_g
Definition: sha256_component.hpp:52
std::vector< blueprint_linear_combination_vector< FieldType > > round_e
Definition: sha256_component.hpp:50
std::vector< blueprint_linear_combination_vector< FieldType > > round_f
Definition: sha256_component.hpp:51
blueprint_variable_vector< FieldType > reduced_output
Definition: sha256_component.hpp:60
std::vector< sha256_round_function_component< FieldType > > round_functions
Definition: sha256_component.hpp:57
std::vector< blueprint_linear_combination_vector< FieldType > > round_b
Definition: sha256_component.hpp:47
sha256_compression_function_component(blueprint< FieldType > &bp, const blueprint_linear_combination_vector< FieldType > &prev_output, const blueprint_variable_vector< FieldType > &new_block, const digest_variable< FieldType > &output)
Definition: sha256_component.hpp:68
std::shared_ptr< sha256_message_schedule_component< FieldType > > message_schedule
Definition: sha256_component.hpp:56
std::vector< blueprint_linear_combination_vector< FieldType > > round_h
Definition: sha256_component.hpp:53
std::vector< lastbits_component< FieldType > > reduce_output
Definition: sha256_component.hpp:61
blueprint_variable_vector< FieldType > unreduced_output
Definition: sha256_component.hpp:59
blueprint_linear_combination_vector< FieldType > prev_output
Definition: sha256_component.hpp:64
std::vector< blueprint_linear_combination_vector< FieldType > > round_c
Definition: sha256_component.hpp:48
void generate_r1cs_witness()
Definition: sha256_component.hpp:166
blueprint_variable_vector< FieldType > packed_W
Definition: sha256_component.hpp:55
blueprint_variable_vector< FieldType > new_block
Definition: sha256_component.hpp:65
Definition: sha256_component.hpp:270
std::shared_ptr< merkle_damagard_padding< FieldType > > padding
Definition: sha256_component.hpp:279
static std::vector< bool > get_hash(const std::vector< bool > &input)
Definition: sha256_component.hpp:354
sha256_hash_component(blueprint< FieldType > &bp, std::size_t input_len, const block_variable< FieldType > &block_input, const digest_variable< FieldType > &output)
Definition: sha256_component.hpp:281
static std::size_t get_digest_len()
Definition: sha256_component.hpp:350
snark::merkle_authentication_path merkle_authentication_path_type
Definition: sha256_component.hpp:274
digest_variable< FieldType > hash_variable_type
Definition: sha256_component.hpp:273
std::vector< std::shared_ptr< digest_variable< FieldType > > > intermediate_outputs
Definition: sha256_component.hpp:278
std::vector< bool > hash_value_type
Definition: sha256_component.hpp:272
std::vector< std::shared_ptr< sha256_compression_function_component< FieldType > > > blocks_components
Definition: sha256_component.hpp:276
void generate_r1cs_witness()
Definition: sha256_component.hpp:339
void generate_r1cs_constraints(bool ensure_output_bitness=true)
Definition: sha256_component.hpp:332
static std::size_t get_block_len()
Definition: sha256_component.hpp:346
std::vector< blueprint_variable_vector< FieldType > > blocks_bits
Definition: sha256_component.hpp:277
Definition: sha256_construction.hpp:45
Definition: sha256_construction.hpp:146
Definition: sha256_component.hpp:194
void generate_r1cs_witness()
Definition: sha256_component.hpp:233
static std::vector< bool > get_hash(const std::vector< bool > &input)
Definition: sha256_component.hpp:245
void generate_r1cs_constraints(bool ensure_output_bitness=true)
Definition: sha256_component.hpp:229
std::vector< bool > hash_value_type
Definition: sha256_component.hpp:196
sha256_two_to_one_hash_component(blueprint< FieldType > &bp, std::size_t block_length, const block_variable< FieldType > &input_block, const digest_variable< FieldType > &output)
Definition: sha256_component.hpp:217
sha256_two_to_one_hash_component(blueprint< FieldType > &bp, const digest_variable< FieldType > &left, const digest_variable< FieldType > &right, const digest_variable< FieldType > &output)
Definition: sha256_component.hpp:202
static std::size_t get_digest_len()
Definition: sha256_component.hpp:241
digest_variable< FieldType > hash_variable_type
Definition: sha256_component.hpp:197
std::shared_ptr< sha256_compression_function_component< FieldType > > f
Definition: sha256_component.hpp:200
static std::size_t expected_constraints(bool ensure_output_bitness=true)
Definition: sha256_component.hpp:260
snark::merkle_authentication_path merkle_authentication_path_type
Definition: sha256_component.hpp:198
static std::size_t get_block_len()
Definition: sha256_component.hpp:237
boost::mpl::apply< AccumulatorSet, tag::block< Mode > >::type::result_type block(const AccumulatorSet &acc)
Definition: accumulators/block.hpp:259
blueprint_linear_combination_vector< FieldType > SHA256_default_IV(blueprint< FieldType > &bp)
Definition: sha256_construction.hpp:274
std::vector< merkle_authentication_node > merkle_authentication_path
Definition: blueprint/include/nil/crypto3/zk/merkle_tree.hpp:66
Definition: pair.hpp:31
Definition: shacal2_policy.hpp:55
Definition: r1cs.hpp:60