Struct poly1305::Poly1305 [−][src]
pub struct Poly1305 { /* fields omitted */ }
The Poly1305 universal hash function.
Note that Poly1305 is not a traditional MAC and is single-use only (a.k.a. “one-time authenticator”).
For this reason it doesn’t impl the crypto_mac::Mac
trait.
Implementations
impl Poly1305
[src]
impl Poly1305
[src]pub fn compute_unpadded(self, data: &[u8]) -> Tag
[src]
Compute unpadded Poly1305 for the given input data.
The main use case for this is XSalsa20Poly1305.
Trait Implementations
impl Clone for Poly1305
[src]
impl Clone for Poly1305
[src]fn clone(&self) -> Poly1305
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl NewUniversalHash for Poly1305
[src]
impl NewUniversalHash for Poly1305
[src]impl UniversalHash for Poly1305
[src]
impl UniversalHash for Poly1305
[src]type BlockSize = U16
Size of the inputs to and outputs from the universal hash function
fn update(&mut self, block: &Block)
[src]
Input data into the Poly1305 universal hash function
fn reset(&mut self)
[src]
Reset internal state
fn finalize(self) -> Tag
[src]
Get the hashed output
pub fn update_padded(&mut self, data: &[u8])
[src]
pub fn finalize_reset(&mut self) -> Output<Self>
[src]
pub fn verify(
self,
other: &GenericArray<u8, Self::BlockSize>
) -> Result<(), Error>
[src]
self,
other: &GenericArray<u8, Self::BlockSize>
) -> Result<(), Error>