Auth
[ class tree: Auth ] [ index: Auth ] [ all elements ]

Class: Auth_Container_Multiple

Source Location: /Auth-1.6.4/Auth/Container/Multiple.php

Class Overview

Auth_Container
   |
   --Auth_Container_Multiple

Storage driver for using multiple storage drivers in a fall through fashion


Author(s):

Version:

  • Release: @package_version@ File: $Revision: 289653 $

Copyright:

  • 2001-2006 The PHP Group

Variables

Methods


Inherited Variables

Inherited Methods

Class: Auth_Container

Auth_Container::Auth_Container()
Constructor
Auth_Container::addUser()
Add a new user to the storage container
Auth_Container::changePassword()
Change password for user in the storage container
Auth_Container::fetchData()
Fetch data from storage container
Auth_Container::getCryptType()
Returns the crypt current crypt type of the container
Auth_Container::getUser()
Returns a user assoc array
Auth_Container::listUsers()
List all users that are available from the storage container
Auth_Container::log()
Log a message to the Auth log
Auth_Container::removeUser()
Remove user from the storage container
Auth_Container::supportsChallengeResponse()
Returns true if the container supports Challenge Response
Auth_Container::verifyPassword()
Crypt and verfiy the entered password

Class Details

[line 80]
Storage driver for using multiple storage drivers in a fall through fashion

This storage driver provides a mechanism for working through multiple storage drivers until either one allows successful login or the list is exhausted.

This container takes an array of options of the following form:

array( array( 'type' => <standard container type name>, 'options' => <normal array of options for container>, ), );

Full example:

$options = array( array( 'type' => 'DB', 'options' => array( 'dsn' => "mysql://user:password@localhost/database", ), ), array( 'type' => 'Array', 'options' => array( 'cryptType' => 'md5', 'users' => array( 'admin' => md5('password'), ), ), ), );

$auth = new Auth('Multiple', $options);

  • Author: Adam Ashley <aashley@php.net>
  • Version: Release: @package_version@ File: $Revision: 289653 $
  • Copyright: 2001-2006 The PHP Group
  • Since: File available since Release 1.5.0
  • License: PHP License 3.01


[ Top ]


Class Variables

$containers = array()

[line 96]

The instanciated containers

Type:   array


[ Top ]

$options = array()

[line 89]

The options for each container

Type:   array


[ Top ]



Method Detail

Auth_Container_Multiple (Constructor)   [line 107]

void Auth_Container_Multiple( $options, array $data)

Constructor for Array Container

Parameters:

array   $data   —  Options for the container
   $options   — 

[ Top ]

fetchData   [line 138]

boolean|PEAR_Error fetchData( string $user, string $pass)

Get user information from array

This function uses the given username to fetch the corresponding login data from the array. If an account that matches the passed username and password is found, the function returns true. Otherwise it returns false.

  • Return: Error object or boolean

Overrides Auth_Container::fetchData() (Fetch data from storage container)

Parameters:

string   $user   —  Username
string   $pass   —  Password

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:41:38 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.