pub struct BashPrgHash<const RATE: usize, const CAPACITY: usize> { /* private fields */ }Expand description
bash-prg-hash hasher generic over rate and capacity.
§Generic Parameters
Only the following combinations of rate and capacity with the resulting security level are supported:
| Rate, bytes | Capacity | Security level, bits | Variant |
|---|---|---|---|
| 160 | 1 | 128 | BashPrgHash1281 |
| 128 | 2 | 128 | BashPrgHash1282 |
| 144 | 1 | 192 | BashPrgHash1921 |
| 96 | 2 | 192 | BashPrgHash1922 |
| 128 | 1 | 256 | BashPrgHash2561 |
| 64 | 2 | 256 | BashPrgHash2562 |
Trying to initialize hasher state with a different pair of parameters will result in a compilation error.
Users are recommended to use type aliases referenced in the last column instead of using this type directly.
Trait Implementations§
Source§impl<const RATE: usize, const CAPACITY: usize> AlgorithmName for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> AlgorithmName for BashPrgHash<RATE, CAPACITY>
Source§impl<const RATE: usize, const CAPACITY: usize> Clone for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> Clone for BashPrgHash<RATE, CAPACITY>
Source§fn clone(&self) -> BashPrgHash<RATE, CAPACITY>
fn clone(&self) -> BashPrgHash<RATE, CAPACITY>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<const RATE: usize, const CAPACITY: usize> ExtendableOutput for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> ExtendableOutput for BashPrgHash<RATE, CAPACITY>
Source§type Reader = BashPrgHashReader<RATE, CAPACITY>
type Reader = BashPrgHashReader<RATE, CAPACITY>
Reader
Source§fn finalize_xof(self) -> Self::Reader
fn finalize_xof(self) -> Self::Reader
Retrieve XOF reader and consume hasher instance.
Source§fn finalize_xof_into(self, out: &mut [u8])
fn finalize_xof_into(self, out: &mut [u8])
Finalize XOF and write result into
out.Source§impl<const RATE: usize, const CAPACITY: usize> TryCustomizedInit for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> TryCustomizedInit for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> ZeroizeOnDrop for BashPrgHash<RATE, CAPACITY>
Available on crate feature
zeroize only.Auto Trait Implementations§
impl<const RATE: usize, const CAPACITY: usize> Freeze for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> RefUnwindSafe for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> Send for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> Sync for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> Unpin for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> UnsafeUnpin for BashPrgHash<RATE, CAPACITY>
impl<const RATE: usize, const CAPACITY: usize> UnwindSafe for BashPrgHash<RATE, CAPACITY>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DynAssociatedOid for Twhere
T: AssociatedOid,
impl<T> DynAssociatedOid for Twhere
T: AssociatedOid,
Source§fn oid(&self) -> ObjectIdentifier
fn oid(&self) -> ObjectIdentifier
Get the OID associated with this value.