Show / Hide Table of Contents

Class PasswordHasher

A base implementation of the . This implementation is an implementation of PBKDF2.

Inheritance
System.Object
PasswordHasher
Implements
IPasswordHasher
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Sartorius.SAF.Security
Assembly: Sartorius.SAF.dll
Syntax
public class PasswordHasher : IPasswordHasher

Methods

View Source

Hash(String)

Implements password hashing methods.

Declaration
public virtual string Hash(string password)
Parameters
Type Name Description
System.String password

The password to hash.

Returns
Type Description
System.String

A hashed password.

View Source

Hash(String, PasswordHasherOptions)

Hash the given password using given has options.

Declaration
public virtual string Hash(string password, PasswordHasherOptions options)
Parameters
Type Name Description
System.String password

The password to hash.

PasswordHasherOptions options

The options for hash.

Returns
Type Description
System.String

A hashed password.

View Source

Verify(String, String)

Implements password hashing methods.

Declaration
public virtual bool Verify(string hashedPassword, string providedPassword)
Parameters
Type Name Description
System.String hashedPassword

A hashed password as base 64 string.

System.String providedPassword

A provided password as plain text.

Returns
Type Description
System.Boolean

True if the hashedPassword and providedPassword equals, otherwise False.

Implements

IPasswordHasher

Extension Methods

CollectionExtensions.AddRange<T, TCollection>(TCollection, IEnumerable<T>)
SerializableObjectCloneExtension.Clone<T>(T)
  • View Source
Back to top Generated by DocFX