Search Results for

    Show / Hide Table of Contents

    Class DbAuthenticationProvider

    Database based (ESS_MS_Intern_User) authentication provider

    Inheritance
    System.Object
    DbAuthenticationProvider
    Implements
    IAuthenticationProvider
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Simplic.Framework.Base.Auth
    Assembly: Simplic.Framework.Base.dll
    Syntax
    public class DbAuthenticationProvider : IAuthenticationProvider

    Constructors

    | Improve this Doc View Source

    DbAuthenticationProvider(IUserService)

    Initialize service

    Declaration
    public DbAuthenticationProvider(IUserService userService)
    Parameters
    Type Name Description
    IUserService userService

    User service

    Methods

    | Improve this Doc View Source

    AuthorizeAsync(IIdentity)

    Authorize a user and get its principal

    Declaration
    public async Task<UserPrincipal> AuthorizeAsync(IIdentity identity)
    Parameters
    Type Name Description
    System.Security.Principal.IIdentity identity

    User identity instance

    Returns
    Type Description
    System.Threading.Tasks.Task<UserPrincipal>

    Principal instance

    | Improve this Doc View Source

    LoginAsync(String, String)

    Login a user and return its identity

    Declaration
    public async Task<UserIdentity> LoginAsync(string userName, string password)
    Parameters
    Type Name Description
    System.String userName

    User name

    System.String password

    Password

    Returns
    Type Description
    System.Threading.Tasks.Task<UserIdentity>

    Identity instance if the user exsits, else null

    | Improve this Doc View Source

    LoginByApiKeyAsync(String, String)

    Login a user using an API key and return its identity.

    Declaration
    public async Task<UserIdentity> LoginByApiKeyAsync(string userName, string apiKey)
    Parameters
    Type Name Description
    System.String userName
    System.String apiKey
    Returns
    Type Description
    System.Threading.Tasks.Task<UserIdentity>

    Implements

    IAuthenticationProvider
    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright © 2018 SIMPLIC GmbH
    Generated by DocFx