Interface nsIAuthInformationType

A object that hold authentication information. The caller of nsIAuthPrompt2::promptUsernameAndPassword or nsIAuthPrompt2::promptPasswordAsync provides an object implementing this interface; the prompt implementation can then read the values here to prefill the dialog. After the user entered the authentication information, it should set the attributes of this object to indicate to the caller what was entered by the user.

Hierarchy

Properties

authenticationScheme: string

The authentication scheme used for this request, if applicable. If the protocol for this authentication does not support schemes, this will be the empty string. Otherwise, this will be a string such as "basic" or "digest". This string will always be in lowercase.

domain: string

The initial value should be used to prefill the dialog or be shown in some other way to the user. On return, this parameter should contain the domain entered by the user. This attribute is only used if flags include #NEED_DOMAIN.

flags: number

@} Flags describing this dialog. A bitwise OR of the flag values above.

It is possible that neither #AUTH_HOST nor #AUTH_PROXY are set.

Auth prompts should ignore flags they don't understand; especially, they should not throw an exception because of an unsupported flag.

password: string

The initial value should be used to prefill the dialog or be shown in some other way to the user. The password should not be shown in clear. On return, this parameter should contain the password entered by the user.

realm: string

The server-supplied realm of the authentication as defined in RFC 2617. Can be the empty string if the protocol does not support realms. Otherwise, this is a human-readable string like "Secret files".

username: string

The initial value should be used to prefill the dialog or be shown in some other way to the user. On return, this parameter should contain the username entered by the user. This field can only be changed if the #ONLY_PASSWORD flag is not set.

Methods

  • Increases the reference count for this interface. The associated instance will not be deleted unless the reference count is returned to zero.

    Returns

    The resulting reference count.

    Returns number

  • Parameters

    • aIID: object
    • Optional aInstancePtr: object

    Returns any

  • A run time mechanism for interface discovery.

    Returns

    NS_OK if the interface is supported by the associated instance, NS_NOINTERFACE if it is not.

    aInstancePtr must not be null.

    Parameters

    • aIID: object

      [in] A requested interface IID

    • aInstancePtr: object

      [out] A pointer to an interface pointer to receive the result.

    Returns void

  • Decreases the reference count for this interface. Generally, if the reference count returns to zero, the associated instance is deleted.

    Returns

    The resulting reference count.

    Returns number

Generated using TypeDoc