Method | Description | |
---|---|---|
AuthenticateUser ( string token, UserSessionDurationType duration, String ipAddress, ExecutionResults result ) : |
Authenticates against the data store and returns a UserIdentity given a token returned from a previous authentication.
|
|
AuthenticateUser ( string name, string password, UserSessionDurationType duration, string ipAddress, ExecutionResults result ) : |
Authenticates against the data store and returns a UserIdentity given a user name, and password.
|
|
GenerateUserResetCode ( String name ) : String |
Generates a new password reset code for a user and stores that as the current code valid for the next hour.
|
|
GetLatestUserSessions ( System.Guid userId, |
Gets the latest session(s) for a given user.
|
|
GetUserByID ( System.Guid userID ) : |
Gets a user by identity.
|
|
GetUserByName ( string name ) : |
Gets a user by name.
|
|
InvalidateSession ( string token, String ipAddress, ExecutionResults result ) : void |
Invalidates a session token so it can no longer be used.
|
|
RegisterUser ( |
Registers a new user. The PasswordHash property should be the actual password.
|
|
UpdateUser ( |
updates a user's name and/or password.
|
|
ValidateEmailAddressFormat ( string emailAddress ) : bool |
Validates that a string is a valid email address format.
|
|
ValidateName ( string name, ExecutionResults result ) : bool |
Validates that the specified name meets minimum requirements.
|
|
ValidatePassword ( string password, ExecutionResults results ) : bool |
Validates that a password meets minimum requirements.
|
public static AuthenticateUser ( string token, UserSessionDurationType duration, String ipAddress, ExecutionResults result ) : |
||
token | string | The unique token. |
duration | UserSessionDurationType | The amount of time that the renewed token will be valid. |
ipAddress | String | The internet address where the user is connecting from. |
result | ExecutionResults | A ExecutionResults instance to add applicable /// warning and error messages to. |
return |
public static AuthenticateUser ( string name, string password, UserSessionDurationType duration, string ipAddress, ExecutionResults result ) : |
||
name | string | The unique user name. |
password | string | The matching password. |
duration | UserSessionDurationType | The amount of time that the issued token will be valid. |
ipAddress | string | The internet address where the user is connecting from. |
result | ExecutionResults | A ExecutionResults instance to add applicable /// warning and error messages to. |
return |
public static GenerateUserResetCode ( String name ) : String | ||
name | String | The user name / email address. |
return | String |
public static GetLatestUserSessions ( System.Guid userId, |
||
userId | System.Guid | The unique identity. |
take | The maximum number of sessions to retrieve. | |
return | List |
public static GetUserByID ( System.Guid userID ) : |
||
userID | System.Guid | The unique identity. |
return |
public static GetUserByName ( string name ) : |
||
name | string | The unique sign in name. |
return |
public static InvalidateSession ( string token, String ipAddress, ExecutionResults result ) : void | ||
token | string | |
ipAddress | String | |
result | ExecutionResults | |
return | void |
public static RegisterUser ( |
||
user | A user with a raw password which is turned into a password hash as part of registration. | |
duration | UserSessionDurationType | The amount of time that the initial session will be valid. |
ipAddress | String | The internet address where the user is connecting from. |
result | ExecutionResults | A ExecutionResults instance to add applicable /// warning and error messages to. |
return |
public static UpdateUser ( |
||
item | The user details to be saved. If Password is empty is it not changed. If specified it should be the new raw password (not a hash). | |
currentPassword | String | The current raw password for the user used to authenticate that the change can be made. |
ipAddress | String | The internet address where the user is connecting from. |
result | ExecutionResults | A ExecutionResults instance to add applicable /// warning and error messages to. |
return | bool |
public static ValidateEmailAddressFormat ( string emailAddress ) : bool | ||
emailAddress | string | |
return | bool |
public static ValidateName ( string name, ExecutionResults result ) : bool | ||
name | string | The desired name/alias. |
result | ExecutionResults | Any error messages about the desired name. |
return | bool |
public static ValidatePassword ( string password, ExecutionResults results ) : bool | ||
password | string | |
results | ExecutionResults | |
return | bool |