Struct hmac::Hmac [−][src]
pub struct Hmac<D> where
D: Input + BlockInput + FixedOutput + Default + Clone,
D::BlockSize: ArrayLength<u8>, { /* fields omitted */ }The Hmac struct represents an HMAC using a given hash function D.
Trait Implementations
impl<D: Clone> Clone for Hmac<D> where
D: Input + BlockInput + FixedOutput + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::BlockSize: Clone, [src]
impl<D: Clone> Clone for Hmac<D> where
D: Input + BlockInput + FixedOutput + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::BlockSize: Clone, fn clone(&self) -> Hmac<D>[src]
fn clone(&self) -> Hmac<D>Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)1.0.0
[src]Performs copy-assignment from source. Read more
impl<D: Debug> Debug for Hmac<D> where
D: Input + BlockInput + FixedOutput + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::BlockSize: Debug, [src]
impl<D: Debug> Debug for Hmac<D> where
D: Input + BlockInput + FixedOutput + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::BlockSize: Debug, fn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl<D> Mac for Hmac<D> where
D: Input + BlockInput + FixedOutput + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::OutputSize: ArrayLength<u8>, [src]
impl<D> Mac for Hmac<D> where
D: Input + BlockInput + FixedOutput + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::OutputSize: ArrayLength<u8>, type OutputSize = D::OutputSize
type KeySize = D::BlockSize
fn new(key: &GenericArray<u8, Self::KeySize>) -> Self[src]
fn new(key: &GenericArray<u8, Self::KeySize>) -> SelfCreate new MAC instance from key with fixed size.
fn new_varkey(key: &[u8]) -> Result<Self, InvalidKeyLength>[src]
fn new_varkey(key: &[u8]) -> Result<Self, InvalidKeyLength>Create new MAC instance from key with variable size. Read more
fn input(&mut self, data: &[u8])[src]
fn input(&mut self, data: &[u8])Process input data.
fn result(&mut self) -> MacResult<D::OutputSize>[src]
fn result(&mut self) -> MacResult<D::OutputSize>Obtain the result of a Mac computation as a MacResult and reset Mac instance. Read more
fn verify(&mut self, code: &[u8]) -> Result<(), MacError>[src]
fn verify(&mut self, code: &[u8]) -> Result<(), MacError>Check if code is correct for the processed input and reset Mac instance. Read more