phpdoc
authorMichael M Slusarz <slusarz@curecanti.org>
Tue, 3 Aug 2010 05:44:34 +0000 (23:44 -0600)
committerMichael M Slusarz <slusarz@curecanti.org>
Tue, 3 Aug 2010 05:44:34 +0000 (23:44 -0600)
framework/Auth/lib/Horde/Auth/Ldap.php
framework/Prefs/lib/Horde/Prefs/Ldap.php

index 6c3cc40..97c3946 100644 (file)
@@ -43,16 +43,15 @@ class Horde_Auth_Ldap extends Horde_Auth_Base
      * Constructor.
      *
      * @param array $params  Required parameters:
-     *                       - basedn (string): The base DN for the LDAP server.
-     *                       - ldap (Horde_Ldap): Horde LDAP object.
-     *                       - uid (string): The username search key.
-     *                       Optional parameters:
-     *                       - filter (string): The LDAP formatted search filter
-     *                         to search for users. This setting overrides the
-     *                         'objectclass' method below.
-     *                       - objectclass (string|array): The objectclass
-     *                         filter used to search for users. Either a single
-     *                         or an array of objectclasses.
+     * <pre>
+     * 'basedn' - (string) [REQUIRED] The base DN for the LDAP server.
+     * 'filter' - (string) The LDAP formatted search filter to search for
+     *            users. This setting overrides the 'objectclass' parameter.
+     * 'ldap' - (Horde_Ldap) [REQUIRED] Horde LDAP object.
+     * 'objectclass - (string|array): The objectclass filter used to search
+     *                for users. Either a single or an array of objectclasses.
+     * 'uid' - (string) [REQUIRED] The username search key.
+     * </pre>
      *
      * @throws Horde_Auth_Exception
      * @throws InvalidArgumentException
index 60ba943..74000e2 100644 (file)
@@ -2,43 +2,6 @@
 /**
  * Preferences storage implementation for PHP's LDAP extension.
  *
- * Required parameters:
- * - basedn:   The base DN for the LDAP server.
- * - hostspec: The hostname of the LDAP server.
- * - uid:      The username search key.
- * - writeas:  One of "user", "admin", or "search"
- *
- * Optional parameters:
- * - binddn:   The DN of the administrative account to bind for write
- *             operations.
- * - bindpw:   'binddn's password for bind authentication.
- * - port:     The port of the LDAP server. DEFAULT: 389
- * - searchdn: The DN of a user with search permissions on the directory
- * - searchpw: 'searchdn's password for binding
- * - tls:      Whether to use TLS connections. DEFAULT: false
- * - version:  The version of the LDAP protocol to use.
- *             DEFAULT: NONE (system default will be used)
- *
- * If setting up as the Horde preference handler in conf.php, the following
- * is an example configuration.
- * The schemas needed for ldap are in horde/scripts/ldap.
- *
- * <code>
- * $conf['prefs']['driver'] = 'ldap';
- * $conf['prefs']['params']['hostspec'] = 'localhost';
- * $conf['prefs']['params']['port'] = '389';
- * $conf['prefs']['params']['basedn'] = 'dc=example,dc=org';
- * $conf['prefs']['params']['uid'] = 'mail';
- * </code>
- *
- * The following is valid but would only be necessary if users do NOT have
- * permission to modify their own LDAP accounts.
- *
- * <code>
- * $conf['prefs']['params']['binddn'] = 'cn=Manager,dc=example,dc=org';
- * $conf['prefs']['params']['bindpw'] = 'password';
- * </code>
- *
  * Copyright 1999-2010 The Horde Project (http://www.horde.org/)
  *
  * See the enclosed file COPYING for license information (LGPL). If you
@@ -77,8 +40,27 @@ class Horde_Prefs_Ldap extends Horde_Prefs
      *
      * @param string $scope  The scope for this set of preferences.
      * @param array $opts    See factory() for list of options.
-     * @param array $params  A hash containing any additional configuration
-     *                       or connection parameters a subclass might need.
+     * @param array $params  Additional configuration options:
+     * <pre>
+     * basedn - (string) [REQUIRED] The base DN for the LDAP server.
+     * hostspec - (string) [REQUIRED] The hostname of the LDAP server.
+     * uid - (string) [REQUIRED] The username search key.
+     * writeas - (string) [REQUIRED] One of "user", "admin", or "search"
+     *
+     * Optional parameters:
+     * binddn - (string) The DN of the administrative account to bind for
+     *          write operations.
+     * bindpw - (string) binddn's password for bind authentication.
+     * port - (integer) The port of the LDAP server.
+     *        DEFAULT: 389
+     * searchdn - (string) The DN of a user with search permissions on the
+     *            directory.
+     * searchpw - (string) searchdn's password for binding.
+     * tls - (boolean) Whether to use TLS connections.
+     *       DEFAULT: false
+     * version - (integer) The version of the LDAP protocol to use.
+     *           DEFAULT: NONE (system default will be used)
+     * </pre>
      */
     protected function __construct($scope, $opts, $params);
     {