Overview

Packages

  • Gollem
  • None

Classes

  • Gollem
  • Gollem_Ajax_Application
  • Gollem_Api
  • Gollem_Auth
  • Gollem_Exception
  • Gollem_Factory_Vfs
  • Gollem_Factory_VfsDefault
  • Gollem_LoginTasks_SystemTask_Upgrade
  • Gollem_Test
  • Overview
  • Package
  • Class
  • Tree

Class Gollem_Auth

The Gollem_Auth class provides authentication for Gollem.

Copyright 2004-2012 Horde LLC (http://www.horde.org/)

See the enclosed file COPYING for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.

Package: Gollem
Author: Michael Slusarz slusarz@horde.org
Author: Jan Schneider jan@horde.org
Located at Auth.php
Methods summary
public static mixed
# authenticate( array $credentials = array() )

Authenticate to the backend.

Authenticate to the backend.

Parameters

$credentials
<p>An array of login credentials. If empty, attempts to login to the cached session.</p> <pre><span class="php-quote">'password'</span> - (string) The user password. <span class="php-quote">'backend'</span> - (string) The backend <span class="php-keyword2">key</span> to <span class="php-keyword1">use</span> (from backends.php). <span class="php-quote">'userId'</span> - (string) The username.</pre>

Returns

mixed

If authentication was successful, and no session exists, an array of data to add to the session. Otherwise returns false.

Throws

Horde_Auth_Exception
public static mixed
# transparent( Horde_Auth_Application $auth_ob )

Perform transparent authentication.

Perform transparent authentication.

Parameters

$auth_ob
The authentication object.

Returns

mixed

If authentication was successful, and no session exists, an array of data to add to the session. Otherwise returns false.

public static mixed
# getBackend( string $backend = null )

Loads the Gollem backend configuration from backends.php.

Loads the Gollem backend configuration from backends.php.

Parameters

$backend
Returns this labeled entry only.

Returns

mixed

If $backend is set return this entry; else, return the entire backends array. Returns false on error.

public static string
# getPreferredBackend( )

Get the current preferred backend key.

Get the current preferred backend key.

Returns

string
The preferred backend key.
public static string
# getAutologinID( string $backend )

Get the authentication ID to use for autologins based on the value of the 'hordeauth' parameter.

Get the authentication ID to use for autologins based on the value of the 'hordeauth' parameter.

Parameters

$backend
The backend to login to.

Returns

string
The ID string to use for logins.
public static array
# canAutoLogin( string $key = null, boolean $force = false )

Can we log in without a login screen for the requested backend key?

Can we log in without a login screen for the requested backend key?

Parameters

$key
<p>The backend key to check. Defaults to self::getPreferredBackend().</p>
$force
<p>If true, check the backend key even if there is more than one backend.</p>

Returns

array

The credentials needed to login ('userId', 'password', 'backend') or false if autologin not available.

public static
# changeBackend( string $key )

Change the currently active backend.

Change the currently active backend.

Parameters

$key
The ID of the backend to set as active.
API documentation generated by ApiGen