|
Barretenberg
The ZK-SNARK library at the core of Aztec
|
Base Stdlib verification key class. More...
#include <flavor.hpp>
Public Types | |
| using | Builder = Builder_ |
| using | FF = stdlib::field_t< Builder > |
| using | Commitment = typename PrecomputedCommitments::DataType |
| using | Transcript = StdlibTranscript< Builder > |
| using | NativeVerificationKey = NativeVerificationKey_ |
Public Member Functions | |
| bool | operator== (const StdlibVerificationKey_ &) const =default |
| virtual | ~StdlibVerificationKey_ ()=default |
| StdlibVerificationKey_ ()=default | |
| template<typename T = NativeVerificationKey_> requires (!std::is_void_v<T>) | |
| StdlibVerificationKey_ (Builder *builder, const std::shared_ptr< T > &native_key) | |
| Construct a new Verification Key with stdlib types from a provided native verification key. | |
| StdlibVerificationKey_ (std::span< FF > elements) | |
| Deserialize a verification key from a vector of field elements. | |
| void | fix_witness () |
| Fixes witnesses of VK to be constants. | |
| template<typename T = NativeVerificationKey_> requires (!std::is_void_v<T>) | |
| T | get_value () const |
| Get the native verification key corresponding to this stdlib verification key. | |
| virtual FF | hash_with_origin_tagging (const OriginTag &tag) const |
| Tag VK components and hash. | |
| template<typename Transcript > | |
| FF | hash_with_origin_tagging (const Transcript &transcript) const |
| An overload that accepts a transcript and extracts the tag internally. | |
Static Public Member Functions | |
| static StdlibVerificationKey_ | from_witness_indices (Builder &builder, const std::span< const uint32_t > &witness_indices) |
| Construct a VerificationKey from a set of corresponding witness indices. | |
Public Attributes | |
| FF | log_circuit_size |
| FF | num_public_inputs |
| FF | pub_inputs_offset = 0 |
Base Stdlib verification key class.
| Builder_ | The circuit builder type |
| PrecomputedCommitments | The precomputed entities type |
| NativeVerificationKey_ | The native VK type (optional, enables native<->stdlib conversion) |
Definition at line 378 of file flavor.hpp.
| using bb::StdlibVerificationKey_< Builder_, PrecomputedCommitments, NativeVerificationKey_ >::Builder = Builder_ |
Definition at line 380 of file flavor.hpp.
| using bb::StdlibVerificationKey_< Builder_, PrecomputedCommitments, NativeVerificationKey_ >::Commitment = typename PrecomputedCommitments::DataType |
Definition at line 382 of file flavor.hpp.
| using bb::StdlibVerificationKey_< Builder_, PrecomputedCommitments, NativeVerificationKey_ >::FF = stdlib::field_t<Builder> |
Definition at line 381 of file flavor.hpp.
| using bb::StdlibVerificationKey_< Builder_, PrecomputedCommitments, NativeVerificationKey_ >::NativeVerificationKey = NativeVerificationKey_ |
Definition at line 384 of file flavor.hpp.
| using bb::StdlibVerificationKey_< Builder_, PrecomputedCommitments, NativeVerificationKey_ >::Transcript = StdlibTranscript<Builder> |
Definition at line 383 of file flavor.hpp.
|
virtualdefault |
|
default |
|
inline |
Construct a new Verification Key with stdlib types from a provided native verification key.
Only available when NativeVerificationKey is specified (not void)
Definition at line 399 of file flavor.hpp.
|
inlineexplicit |
Deserialize a verification key from a vector of field elements.
Definition at line 413 of file flavor.hpp.
|
inline |
Fixes witnesses of VK to be constants.
Definition at line 448 of file flavor.hpp.
|
inlinestatic |
Construct a VerificationKey from a set of corresponding witness indices.
Definition at line 434 of file flavor.hpp.
|
inline |
Get the native verification key corresponding to this stdlib verification key.
Only available when NativeVerificationKey is specified (not void)
Definition at line 465 of file flavor.hpp.
|
inlinevirtual |
Tag VK components and hash.
Needed to make sure the Origin Tag system works. We need to set the origin tags of the VK witnesses. If we instead did the hashing outside and just submitted the hash, only the origin tag of the hash would be set properly. By tagging the VK components directly, we ensure all VK witnesses have proper origin tags.
| tag | The origin tag extracted from the transcript |
Definition at line 487 of file flavor.hpp.
|
inline |
An overload that accepts a transcript and extracts the tag internally.
| TranscriptType | The transcript type (Codec and HashFunction deduced automatically) |
| transcript | The transcript to extract the origin tag from |
Definition at line 523 of file flavor.hpp.
|
default |
| FF bb::StdlibVerificationKey_< Builder_, PrecomputedCommitments, NativeVerificationKey_ >::log_circuit_size |
Definition at line 385 of file flavor.hpp.
| FF bb::StdlibVerificationKey_< Builder_, PrecomputedCommitments, NativeVerificationKey_ >::num_public_inputs |
Definition at line 386 of file flavor.hpp.
| FF bb::StdlibVerificationKey_< Builder_, PrecomputedCommitments, NativeVerificationKey_ >::pub_inputs_offset = 0 |
Definition at line 387 of file flavor.hpp.