soup.auth

Module for [Auth] class

Types 3

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 soup.session.Session.

Methods
GType _getGType() static nothrow
GType _gType() @property nothrow
Auth self() nothrowReturns `this`, for use in `with` statements.
AuthGidBuilder builder() static nothrowGet builder for [soup.auth.Auth] Returns: New builder object
string authority() @property nothrowGet `authority` property. Returns: The authority (host:port) being authenticated to.
void authority(string propval) @property nothrowSet `authority` property. Params: propval = The authority (host:port) being authenticated to.
string realm() @property nothrowGet `realm` property. Returns: The authentication realm.
void realm(string propval) @property nothrowSet `realm` property. Params: propval = The authentication realm.
string schemeName() @property nothrowGet `schemeName` property. Returns: The authentication scheme name.
void authenticate(string username, string password) nothrowCall this on an auth to authenticate it.
bool canAuthenticate() nothrowTests if auth is able to authenticate by providing credentials to the [soup.auth.Auth.authenticate]. Returns: true if auth is able to accept credentials.
void cancel() nothrowCall this on an auth to cancel it.
string getAuthority() nothrowReturns the authority (host:port) that auth is associated with. Returns: the authority
string getAuthorization(soup.message.Message msg) nothrowGenerates an appropriate "Authorization" header for msg.
string getInfo() nothrowGets an opaque identifier for auth.
string[] getProtectionSpace(glib.uri.Uri sourceUri) nothrowReturns a list of paths on the server which auth extends over.
string getRealm() nothrowReturns auth's realm.
string getSchemeName() nothrowsoup_auth_get_scheme_name: (attributes org.gtk.Method.get_property=scheme-name) Returns auth's scheme name. (Eg, "Basic", "Digest", or "NTLM") Returns: the scheme name
bool isAuthenticated() nothrowTests if auth has been given a username and password. Returns: true if auth has been given a username and password
bool isCancelled() nothrowTests if auth has been cancelled Returns: true if auth has been cancelled
bool isForProxy() nothrowTests whether or not auth is associated with a proxy server rather than an "origin" server. Returns: true or false
bool isReady(soup.message.Message msg) nothrowTests if auth is ready to make a request for msg with.
bool update(soup.message.Message msg, string authHeader) nothrowUpdates auth with the information from msg and auth_header, possibly un-authenticating it.
Constructors
this(void * ptr, Flag!"Take" take)
this(gobject.types.GType type, soup.message.Message msg, string authHeader)Creates a new #SoupAuth of type type with the information from msg and auth_header.

Fluent builder implementation template for soup.auth.Auth

Methods
T authority(string propval) nothrowSet `authority` property. Params: propval = The authority (host:port) being authenticated to. Returns: Builder instance for fluent chaining
T realm(string propval) nothrowSet `realm` property. Params: propval = The authentication realm. Returns: Builder instance for fluent chaining

Fluent builder for soup.auth.Auth

Methods
Auth build() nothrowCreate object from builder. Returns: New object