Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface Credentials

Abstract representation of a Credentials object. All implementations of this interface will define the required types and parameters for the specific implementation.

Hierarchy

  • Credentials

Index

Methods

applyHttpChallenge

  • applyHttpChallenge(challenge: string, method: HttpMethod, uri: string, nc: number, cnonce: string): Credentials
  • applyHttpChallenge(challenge: string, method: HttpMethod, uri: string): Credentials
  • applyHttpChallenge(challenge: string): Credentials
  • Applies the HTTP Authorization challenge to this Credential instance. The internal state can change to reflect the extra properties the challenge conveys.

    See https://tools.ietf.org/html/rfc7235 for more information.

    Parameters

    • challenge: string
    • method: HttpMethod
    • uri: string
    • nc: number
    • cnonce: string

    Returns Credentials

  • Applies the HTTP Authorization challenge to this Credential instance. The internal state can change to reflect the extra properties the challenge conveys.

    See https://tools.ietf.org/html/rfc7235 for more information.

    Parameters

    • challenge: string
    • method: HttpMethod
    • uri: string

    Returns Credentials

  • Applies the HTTP Authorization challenge to this Credential instance. The internal state can change to reflect the extra properties the challenge conveys.

    See https://tools.ietf.org/html/rfc7235 for more information.

    Parameters

    • challenge: string

    Returns Credentials

checkValid

  • checkValid<V>(arg: V): void
  • Implementors should override this method to perform validation. An argument is allowed to allow custom validation, for example, when given a configuration property, a specific property may be allowed to be null.

    Type parameters

    • V

    Parameters

    • arg: V

    Returns void

toHttpAuthorization

  • toHttpAuthorization(): string
  • Encodes this credential as an HTTP Authorization https://tools.ietf.org/html/rfc7235.

    Calls to this method, expect that {@link Credentials#applyHttpChallenge} has been prior executed. For some Authentication schemes, this isn't a requirement but doing so ensures that the object is on the right state.

    Returns string

toJson

  • toJson(): {}
  • Simple interop to downcast back to JSON for backwards compatibility.

    Returns {}

    • [key: string]: any

Generated using TypeDoc