Class AuthenticationMethod
Base class for all supported authentication methods.
public abstract class AuthenticationMethod
- Inheritance
-
AuthenticationMethod
- Derived
- Inherited Members
Constructors
AuthenticationMethod(string)
Initializes a new instance of the AuthenticationMethod class.
protected AuthenticationMethod(string username)
Parameters
username
stringThe username.
Exceptions
- ArgumentException
username
is whitespace or null.
Properties
AllowedAuthentications
Gets or sets the list of allowed authentications.
public string[] AllowedAuthentications { get; protected set; }
Property Value
- string[]
Name
Gets the name of the authentication method.
public abstract string Name { get; }
Property Value
- string
The name of the authentication method.
Username
Gets connection username.
public string Username { get; }
Property Value
Methods
Authenticate(Session)
Authenticates the specified session.
public abstract AuthenticationResult Authenticate(Session session)
Parameters
session
SessionThe session to authenticate.
Returns
- AuthenticationResult
The result of the authentication process.