pub struct PasswordHashRef(/* private fields */);Available on crate feature
password-hash only.Expand description
Password hash reference type for hashes encoded in the Modular Crypt Format (MCF),
e.g. $<id>$....
For more information, see PasswordHash.
Implementations§
Source§impl PasswordHashRef
impl PasswordHashRef
Sourcepub fn new(s: &str) -> Result<&PasswordHashRef, Error>
pub fn new(s: &str) -> Result<&PasswordHashRef, Error>
Parse the given input string, returning an PasswordHashRef if valid.
Trait Implementations§
Source§impl AsRef<PasswordHashRef> for PasswordHash
impl AsRef<PasswordHashRef> for PasswordHash
Source§fn as_ref(&self) -> &PasswordHashRef
fn as_ref(&self) -> &PasswordHashRef
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<str> for &PasswordHashRef
impl AsRef<str> for &PasswordHashRef
Source§impl Borrow<PasswordHashRef> for PasswordHash
impl Borrow<PasswordHashRef> for PasswordHash
Source§fn borrow(&self) -> &PasswordHashRef
fn borrow(&self) -> &PasswordHashRef
Immutably borrows from an owned value. Read more
Source§impl Debug for PasswordHashRef
impl Debug for PasswordHashRef
Source§impl Display for PasswordHashRef
impl Display for PasswordHashRef
Source§impl<'a> From<&'a PasswordHash> for &'a PasswordHashRef
impl<'a> From<&'a PasswordHash> for &'a PasswordHashRef
Source§fn from(hash: &'a PasswordHash) -> &'a PasswordHashRef
fn from(hash: &'a PasswordHash) -> &'a PasswordHashRef
Converts to this type from the input type.
Source§impl<'a> From<&'a PasswordHashRef> for &'a str
impl<'a> From<&'a PasswordHashRef> for &'a str
Source§fn from(hash: &'a PasswordHashRef) -> &'a str
fn from(hash: &'a PasswordHashRef) -> &'a str
Converts to this type from the input type.
Source§impl From<&PasswordHashRef> for PasswordHash
impl From<&PasswordHashRef> for PasswordHash
Source§fn from(hash: &PasswordHashRef) -> PasswordHash
fn from(hash: &PasswordHashRef) -> PasswordHash
Converts to this type from the input type.
Source§impl Ord for PasswordHashRef
impl Ord for PasswordHashRef
Source§impl PartialEq for PasswordHashRef
impl PartialEq for PasswordHashRef
Source§impl PartialOrd for PasswordHashRef
impl PartialOrd for PasswordHashRef
Source§impl PasswordVerifier<PasswordHashRef> for ShaCrypt
impl PasswordVerifier<PasswordHashRef> for ShaCrypt
Source§fn verify_password(&self, password: &[u8], hash: &PasswordHashRef) -> Result<()>
fn verify_password(&self, password: &[u8], hash: &PasswordHashRef) -> Result<()>
Compute this password hashing function against the provided password
using the parameters from the provided password hash and see if the
computed output matches.
Source§impl ToOwned for PasswordHashRef
impl ToOwned for PasswordHashRef
Source§type Owned = PasswordHash
type Owned = PasswordHash
The resulting type after obtaining ownership.
Source§fn to_owned(&self) -> PasswordHash
fn to_owned(&self) -> PasswordHash
Creates owned data from borrowed data, usually by cloning. Read more
1.63.0 · Source§fn clone_into(&self, target: &mut Self::Owned)
fn clone_into(&self, target: &mut Self::Owned)
Uses borrowed data to replace owned data, usually by cloning. Read more