Indy 9
TIdAuthentication
Hierarchy, Properties, Methods, See Also, Unit: IdAuthentication
Ancestor for authentication classes in the Indy authentication framework.
TIdAuthentication = class(TPersistent)
Unit
IdAuthentication
Description
TIdAuthentication is a TPersistent descendant, and an ancestor class that specifies the properties and methods available in the Indy authentication framework. TIdAuthentication represents the common functionality needed to implement the authentication methods described in the Internet Standards documents:

  • RFC 2616 - Hypertext Transfer Protocol [HTTP/1.1] (http://www.rfc-editor.org/rfc/rfc2616.txt)

  • RFC 2617 - HTTP Authentication: Basic and Digest Access Authentication (http://www.rfc-editor.org/rfc/rfc2617.txt)

Applications should create instances of descendant classes that implement the specifics described in the preceeding documents, such as TIdBasicAuthentication and TIdDigestAuthentication.


TIdAuthentication.AuthParams
TIdAuthentication, See Also
Represents authentication parameters to be used for the process.
property AuthParams: TIdHeaderList;
Description
AuthParams is a TIdHeaderList property that represents authentication parameters to be used for the authentication process. AuthParams normally contains the value of the WWWAuthenticate in the TIdRequestHeaderInfo that triggered the authentication process.

TIdAuthentication.CurrentStep
TIdAuthentication, See Also
Identifies the current task number during authentication processing.
property CurrentStep: Integer;
Description
CurrentStep is a read-only Integer property used to identify the active task during reading of authentication information. CurrentStep contains the value 0 (zero) when Username and Password values have not been examined for the corresponding TIdAuthWhatsNext value. CurrentStep contains the value 1 (one) when the current authentication process has failed.

The default value for CurrentStep is 0 (zero) as assigned in the Create constructor. CurrentStep is also set to the default value in the Reset method.


TIdAuthentication.Params
TIdAuthentication, See Also
Contains authentication parameters for the mechanism.
property Params: TIdHeaderList;
Description
Params is a read-only TIdHeaderList property used to represent common parameter values for the authentication mechanism. Params is used to store the Username and Password property values used during execution of the authorization process. Params is also used in descendant classes for values specific to the enhanced authentication functionality.

TIdAuthentication.Password
TIdAuthentication, See Also
Represents the authorization credentials for the authentication process.
property Password: String;
Description
Password is a String property that represents the authorization credentials used in the authentication process. Use Username to specify the identity used for the authentication process.

TIdAuthentication.Steps
TIdAuthentication
Number of tasks required for the authentication process.
property Steps: Integer;
Description
Steps is a read-only Integer property that represents the number of tasks needed to perform the authentication process. The default value returned for the Steps property is 0.

TIdAuthentication.Username
TIdAuthentication, See Also
Represents the authorization identity for the authentication process.
property Username: String;
Description
Username is a String property that represents the authorization identity used in the authentication process. Use Password to specify the credential used for the authentication process.

TIdAuthentication.Authentication
TIdAuthentication
Represents the authentication method name to use.
function Authentication: String; virtual; abstract;
Return Value
String - Authentication method Name for the object instance.
Description
Authentication is an abstract virtual String function that represents the authentication method name to use.

TIdAuthentication.Create
TIdAuthentication, See Also
Constructor for the object instance.
constructor Create; virtual;
Description
Create is the constructor for the object instance. Create relies on the inherited Create method. Create allocates resources required for the Params property, and sets the default value for CurrentStep to 0.

TIdAuthentication.Destroy
TIdAuthentication, See Also
Frees the object instance.
destructor Destroy; override;
Description
Destroy is the destructor for the object instance. Destroy clears the AuthParams, if values have been assigned to the property, prior to calling the inherited Destroy method.

TIdAuthentication.KeepAlive
TIdAuthentication, See Also
Indicates that Keep-Alive signals are supported for the authentication mechanism.
function KeepAlive: Boolean; virtual; abstract;
Description
KeepAlive is an abstract virtual Boolean function that specifies the function used to indicate if the authentication mechanism supports use of the KEEP-ALIVE header. Descendant classes, like TIdBasicAuthentication, must implement the KeepAlive function to indicate if the mechanism can be used to prevent loss of a connection during authentication processing.

TIdAuthentication.Next
TIdAuthentication, See Also
Identifies the next action in the authentication process.
function Next: TIdAuthWhatsNext;
Return Value
TIdAuthWhatsNext - Next action in the authentication process.
Description
Next is a TIdAuthWhatsNext function that identifies the next action that should be performed in the authentication process. Next will increment the the value of Retries when the return value is wnDoRequest.

Next is used in TIdHTTP.OnAuthorization to determine the action to be taken by the user agent.


TIdAuthentication.Reset
TIdAuthentication, See Also
Clears the number of retries for the authentication mechanism.
procedure Reset; virtual;
Description
Reset is a virtual procedure that clears the number of retry attempts performed using the authentication mechanism. In TIdAuthentication, Reset is an empty implementation. Descendant classes, like TIdBasicAuthentication will override Reset to perform the functionality specific to the authentication mechanism.

Created with Doc-O-Matic 2 donated to Project JEDI. Commercial license available from the Doc-O-Matic site.