Auth

open class Auth(pointer: <Error class: unknown class><<Error class: unknown class>>)

The abstract base class for handling authentication.

Specific HTTP Authentication mechanisms are implemented by its subclasses, but applications never need to be aware of the specific subclasses being used.

#SoupAuth objects store the authentication data associated with a given bit of web space. They are created automatically by class@Session.

Skipped during bindings generation

  • method is-authenticated: Property has no getter nor setter

  • method is-cancelled: Property has no getter nor setter

  • method is-for-proxy: Property has no getter nor setter

Constructors

Link copied to clipboard
constructor(type: <Error class: unknown class>, msg: Message, authHeader: String)

Creates a new #SoupAuth of type @type with the information from

constructor(pointer: <Error class: unknown class><<Error class: unknown class>>)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open val authority: String

The authority (host:port) being authenticated to.

Link copied to clipboard
open val realm: String

The authentication realm.

Link copied to clipboard
open val schemeName: String

The authentication scheme name.

Link copied to clipboard
val soupAuthPointer: <Error class: unknown class><<Error class: unknown class>>

Functions

Link copied to clipboard
open fun authenticate(username: String, password: String)

Call this on an auth to authenticate it.

Link copied to clipboard

Tests if @auth is able to authenticate by providing credentials to the method@Auth.authenticate.

Link copied to clipboard
open fun cancel()

Call this on an auth to cancel it.

Link copied to clipboard
open fun freeProtectionSpace(space: <Error class: unknown class>)

Frees @space.

Link copied to clipboard

Generates an appropriate "Authorization" header for @msg.

Link copied to clipboard
open fun getInfo(): String

Gets an opaque identifier for @auth.

Link copied to clipboard
open fun getProtectionSpace(sourceUri: <Error class: unknown class>): <Error class: unknown class>

Returns a list of paths on the server which @auth extends over.

Link copied to clipboard

Tests if @auth has been given a username and password.

Link copied to clipboard
open fun isCancelled(): Boolean

Tests if @auth has been cancelled

Link copied to clipboard
open fun isForProxy(): Boolean

Tests whether or not @auth is associated with a proxy server rather than an "origin" server.

Link copied to clipboard
open fun isReady(msg: Message): Boolean

Tests if @auth is ready to make a request for @msg with.

Link copied to clipboard
open fun update(msg: Message, authHeader: String): Boolean

Updates @auth with the information from @msg and @auth_header, possibly un-authenticating it.