#[non_exhaustive]pub enum Algorithm {
Pbkdf2Sha1,
Pbkdf2Sha256,
Pbkdf2Sha512,
}
Expand description
PBKDF2 variants.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Pbkdf2Sha1
Available on crate feature
sha1
only.PBKDF2 SHA1
Pbkdf2Sha256
PBKDF2 SHA-256
Pbkdf2Sha512
PBKDF2 SHA-512
Implementations§
Source§impl Algorithm
impl Algorithm
Sourcepub const PBKDF2_SHA1_IDENT: Ident<'static>
pub const PBKDF2_SHA1_IDENT: Ident<'static>
PBKDF2 (SHA-1) algorithm identifier
Sourcepub const PBKDF2_SHA256_IDENT: Ident<'static>
pub const PBKDF2_SHA256_IDENT: Ident<'static>
PBKDF2 (SHA-256) algorithm identifier
Sourcepub const PBKDF2_SHA512_IDENT: Ident<'static>
pub const PBKDF2_SHA512_IDENT: Ident<'static>
PBKDF2 (SHA-512) algorithm identifier
Trait Implementations§
Source§impl Default for Algorithm
impl Default for Algorithm
Source§fn default() -> Self
fn default() -> Self
Default suggested by the OWASP cheat sheet:
Use PBKDF2 with a work factor of 600,000 or more and set with an internal hash function of HMAC-SHA-256.
Source§impl Ord for Algorithm
impl Ord for Algorithm
Source§impl PartialOrd for Algorithm
impl PartialOrd for Algorithm
impl Copy for Algorithm
impl Eq for Algorithm
impl StructuralPartialEq for Algorithm
Auto Trait Implementations§
impl Freeze for Algorithm
impl RefUnwindSafe for Algorithm
impl Send for Algorithm
impl Sync for Algorithm
impl Unpin for Algorithm
impl UnwindSafe for Algorithm
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more