[−][src]Struct pwbox::rcrypto::Keccak256
This is supported on crate feature
rust-crypto
only.MAC construction based on Keccak256 hash function.
This MAC is used as a part of Ethereum keystores.
Specification
Mac(key, message) = Keccak256(key || message)
where ||
denotes concatenation of byte arrays.
Theoretical note
This construction is only secure because hash functions from Keccak/SHA-3 family are resistant to length extension attacks. Implementing a similar construction based on functions from the SHA-2 family or other hash functions susceptible to length extension attacks is not secure; use an HMAC instead.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Keccak256
impl Send for Keccak256
impl Sync for Keccak256
impl Unpin for Keccak256
impl UnwindSafe for Keccak256
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
type Output = T
Should always be Self
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>,