/net-Hash

A password hasher.

Primary LanguageC#

Hash

A password hasher that generates a unique salt for each hash and hashes using PBKDF2.

Usage

var plainPassword = "my cr4zy pa$$w0rd";

// gives a HashedPassword object
// which has Hash and Salt properties ready to be stored somewhere
var hash = HashedPassword.New(plainPassword);

// checking the plain text password against the hashed one
if (hash.Check(plainPassword))
{
    // the given password matches the given hash
}
else
{
    // wrong password
}