library/Extlib/Auth/Adapter/Doctrine2.php
public function authenticate()
    {
        $this->_authenticateSetup();
        $dqlQuery = $this->_authenticateCreateSelect();
        $resultIdentities = $this->_authenticateQueryDql($dqlQuery);

        if (($authResult = $this->_authenticateValidateResultset($resultIdentities)) instanceof \Zend_Auth_Result) {
            return $authResult;
        }

        if (true === $this->getAmbiguityIdentity()) {
            $validIdentities = array();
            foreach ($resultIdentities as $identity) {
                if (1 === (int) $identity['zend_auth_credential_match']) {
                    $validIdentities[] = $identity;
                }
            }
            $resultIdentities = $validIdentities;
        }

        $authResult = $this->_authenticateValidateResult(array_shift($resultIdentities));
        return $authResult;
    }
public function authenticate()
    {
        $this->_authenticateSetup();
        $dqlQuery = $this->_authenticateCreateSelect();
        $resultIdentities = $this->_authenticateQueryDql($dqlQuery);

        if (($authResult = $this->_authenticateValidateResultset($resultIdentities)) instanceof \Zend_Auth_Result) {
            return $authResult;
        }

        if (true === $this->getAmbiguityIdentity()) {
            $validIdentities = array();
            foreach ($resultIdentities as $identity) {
                if (1 === (int) $identity['zend_auth_credential_match']) {
                    $validIdentities[] = $identity;
                }
            }
            $resultIdentities = $validIdentities;
        }

        $authResult = $this->_authenticateValidateResult(array_shift($resultIdentities));
        return $authResult;
    }
public function authenticate ( ) { $ this -> _authenticateSetup ( ) ; $ dqlQuery = $ this -> _authenticateCreateSelect ( ) ; $ resultIdentities = $ this -> _authenticateQueryDql ( $ dqlQuery ) ; if ( ( $ authResult = $ this -> _authenticateValidateResultset ( $ resultIdentities ) ) instanceof \ Zend_Auth_Result ) { return $ authResult ; } if ( true === $ this -> getAmbiguityIdentity ( ) ) { $ validIdentities = array ( ) ; foreach ( $ resultIdentities as $ identity ) { if ( 1 === ( int ) $ identity [ 'zend_auth_credential_match' ] ) { $ validIdentities [ ] = $ identity ; } } $ resultIdentities = $ validIdentities ; } $ authResult = $ this -> _authenticateValidateResult ( array_shift ( $ resultIdentities ) ) ; return $ authResult ; }
Defined by Zend_Auth_Adapter_Interface. 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.

@throws \Zend_Auth_Adapter_Exception if answering the authentication query is impossible
@return \Zend_Auth_Result
Defined by Zend_Auth_Adapter_Interface . 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 .