package Default
inherited_from \Zend\Authentication\Adapter\DbTable\AbstractAdapter

 Methods

__construct() - Sets configuration options

__construct(\Zend\Db\Adapter\Adapter $zendDb, string $tableName = null, string $identityColumn = null, string $credentialColumn = null, string $credentialTreatment = null
inherited_from \Zend\Authentication\Adapter\DbTable\AbstractAdapter::__construct()

Parameters

$zendDb

\Zend\Db\Adapter\Adapter

$tableName

string

Optional

$identityColumn

string

Optional

$credentialColumn

string

Optional

$credentialTreatment

string

Optional

__construct() - Sets configuration options

__construct(\Zend\Db\Adapter\Adapter $zendDb, string $tableName = null, string $identityColumn = null, string $credentialColumn = null
Inherited

Parameters

$zendDb

\Zend\Db\Adapter\Adapter

$tableName

string

Optional

$identityColumn

string

Optional

$credentialColumn

string

Optional

This method is called to attempt an authentication. Previous to this call, this adapter would have already been configured with all necessary information to successfully connect to a database table and attempt to find a record matching the provided identity.

authenticate() : \Zend\Authentication\Result
Inherited

Exceptions

\Zend\Authentication\Adapter\DbTable\Exception\RuntimeException if answering the authentication query is impossible

Returns

\Zend\Authentication\Result

getAmbiguityIdentity() - returns TRUE for usage of multiple identical identities with different credentials, FALSE if not used.

getAmbiguityIdentity() : boolean
Inherited

Returns

boolean

Returns the credential of the account being authenticated, or NULL if none is set.

getCredential() : mixed
Inherited
inherited_from \Zend\Authentication\Adapter\ValidatableAdapterInterface::getCredential()

Returns

mixed

getDbSelect() - Return the preauthentication Db Select object for userland select query modification

getDbSelect() : \Zend\Db\Sql\Select
Inherited

Returns

\Zend\Db\Sql\Select

Returns the identity of the account being authenticated, or NULL if none is set.

getIdentity() : mixed
Inherited
inherited_from \Zend\Authentication\Adapter\ValidatableAdapterInterface::getIdentity()

Returns

mixed

getResultRowObject() - Returns the result row as a stdClass object

getResultRowObject(string|array $returnColumns = null, string|array $omitColumns = null) : \stdClass | boolean
Inherited

Parameters

$returnColumns

stringarray

$omitColumns

stringarray

Returns

\stdClassboolean

setAmbiguityIdentity() - sets a flag for usage of identical identities with unique credentials. It accepts integers (0, 1) or boolean (true, false) parameters. Default is false.

setAmbiguityIdentity(integer|boolean $flag) : \Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapter
Inherited
fluent This method is part of a fluent interface and will return the same instance

Parameters

$flag

integerboolean

Returns

\Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapterProvides a fluent interface

Sets the credential for binding

setCredential(mixed $credential) : \Zend\Authentication\Adapter\AbstractAdapter
Inherited
inherited_from \Zend\Authentication\Adapter\ValidatableAdapterInterface::setCredential()

Parameters

$credential

mixed

Returns

\Zend\Authentication\Adapter\AbstractAdapter

setCredentialColumn() - set the column name to be used as the credential column

setCredentialColumn(string $credentialColumn) : \Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapter
Inherited
fluent This method is part of a fluent interface and will return the same instance

Parameters

$credentialColumn

string

Returns

\Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapterProvides a fluent interface

setCredentialTreatment() - allows the developer to pass a parametrized string that is used to transform or treat the input credential data.

setCredentialTreatment(string $treatment) : \Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapter

In many cases, passwords and other sensitive data are encrypted, hashed, encoded, obscured, or otherwise treated through some function or algorithm. By specifying a parametrized treatment string with this method, a developer may apply arbitrary SQL upon input credential data.

Examples:

'PASSWORD(?)' 'MD5(?)'

fluent This method is part of a fluent interface and will return the same instance

Parameters

$treatment

string

Returns

\Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapterProvides a fluent interface

Sets the identity for binding

setIdentity(mixed $identity) : \Zend\Authentication\Adapter\AbstractAdapter
Inherited
inherited_from \Zend\Authentication\Adapter\ValidatableAdapterInterface::setIdentity()

Parameters

$identity

mixed

Returns

\Zend\Authentication\Adapter\AbstractAdapter

setIdentityColumn() - set the column name to be used as the identity column

setIdentityColumn(string $identityColumn) : \Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapter
Inherited
fluent This method is part of a fluent interface and will return the same instance

Parameters

$identityColumn

string

Returns

\Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapterProvides a fluent interface

setTableName() - set the table name to be used in the select query

setTableName(string $tableName) : \Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapter
Inherited
fluent This method is part of a fluent interface and will return the same instance

Parameters

$tableName

string

Returns

\Zend\Authentication\Adapter\DbTable\CredentialTreatmentAdapterProvides a fluent interface

Creates a Zend\Authentication\Result object from the information that has been collected during the authenticate() attempt.

authenticateCreateAuthResult() : \Zend\Authentication\Result
Inherited

Returns

\Zend\Authentication\Result

_authenticateCreateSelect() - This method creates a Zend\Db\Sql\Select object that is completely configured to be queried against the database.

authenticateCreateSelect() : \Zend\Db\Sql\Select
inherited_from \Zend\Authentication\Adapter\DbTable\AbstractAdapter::authenticateCreateSelect()

Returns

\Zend\Db\Sql\Select

_authenticateCreateSelect() - This method creates a Zend\Db\Sql\Select object that is completely configured to be queried against the database.

authenticateCreateSelect() : \Zend\Db\Sql\Select
Inherited

Returns

\Zend\Db\Sql\Select

_authenticateQuerySelect() - This method accepts a Zend\Db\Sql\Select object and performs a query against the database with that object.

authenticateQuerySelect(\Zend\Db\Sql\Select $dbSelect) : array
Inherited

Parameters

$dbSelect

\Zend\Db\Sql\Select

Exceptions

\Zend\Authentication\Adapter\DbTable\Exception\RuntimeException when an invalid select object is encountered

Returns

array

_authenticateSetup() - This method abstracts the steps involved with making sure that this adapter was indeed setup properly with all required pieces of information.

authenticateSetup() : boolean
Inherited

Exceptions

\Zend\Authentication\Adapter\DbTable\Exception\RuntimeException in the event that setup was not done properly

Returns

boolean

_authenticateValidateResult() - This method attempts to validate that the record in the resultset is indeed a record that matched the identity provided to this adapter.

authenticateValidateResult(array $resultIdentity) : \Zend\Authentication\Result
inherited_from \Zend\Authentication\Adapter\DbTable\AbstractAdapter::authenticateValidateResult()

Parameters

$resultIdentity

array

Returns

\Zend\Authentication\Result

_authenticateValidateResult() - This method attempts to validate that the record in the resultset is indeed a record that matched the identity provided to this adapter.

authenticateValidateResult(array $resultIdentity) : \Zend\Authentication\Result
Inherited

Parameters

$resultIdentity

array

Returns

\Zend\Authentication\Result

_authenticateValidateResultSet() - This method attempts to make certain that only one record was returned in the resultset

authenticateValidateResultSet(array $resultIdentities) : boolean | \Zend\Authentication\Result
Inherited

Parameters

$resultIdentities

array

Returns

boolean\Zend\Authentication\Result

 Properties

 

$ambiguityIdentity - Flag to indicate same Identity can be used with different credentials. Default is FALSE and need to be set to true to allow ambiguity usage.

$ambiguityIdentity : boolean

Default

false
 

$authenticateResultInfo

$authenticateResultInfo : array

Default

null
 

$credential

$credential : mixed

Default

 

$credentialColumns - columns to be used as the credentials

$credentialColumn : string

Default

null
 

$credentialTreatment - Treatment applied to the credential, such as MD5() or PASSWORD()

$credentialTreatment : string

Default

null
 

$dbSelect

$dbSelect : \Zend\Db\Sql\Select

Default

null
 

$identity

$identity : mixed

Default

 

$identityColumn - the column to use as the identity

$identityColumn : string

Default

null
 

$resultRow - Results of database authentication query

$resultRow : array

Default

null
 

$tableName - the table name to check

$tableName : string

Default

null
 

Database Connection

$zendDb : \Zend\Db\Adapter\Adapter

Default

null