Trait mitrid_core::crypto::commit::Committable[][src]

pub trait Committable<P, C> where
    P: Datable,
    C: Datable + ConstantSize,
    Self: 'static + Sized
{ fn commit_cb(
        &self,
        params: &P,
        cb: &Fn(&Self, &P) -> Result<C>
    ) -> Result<C> { ... }
fn verify_commitment_cb(
        &self,
        params: &P,
        commitment: &C,
        cb: &Fn(&Self, &P, &C) -> Result<bool>
    ) -> Result<bool> { ... }
fn check_commitment_cb(
        &self,
        params: &P,
        commitment: &C,
        cb: &Fn(&Self, &P, &C) -> Result<()>
    ) -> Result<()> { ... } }

Trait used by types that can be cryptographically committed.

Provided Methods

Commits cryptographically the implementor using Datable params and a callback. Returns a commitment.

Verifies a commitment against the implementor commit.

Checks a commitment against the implementor commit.

Implementors