Search Results for

    Show / Hide Table of Contents

    Class IvOAuthTokenUtil

    OAuth authentication utility class.

    Inheritance
    System.Object
    IvOAuthTokenUtil
    Implements
    IAuthTokenUtil
    Namespace: ImageVault.Client.Authentication
    Assembly: ImageVault.Client.dll
    Syntax
    public class IvOAuthTokenUtil : Object, IAuthTokenUtil

    Constructors

    IvOAuthTokenUtil(ImageVaultClientOptions, String, IList<String>, IList<Claim>)

    Declaration
    public IvOAuthTokenUtil(ImageVaultClientOptions options, string actAsUser = null, IList<string> roles = null, IList<Claim> claims = null)
    Parameters
    Type Name Description
    ImageVaultClientOptions options
    System.String actAsUser
    System.Collections.Generic.IList<System.String> roles
    System.Collections.Generic.IList<System.Security.Claims.Claim> claims

    Properties

    ClientConfiguration

    Get/Sets the Configuration of the IvOAuthTokenUtil

    Declaration
    public ClientConfigurationSection ClientConfiguration { get; }
    Property Value
    Type Description
    ClientConfigurationSection

    TokenExpires

    Gets the TokenExpires of the IvOAuthTokenUtil

    Declaration
    public DateTime TokenExpires { get; }
    Property Value
    Type Description
    System.DateTime

    Methods

    ClearAuthToken()

    Clears the current auth token

    Declaration
    public void ClearAuthToken()

    GetAuthToken()

    Gets the Authentication token that should be added to the Authorization header

    Declaration
    public string GetAuthToken()
    Returns
    Type Description
    System.String

    GetAuthToken(Boolean)

    Gets the Authentication token that should be added to the Authorization header

    Declaration
    public string GetAuthToken(bool forceRenew)
    Parameters
    Type Name Description
    System.Boolean forceRenew
    Returns
    Type Description
    System.String

    RequestAccessToken()

    Requests an access token

    Declaration
    public AccessToken RequestAccessToken()
    Returns
    Type Description
    AccessToken
    Exceptions
    Type Condition
    System.ApplicationException

    If cannot create request for .

    ImageVaultException

    If no configured SdkIdentity was found or if request access token failed: or if cannot get response stream from response or if unable to request access token @ .

    Implements

    IAuthTokenUtil

    Extension Methods

    EnumExtensions.GetNames<TEnum>(TEnum)
    In This Article
    Back to top (c) Meriworks 2002-2022