Beispiel #1
0
 /**
  * Initializes the LDAP Driver
  *
  * @return  void
  */
 public function __construct($params)
 {
     self::$_params = $params;
     self::$_connection = ldap_connect(self::$_params["url"]);
     ldap_set_option(self::$_connection, LDAP_OPT_PROTOCOL_VERSION, 3);
     ldap_bind(self::$_connection);
 }
Beispiel #2
0
 /**
  * Initializes the LDAP Driver
  *
  * @return  void
  */
 public function __construct($params)
 {
     self::$_params = $params;
     self::$_connection = ldap_connect(self::$_params["url"]);
     ldap_set_option(self::$_connection, LDAP_OPT_PROTOCOL_VERSION, 3);
     if (self::$_params["bind_rdn"]) {
         ldap_bind(self::$_connection, self::$_params["bind_rdn"], self::$_params["bind_password"]);
     } else {
         ldap_bind(self::$_connection);
     }
 }
Beispiel #3
0
 /**
  * Initializes the LDAP Driver
  *
  * @return  void
  */
 public function __construct($params)
 {
     self::$_params = $params;
     if (!in_array(self::$_params["everybody_group"], self::$_params["groups"]) || !in_array(self::$_params["registered_users_group"], self::$_params["groups"])) {
         throw new Exception("Module ldap: Values of parameters \"everybody_group\" and \"registered_users_group\" must be listed in parameter \"groups\"!");
     }
     self::$_connection = ldap_connect(self::$_params["url"]);
     ldap_set_option(self::$_connection, LDAP_OPT_PROTOCOL_VERSION, 3);
     if (self::$_params["bind_rdn"]) {
         ldap_bind(self::$_connection, self::$_params["bind_rdn"], self::$_params["bind_password"]);
     } else {
         ldap_bind(self::$_connection);
     }
 }