class RbNaCl::PasswordHash::Argon2
def self.digest_str_verify(password, digest_string)
-
(boolean)
- true if password matches digest_string
Parameters:
-
digest_string
(String
) -- to compare to -
password
(String
) -- to be hashed
def self.digest_str_verify(password, digest_string) raise ArgumentError, "password must be a String" unless password.is_a?(String) raise ArgumentError, "digest_string must be a String" unless digest_string.is_a?(String) pwhash_str_verify( digest_string, password, password.bytesize ) end