Skip to main content

ProverState

Struct ProverState 

Source
pub struct ProverState<C: Spake2PlusCiphersuite> { /* private fields */ }
Expand description

State held by the Prover between sending shareP and receiving (shareV, confirmV).

Implementations§

Source§

impl<C: Spake2PlusCiphersuite> ProverState<C>

Source

pub fn finish( self, share_v_bytes: &[u8], confirm_v: &[u8], ) -> Result<ProverOutput, Spake2PlusError>

Finish the SPAKE2+ protocol by processing the Verifier’s response.

The Prover receives (shareV_bytes, confirm_v) from the Verifier, verifies confirm_v, and returns ProverOutput containing the session key and confirm_p to send back.

Trait Implementations§

Source§

impl<C: Spake2PlusCiphersuite> Drop for ProverState<C>

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more
Source§

impl<C: Spake2PlusCiphersuite> Zeroize for ProverState<C>

Source§

fn zeroize(&mut self)

Zero out this object from memory using Rust intrinsics which ensure the zeroization operation is not “optimized away” by the compiler.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.