Struct dusk_plonk::proof_system::verifier::Verifier [−][src]
pub struct Verifier { pub verifier_key: Option<VerifierKey>, pub preprocessed_transcript: Transcript, // some fields omitted }
Abstraction structure designed verify Proof
s.
Fields
verifier_key: Option<VerifierKey>
VerificationKey which is used to verify a specific PLONK circuit
preprocessed_transcript: Transcript
Store the messages exchanged during the preprocessing stage This is copied each time, we make a proof, so that we can use the same verifier to Verify multiple proofs from the same circuit. If this is not copied, then the verification procedure will modify the transcript, making it unusable for future proofs.
Implementations
impl Verifier
[src]
pub fn new(label: &'static [u8]) -> Verifier
[src]
Creates a new Verifier
instance.
pub fn with_expected_size(label: &'static [u8], size: usize) -> Verifier
[src]
Creates a new Verifier
instance with some expected size.
pub fn circuit_size(&self) -> usize
[src]
Returns the number of gates in the circuit.
pub fn mut_cs(&mut self) -> &mut StandardComposer
[src]
Returns a mutable copy of the underlying composer.
pub fn preprocess(&mut self, commit_key: &CommitKey) -> Result<(), Error>
[src]
Preprocess a circuit to obtain a VerifierKey
and a circuit
descriptor so that the Verifier
instance can verify Proof
s
for this circuit descriptor instance.
pub fn key_transcript(&mut self, label: &'static [u8], message: &[u8])
[src]
Keys the Transcript
with additional seed information
Wrapper around Transcript::append_message
.
pub fn verify(
&self,
proof: &Proof,
opening_key: &OpeningKey,
public_inputs: &[BlsScalar]
) -> Result<(), Error>
[src]
&self,
proof: &Proof,
opening_key: &OpeningKey,
public_inputs: &[BlsScalar]
) -> Result<(), Error>
Verifies a Proof
.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Verifier
impl Send for Verifier
impl Sync for Verifier
impl Unpin for Verifier
impl UnwindSafe for Verifier
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Pointable for T
pub const ALIGN: usize
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
pub unsafe fn drop(ptr: usize)
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,