Struct crypto_mac::Output [−][src]
Output
is a thin wrapper around bytes array which provides a safe Eq
implementation that runs in a fixed time.
Implementations
impl<M: Mac> Output<M>
[src]
pub fn new(bytes: GenericArray<u8, M::OutputSize>) -> Output<M>
[src]
Create a new MAC Output
.
pub fn into_bytes(self) -> GenericArray<u8, M::OutputSize>
[src]
Get the MAC tag/code value as a byte array.
Be very careful using this method, since incorrect use of the tag value
may permit timing attacks which defeat the security provided by the
Mac
trait.
Trait Implementations
impl<M: Clone + Mac> Clone for Output<M> where
M::OutputSize: Clone,
[src]
M::OutputSize: Clone,
impl<M: Mac> ConstantTimeEq for Output<M>
[src]
impl<M: Mac> Eq for Output<M>
[src]
impl<M: Mac> PartialEq<Output<M>> for Output<M>
[src]
Auto Trait Implementations
impl<M> RefUnwindSafe for Output<M> where
<<M as Mac>::OutputSize as ArrayLength<u8>>::ArrayType: RefUnwindSafe,
<<M as Mac>::OutputSize as ArrayLength<u8>>::ArrayType: RefUnwindSafe,
impl<M> Send for Output<M>
impl<M> Sync for Output<M>
impl<M> Unpin for Output<M> where
<<M as Mac>::OutputSize as ArrayLength<u8>>::ArrayType: Unpin,
<<M as Mac>::OutputSize as ArrayLength<u8>>::ArrayType: Unpin,
impl<M> UnwindSafe for Output<M> where
<<M as Mac>::OutputSize as ArrayLength<u8>>::ArrayType: UnwindSafe,
<<M as Mac>::OutputSize as ArrayLength<u8>>::ArrayType: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
[src]
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,