Skip to content

A password hasher.

Notifications You must be signed in to change notification settings

tallesl/net-Hash

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

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
}