std :: crypto::hmac
Struct std::Hmac
generic<H: BlockHash> struct Hmac {
H inner;
H outer;
}Fields
H((key ^ ipad) || message ...)
H((key ^ opad) || ...), fed the inner digest by finish()
Methods
An HMAC keyed by 'key' over 'fresh', a new context of the hash to use (Sha256Ctx::new(), Sha512Ctx::new_384(), ...). A key longer than the hash's block is hashed first, as RFC 2104 specifies.
Writes the digest_size()-byte MAC into mac (a shorter slice panics). The context is spent after.