Class Auth_passwd

Description

The Auth_passwd:: class provides a passwd-file implementation of the Horde authentication system.

Required parameters:

   'filename'  The passwd file to use.

Optional parameters:

   'encryption'       The encryption to use to store the password in
                      the table (e.g. plain, crypt, md5-hex,
                      md5-base64, smd5, sha, ssha, aprmd5).
                      DEFAULT: 'crypt-des'
   'show_encryption'  Whether or not to prepend the encryption in the
                      password field.
                      DEFAULT: 'false'
   'lock'             Should we lock the passwd file? (boolean) The password
                      file cannot be changed (add, edit, or delete users)
                      unless this is true.
                      DEFAULT: false

$Horde: framework/Auth/Auth/passwd.php,v 1.16.10.20 2009/01/06 15:22:50 jan Exp $

Copyright 1997-2007 Rasmus Lerdorf <rasmus@php.net> Copyright 2002-2009 The Horde Project (http://www.horde.org/)

See the enclosed file COPYING for license information (LGPL). If you did not receive this file, see http://opensource.org/licenses/lgpl-license.php.

Located in /Auth/Auth/passwd.php (line 36)

Auth
   |
   --Auth_passwd
Variable Summary
 array $_exclude
 integer $_fplock
 array $_groups
 boolean $_locked
 array $_users
Method Summary
 Auth_passwd Auth_passwd ([array $params = array()])
 mixed addUser (string $userId, array $credentials)
 mixed listUsers ()
 boolean removeUser (string $userId)
 mixed resetPassword (string $userId)
 mixed updateUser (string $oldID, string $newID, array $credentials)
 void _commit ()
 void _read ()
Variables
array $capabilities = array('add' => false,
'update' => false,
'resetpassword' => false,
'remove' => false,
'list' => true,
'transparent' => false)
(line 44)

An array of capabilities, so that the driver can report which operations it supports and which it doesn't.


Redefinition of:
Auth::$capabilities
An array of capabilities, so that the driver can report which operations it supports and which it doesn't.
array $_exclude = array(
'root',
'daemon',
'bin',
'sys',
'sync',
'games',
'man',
'lp',
'mail',
'news',
'uucp',
'proxy',
'postgres',
'www-data',
'backup',
'operator',
'list',
'irc',
'gnats',
'nobody',
'identd',
'sshd',
'gdm',
'postfix',
'mysql',
'cyrus',
'ftp',
)
(line 85)

List of users that should be excluded from being listed/handled in any way by this driver.

integer $_fplock (line 70)

Filehandle for lockfile.

array $_groups = array() (line 63)

Array of groups and members.

boolean $_locked (line 77)

Locking state.

array $_users = null (line 56)

Hash list of users.

Inherited Variables

Inherited from Auth

Auth::$_authCredentials
Auth::$_params
Methods
Constructor Auth_passwd (line 120)

Constructs a new Passwd authentication object.

Auth_passwd Auth_passwd ([array $params = array()])
  • array $params: A hash containing connection parameters.
addUser (line 317)

Add a set of authentication credentials.

  • return: True on success or a PEAR_Error object on failure.
mixed addUser (string $userId, array $credentials)
  • string $userId: The userId to add.
  • array $credentials: The credentials to add.

Redefinition of:
Auth::addUser()
Adds a set of authentication credentials.
listUsers (line 290)

List all users in the system.

  • return: The array of userIds, or a PEAR_Error object on failure.
mixed listUsers ()

Redefinition of:
Auth::listUsers()
Lists all users in the system.
removeUser (line 389)

Delete a set of authentication credentials.

  • return: Success or failure.
boolean removeUser (string $userId)
  • string $userId: The userId to delete.

Redefinition of:
Auth::removeUser()
Deletes a set of authentication credentials.
resetPassword (line 370)

Reset a user's password. Used for example when the user does not remember the existing password.

  • return: The new password on success or a PEAR_Error object on failure.
mixed resetPassword (string $userId)
  • string $userId: The user id for which to reset the password.
updateUser (line 341)

Update a set of authentication credentials.

  • return: True on success or a PEAR_Error object on failure.
mixed updateUser (string $oldID, string $newID, array $credentials)
  • string $oldID: The old userId.
  • string $newID: The new userId.
  • array $credentials: The new credentials

Redefinition of:
Auth::updateUser()
Updates a set of authentication credentials.
_commit (line 409)

Writes changes to passwd file and unlocks it. Takes no arguments and has no return value. Called on script shutdown.

void _commit ()
_read (line 145)

Read and, if requested, lock the password file.

void _read ()

Inherited Methods

Inherited From Auth

 Auth::addHook()
 Auth::addLogoutParameters()
 Auth::addUser()
 Auth::authenticate()
 Auth::clearAuth()
 Auth::exists()
 Auth::factory()
 Auth::genRandomPassword()
 Auth::getAuth()
 Auth::getAuthDomain()
 Auth::getBareAuth()
 Auth::getCredential()
 Auth::getCryptedPassword()
 Auth::getDriver()
 Auth::getLoginScreen()
 Auth::getLogoutReason()
 Auth::getLogoutReasonString()
 Auth::getParam()
 Auth::getProvider()
 Auth::getSalt()
 Auth::hasCapability()
 Auth::isAdmin()
 Auth::isAuthenticated()
 Auth::isPasswordChangeRequested()
 Auth::listUsers()
 Auth::readSessionData()
 Auth::removeHook()
 Auth::removeUser()
 Auth::removeUserData()
 Auth::setAuth()
 Auth::setCredential()
 Auth::singleton()
 Auth::transparent()
 Auth::updateUser()
 Auth::_authenticate()
 Auth::_isAdmin()

Documentation generated on Sun, 30 Jan 2011 05:20:19 +0000 by phpDocumentor 1.4.3