Click or drag to resize

IAuthenticationProvider Interface

NetQuarry supports application security using a powerful, replaceable set of authentication and permission patterns. Depending on the needs of your application and the capabilities of your enterprise infrastructure, NetQuarry can support several different methods of user authentication. Several standard authentication provider are available:
  • DatabaseAuthenticationProvider - Authenticates users based on user ID and password stored in the main operational database. This is the primary authenticator.
  • GenericAuthenticationProvider - Always authenticates the user regardless of password. Also serves as a base class for most other authentication provider implementations.
  • WindowsAuthenticationProvider - Authenticates using the company's ActiveDirectory and NTLM. Not generally appropriate for use in SaaS and other applications with non-employee users.

Namespace:  NetQuarry.Security
Assembly:  EAP.Core (in EAP.Core.dll) Version: 2.0.0.0 (4.6.8.0)
Syntax
public interface IAuthenticationProvider

The IAuthenticationProvider type exposes the following members.

Properties
  NameDescription
Public propertyApplication
Gets/Sets an IAppContext object for use by the provider.
Public propertyProperties
Get the object's Properties collection.
Top
Methods
  NameDescription
Public methodAuthenticate(String, Int64)
The implementing class should authenticate the user using the provided token, create and populate a UserContext object adding appropriate UserProfiles items to its Profiles collection. If the authentication fails, the implementing class can return a null UserContext object or throw a custom exception.
Public methodAuthenticate(String, String, NameValueCollection, Int64)
The implementing class should authenticate the user, create and populate a UserContext object adding UserProfiles items to its Profiles collection when an item in the profileRoles collection is supported for this user. If the authentication fails, the implementing class can return a null UserContext object or throw a custom exception. Note that you can use BuildProfileRolesCollection(IAppContext) to get the full set of available roles for the current application.
Public methodChangePassword
Changes the password for the user. Use ChangeUserPassword(IAppContext, String, String, String) if you need the new password in a form (raw vs. encrypted) for storing in Password.
Public methodChangeUserPassword
Changes the password for the user. Performs the same functionality as ChangePassword(IAppContext, String, String, String) except that it returns the new password (raw for two-way encryptions, encrypted for one-way encryptions) as is appropriate for storing in Password.
Public methodResetPassword
Sets the password to null, sets the ForcePasswordChange attribute on the user and (optionally) sends the user a way to reset it via email.
Public methodRestore
Restore the user context from a user id. Used when a password is lost and you want to send the user a new password.
Top
Remarks
A class can implement this interface to provide a new method of authentication.
See Also