Struct tor_checkable::signed::SignatureGated
source · pub struct SignatureGated<T> { /* private fields */ }Expand description
A SignatureGated object is a self-signed object that’s well-signed when one or more ValidatableSignature objects are correct.
Implementations§
source§impl<T> SignatureGated<T>
impl<T> SignatureGated<T>
sourcepub fn new(obj: T, signatures: Vec<Box<dyn ValidatableSignature>>) -> Self
pub fn new(obj: T, signatures: Vec<Box<dyn ValidatableSignature>>) -> Self
Return a new SignatureGated object that will be treated as correct if every one if the given set of signatures is valid.
Trait Implementations§
source§impl<T> SelfSigned<T> for SignatureGated<T>
impl<T> SelfSigned<T> for SignatureGated<T>
source§fn dangerously_assume_wellsigned(self) -> T
fn dangerously_assume_wellsigned(self) -> T
Return the underlying object without checking its signature.
source§fn check_signature(self) -> Result<T, Self::Error>
fn check_signature(self) -> Result<T, Self::Error>
Unwrap this object if the signature is valid