root / drupal7 / sites / all / modules / ldap / ldap_servers / ldap_types / LdapTypeAbstract.class.php @ fc2c1c7a
1 |
<?php
|
---|---|
2 |
|
3 |
/**
|
4 |
* @file
|
5 |
* abstract class to represent an ldap implementation type
|
6 |
* such as active directory, open ldap, novell, etc.
|
7 |
*
|
8 |
*/
|
9 |
|
10 |
abstract class LdapTypeAbstract { |
11 |
|
12 |
public $name; |
13 |
public $typeId; |
14 |
public $description; |
15 |
|
16 |
// ldap_servers configuration
|
17 |
public $port = 389; |
18 |
public $tls = 0; |
19 |
public $encrypted = 0; |
20 |
public $user_attr = 'cn'; |
21 |
public $mail_attr = 'mail'; |
22 |
public $groupObjectClassDefault = NULL; |
23 |
public $groupDerivationModelDefault = NULL; |
24 |
|
25 |
// ldap_authorization configuration
|
26 |
public $deriveFromDn = FALSE; |
27 |
public $deriveFromAttr = FALSE; |
28 |
public $deriveFromEntry = FALSE; |
29 |
public $groupMembershipsAttr = NULL; |
30 |
public $groupMembershipsAttrMatchingUserAttr = FALSE; // can be removed in 2.0 branch |
31 |
|
32 |
/**
|
33 |
* Constructor Method
|
34 |
*
|
35 |
*/
|
36 |
function __construct($params = array()) { |
37 |
foreach ($params as $k => $v) { |
38 |
if (property_exists($this, $k)) { |
39 |
$this->{$k} = $v; |
40 |
} |
41 |
} |
42 |
} |
43 |
|
44 |
|
45 |
|
46 |
|
47 |
} |