C# Class GSF.Security.Authentication.SrpUserCredentials

Provides simple password based authentication that uses Secure Remote Password.
It is safe to store the user's credential on the server. This is a zero knowledge password proof, meaning if this database is compromised, a brute force attack is the only way to reveal the password.
Exibir arquivo Open project: GridProtectionAlliance/openHistorian Class Usage Examples

Public Methods

Method Description
AddUser ( string username, byte verifier, byte passwordSalt, int iterations, SrpStrength strength ) : void

Adds the specified user to the credential database.

AddUser ( string username, string password, SrpStrength strength = SrpStrength.Bits1024, int saltSize = 32, int iterations = 4000 ) : void

Adds the specified user to the credentials database.

Lookup ( string username ) : SrpUserCredential

Looks up the username from the database.

Method Details

AddUser() public method

Adds the specified user to the credential database.
public AddUser ( string username, byte verifier, byte passwordSalt, int iterations, SrpStrength strength ) : void
username string
verifier byte
passwordSalt byte
iterations int
strength SrpStrength
return void

AddUser() public method

Adds the specified user to the credentials database.
public AddUser ( string username, string password, SrpStrength strength = SrpStrength.Bits1024, int saltSize = 32, int iterations = 4000 ) : void
username string
password string
strength SrpStrength
saltSize int
iterations int
return void

Lookup() public method

Looks up the username from the database.
public Lookup ( string username ) : SrpUserCredential
username string
return SrpUserCredential