pub struct WebBotAuthVerifier { /* private fields */ }
Expand description
A verifier for Web Bot Auth messages specifically.
Implementations§
Source§impl WebBotAuthVerifier
impl WebBotAuthVerifier
Sourcepub fn parse(
message: &impl WebBotAuthSignedMessage,
) -> Result<Self, ImplementationError>
pub fn parse( message: &impl WebBotAuthSignedMessage, ) -> Result<Self, ImplementationError>
Parse a message into a structure that is ready for verification against an
external key with a suitable algorithm. If alg
is not set, a default will
be chosen from the alg
parameter.
§Errors
Returns ImplementationErrors
relevant to verifying and parsing.
Sourcepub fn get_signature_agents(&self) -> &Vec<SignatureAgentLink>
pub fn get_signature_agents(&self) -> &Vec<SignatureAgentLink>
Obtain list of Signature-Agents parsed and ready. This method is ideal for populating a keyring ahead of time at your discretion.
Sourcepub fn verify(
self,
keyring: &KeyRing,
key_id: Option<String>,
) -> Result<SignatureTiming, ImplementationError>
pub fn verify( self, keyring: &KeyRing, key_id: Option<String>, ) -> Result<SignatureTiming, ImplementationError>
Verify the messsage, consuming the verifier in the process.
If key_id
is not supplied, a key ID to fetch the public key
from keyring
will be sourced from the keyid
parameter
within the message.
Sourcepub fn get_parsed_label(&self) -> &ParsedLabel
pub fn get_parsed_label(&self) -> &ParsedLabel
Retrieve the contents of the chosen signature and signature input label for verification.
Trait Implementations§
Source§impl Clone for WebBotAuthVerifier
impl Clone for WebBotAuthVerifier
Source§fn clone(&self) -> WebBotAuthVerifier
fn clone(&self) -> WebBotAuthVerifier
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for WebBotAuthVerifier
impl RefUnwindSafe for WebBotAuthVerifier
impl Send for WebBotAuthVerifier
impl Sync for WebBotAuthVerifier
impl Unpin for WebBotAuthVerifier
impl UnwindSafe for WebBotAuthVerifier
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more