Révision 32700c57
Ajouté par Assos Assos il y a environ 5 ans
drupal7/sites/all/modules/ldap/ldap_test/ldap_servers.conf.inc | ||
---|---|---|
2 | 2 |
|
3 | 3 |
/** |
4 | 4 |
* @file |
5 |
* |
|
6 | 5 |
*/ |
7 | 6 |
|
8 |
/*** activedirectory is default Active Directory server config **/ |
|
7 |
/*** |
|
8 |
* Activedirectory is default Active Directory server config .**/ |
|
9 | 9 |
function ldap_test_ldap_servers_data() { |
10 | 10 |
|
11 |
$servers['ldapauthor1']['properties'] = array(
|
|
11 |
$servers['ldapauthor1']['properties'] = [
|
|
12 | 12 |
'sid' => 'openldap1', |
13 | 13 |
'name' => 'Test LDAP Server LDAP Authorization' , |
14 | 14 |
'inDatabase' => TRUE, |
... | ... | |
18 | 18 |
'port' => 389, |
19 | 19 |
'tls' => FALSE, |
20 | 20 |
'bind_method' => LDAP_SERVERS_BIND_METHOD_SERVICE_ACCT, |
21 |
'basedn' => array(
|
|
22 |
'dc=hogwarts,dc=edu',
|
|
23 |
),
|
|
21 |
'basedn' => [
|
|
22 |
'dc=hogwarts,dc=edu', |
|
23 |
],
|
|
24 | 24 |
'binddn' => 'cn=service-account,ou=people,dc=hogwarts,dc=edu', |
25 | 25 |
'bindpw' => 'goodpwd', |
26 | 26 |
'user_dn_expression' => NULL, |
... | ... | |
37 | 37 |
'groupMembershipsAttrMatchingUserAttr' => 'dn', |
38 | 38 |
'search_pagination' => 0, |
39 | 39 |
'searchPageSize' => NULL, |
40 |
);
|
|
40 |
];
|
|
41 | 41 |
|
42 |
|
|
43 |
|
|
44 |
$conf['openldap1']['properties'] = array( |
|
42 |
$conf['openldap1']['properties'] = [ |
|
45 | 43 |
'sid' => 'openldap1', |
46 | 44 |
'name' => 'Test Open LDAP' , |
47 | 45 |
'inDatabase' => TRUE, |
... | ... | |
51 | 49 |
'port' => 389, |
52 | 50 |
'tls' => FALSE, |
53 | 51 |
'bind_method' => LDAP_SERVERS_BIND_METHOD_SERVICE_ACCT, |
54 |
'basedn' => array(
|
|
55 |
'dc=hogwarts,dc=edu',
|
|
56 |
),
|
|
52 |
'basedn' => [
|
|
53 |
'dc=hogwarts,dc=edu', |
|
54 |
],
|
|
57 | 55 |
'binddn' => 'cn=service-account,ou=people,dc=hogwarts,dc=edu', |
58 | 56 |
'bindpw' => 'goodpwd', |
59 | 57 |
'user_dn_expression' => NULL, |
... | ... | |
71 | 69 |
'groupMembershipsAttrMatchingUserAttr' => 'dn', |
72 | 70 |
'search_pagination' => 0, |
73 | 71 |
'searchPageSize' => NULL, |
74 |
); |
|
75 |
|
|
76 |
$conf['openldap1']['methodResponses']['connect'] = LDAP_SUCCESS; |
|
77 |
|
|
78 |
|
|
79 |
$conf['openldap1']['search_results'] = array(); |
|
72 |
]; |
|
80 | 73 |
|
74 |
$conf['openldap1']['methodResponses']['connect'] = LDAP_SUCCESS; |
|
81 | 75 |
|
82 |
$conf['openldap1']['search_results']['(&(objectClass=group)(|(member=cn=gryffindor,ou=groups,dc=hogwarts,dc=edu)(member=cn=students,ou=groups,dc=hogwarts,dc=edu)(member=cn=honors students,ou=groups,dc=hogwarts,dc=edu)))']['dc=hogwarts,dc=edu'] = array( |
|
83 |
0 => array('count' => 1, 'dn' => 'cn=users,ou=groups,dc=hogwarts,dc=edu'), |
|
84 |
'count' => 1, |
|
85 |
); |
|
76 |
$conf['openldap1']['search_results'] = []; |
|
86 | 77 |
|
87 |
$conf['openldap1']['search_results']['(cn=hpotter)']['dc=hogwarts,dc=edu'] = array(
|
|
88 |
0 => array(
|
|
78 |
$conf['openldap1']['search_results']['(&(objectClass=group)(|(member=cn=gryffindor,ou=groups,dc=hogwarts,dc=edu)(member=cn=students,ou=groups,dc=hogwarts,dc=edu)(member=cn=honors students,ou=groups,dc=hogwarts,dc=edu)))']['dc=hogwarts,dc=edu'] = [
|
|
79 |
0 => ['count' => 1, 'dn' => 'cn=users,ou=groups,dc=hogwarts,dc=edu'],
|
|
89 | 80 |
'count' => 1, |
90 |
'dn' => 'cn=hpotter,ou=people,dc=hogwarts,dc=edu', |
|
91 |
'FULLENTRY' => TRUE, |
|
92 |
), |
|
93 |
'count' => 1, |
|
94 |
); |
|
95 |
|
|
96 |
$conf['openldap1']['search_results']['(cn=hpotter)']['dc=hogwarts,dc=edu'] = array( |
|
97 |
0 => array( |
|
98 |
'count' => 1, |
|
99 |
'dn' => 'cn=hpotter,ou=people,dc=hogwarts,dc=edu', |
|
100 |
'FULLENTRY' => TRUE, |
|
101 |
), |
|
102 |
'count' => 1, |
|
103 |
); |
|
104 |
|
|
105 |
$conf['openldap1']['search_results']['(cn=hpotter-granger)']['dc=hogwarts,dc=edu'] = array( |
|
106 |
0 => array( |
|
81 |
]; |
|
82 |
|
|
83 |
$conf['openldap1']['search_results']['(cn=hpotter)']['dc=hogwarts,dc=edu'] = [ |
|
84 |
0 => [ |
|
85 |
'count' => 1, |
|
86 |
'dn' => 'cn=hpotter,ou=people,dc=hogwarts,dc=edu', |
|
87 |
'FULLENTRY' => TRUE, |
|
88 |
], |
|
107 | 89 |
'count' => 1, |
108 |
'dn' => 'cn=hpotter,ou=people,dc=hogwarts,dc=edu',
|
|
109 |
'FULLENTRY' => TRUE, |
|
110 |
),
|
|
111 |
'count' => 1,
|
|
112 |
);
|
|
113 |
|
|
114 |
$conf['openldap1']['search_results']['(cn=ssnape)']['dc=hogwarts,dc=edu'] = array(
|
|
115 |
0 => array(
|
|
90 |
];
|
|
91 |
|
|
92 |
$conf['openldap1']['search_results']['(cn=hpotter)']['dc=hogwarts,dc=edu'] = [
|
|
93 |
0 => [
|
|
94 |
'count' => 1,
|
|
95 |
'dn' => 'cn=hpotter,ou=people,dc=hogwarts,dc=edu', |
|
96 |
'FULLENTRY' => TRUE,
|
|
97 |
],
|
|
116 | 98 |
'count' => 1, |
117 |
'dn' => 'cn=ssnape,ou=people,dc=hogwarts,dc=edu',
|
|
118 |
'FULLENTRY' => TRUE, |
|
119 |
),
|
|
120 |
'count' => 1,
|
|
121 |
);
|
|
122 |
|
|
123 |
$conf['openldap1']['search_results']['(cn=adumbledore)']['dc=hogwarts,dc=edu'] = array(
|
|
124 |
0 => array(
|
|
99 |
];
|
|
100 |
|
|
101 |
$conf['openldap1']['search_results']['(cn=hpotter-granger)']['dc=hogwarts,dc=edu'] = [
|
|
102 |
0 => [
|
|
103 |
'count' => 1,
|
|
104 |
'dn' => 'cn=hpotter,ou=people,dc=hogwarts,dc=edu', |
|
105 |
'FULLENTRY' => TRUE,
|
|
106 |
],
|
|
125 | 107 |
'count' => 1, |
126 |
'dn' => 'cn=adumbledore,ou=people,dc=hogwarts,dc=edu', |
|
127 |
'FULLENTRY' => TRUE, |
|
128 |
), |
|
129 |
'count' => 1, |
|
130 |
); |
|
108 |
]; |
|
131 | 109 |
|
132 |
$conf['openldap1']['search_results']['(&(objectClass=groupofnames)(member=cn=hpotter,ou=people,dc=hogwarts,dc=edu))']['dc=hogwarts,dc=edu'] = array( |
|
133 |
0 => array('count' => 1, 'dn' => 'cn=gryffindor,ou=groups,dc=hogwarts,dc=edu'), |
|
134 |
1 => array('count' => 1, 'dn' => 'cn=students,ou=groups,dc=hogwarts,dc=edu'), |
|
135 |
2 => array('count' => 1, 'dn' => 'cn=honors students,ou=groups,dc=hogwarts,dc=edu'), |
|
136 |
'count' => 3, |
|
137 |
); |
|
110 |
$conf['openldap1']['search_results']['(cn=ssnape)']['dc=hogwarts,dc=edu'] = [ |
|
111 |
0 => [ |
|
112 |
'count' => 1, |
|
113 |
'dn' => 'cn=ssnape,ou=people,dc=hogwarts,dc=edu', |
|
114 |
'FULLENTRY' => TRUE, |
|
115 |
], |
|
116 |
'count' => 1, |
|
117 |
]; |
|
138 | 118 |
|
139 |
$conf['openldap1']['search_results']['(&(objectClass=groupofnames)(|(member=cn=gryffindor,ou=groups,dc=hogwarts,dc=edu)(member=cn=students,ou=groups,dc=hogwarts,dc=edu)(member=cn=honors students,ou=groups,dc=hogwarts,dc=edu)))']['dc=hogwarts,dc=edu'] = array( |
|
140 |
0 => array('count' => 1, 'dn' => 'cn=users,ou=groups,dc=hogwarts,dc=edu'), |
|
141 |
'count' => 1, |
|
142 |
); |
|
119 |
$conf['openldap1']['search_results']['(cn=adumbledore)']['dc=hogwarts,dc=edu'] = [ |
|
120 |
0 => [ |
|
121 |
'count' => 1, |
|
122 |
'dn' => 'cn=adumbledore,ou=people,dc=hogwarts,dc=edu', |
|
123 |
'FULLENTRY' => TRUE, |
|
124 |
], |
|
125 |
'count' => 1, |
|
126 |
]; |
|
143 | 127 |
|
128 |
$conf['openldap1']['search_results']['(&(objectClass=groupofnames)(member=cn=hpotter,ou=people,dc=hogwarts,dc=edu))']['dc=hogwarts,dc=edu'] = [ |
|
129 |
0 => ['count' => 1, 'dn' => 'cn=gryffindor,ou=groups,dc=hogwarts,dc=edu'], |
|
130 |
1 => ['count' => 1, 'dn' => 'cn=students,ou=groups,dc=hogwarts,dc=edu'], |
|
131 |
2 => ['count' => 1, 'dn' => 'cn=honors students,ou=groups,dc=hogwarts,dc=edu'], |
|
132 |
'count' => 3, |
|
133 |
]; |
|
144 | 134 |
|
135 |
$conf['openldap1']['search_results']['(&(objectClass=groupofnames)(|(member=cn=gryffindor,ou=groups,dc=hogwarts,dc=edu)(member=cn=students,ou=groups,dc=hogwarts,dc=edu)(member=cn=honors students,ou=groups,dc=hogwarts,dc=edu)))']['dc=hogwarts,dc=edu'] = [ |
|
136 |
0 => ['count' => 1, 'dn' => 'cn=users,ou=groups,dc=hogwarts,dc=edu'], |
|
137 |
'count' => 1, |
|
138 |
]; |
|
145 | 139 |
|
146 |
$conf['activedirectory1']['properties'] = array(
|
|
140 |
$conf['activedirectory1']['properties'] = [
|
|
147 | 141 |
'sid' => 'activedirectory1', |
148 | 142 |
'name' => 'Test Active Directory LDAP' , |
149 | 143 |
'inDatabase' => TRUE, |
... | ... | |
153 | 147 |
'port' => 389, |
154 | 148 |
'tls' => FALSE, |
155 | 149 |
'bind_method' => LDAP_SERVERS_BIND_METHOD_SERVICE_ACCT, |
156 |
'basedn' => array(
|
|
157 |
'dc=hogwarts,dc=edu',
|
|
158 |
),
|
|
150 |
'basedn' => [
|
|
151 |
'dc=hogwarts,dc=edu', |
|
152 |
],
|
|
159 | 153 |
'binddn' => 'cn=service-account,ou=people,dc=hogwarts,dc=edu', |
160 | 154 |
'bindpw' => 'goodpwd', |
161 | 155 |
'user_dn_expression' => NULL, |
... | ... | |
174 | 168 |
'groupMembershipsAttrMatchingUserAttr' => 'dn', |
175 | 169 |
'search_pagination' => 0, |
176 | 170 |
'searchPageSize' => NULL, |
177 |
);
|
|
171 |
];
|
|
178 | 172 |
|
179 |
$conf['activedirectory1']['methodResponses']['connect'] = LDAP_SUCCESS; |
|
180 |
$conf['activedirectory1']['clones'] = LDAP_TEST_USER_ORPHAN_CLONE_COUNT; |
|
173 |
$conf['activedirectory1']['methodResponses']['connect'] = LDAP_SUCCESS;
|
|
174 |
$conf['activedirectory1']['clones'] = LDAP_TEST_USER_ORPHAN_CLONE_COUNT;
|
|
181 | 175 |
|
182 |
$conf['activedirectory1']['search_results'] = array();
|
|
176 |
$conf['activedirectory1']['search_results'] = [];
|
|
183 | 177 |
|
184 |
$conf['activedirectory1']['search_results']['(&(objectClass=group)(member=cn=hpotter,ou=people,dc=hogwarts,dc=edu))']['dc=hogwarts,dc=edu'] = array(
|
|
185 |
0 => array('count' => 1, 'dn' => 'cn=gryffindor,ou=groups,dc=hogwarts,dc=edu'),
|
|
186 |
1 => array('count' => 1, 'dn' => 'cn=students,ou=groups,dc=hogwarts,dc=edu'),
|
|
187 |
2 => array('count' => 1, 'dn' => 'cn=honors students,ou=groups,dc=hogwarts,dc=edu'),
|
|
188 |
'count' => 3, |
|
189 |
);
|
|
178 |
$conf['activedirectory1']['search_results']['(&(objectClass=group)(member=cn=hpotter,ou=people,dc=hogwarts,dc=edu))']['dc=hogwarts,dc=edu'] = [
|
|
179 |
0 => ['count' => 1, 'dn' => 'cn=gryffindor,ou=groups,dc=hogwarts,dc=edu'],
|
|
180 |
1 => ['count' => 1, 'dn' => 'cn=students,ou=groups,dc=hogwarts,dc=edu'],
|
|
181 |
2 => ['count' => 1, 'dn' => 'cn=honors students,ou=groups,dc=hogwarts,dc=edu'],
|
|
182 |
'count' => 3,
|
|
183 |
];
|
|
190 | 184 |
|
191 |
$conf['activedirectory1']['search_results']['(&(objectClass=group)(|(member=cn=gryffindor,ou=groups,dc=hogwarts,dc=edu)(member=cn=students,ou=groups,dc=hogwarts,dc=edu)(member=cn=honors students,ou=groups,dc=hogwarts,dc=edu)))']['dc=hogwarts,dc=edu'] = array(
|
|
192 |
0 => array('count' => 1, 'dn' => 'cn=users,ou=groups,dc=hogwarts,dc=edu'),
|
|
193 |
'count' => 1, |
|
194 |
);
|
|
185 |
$conf['activedirectory1']['search_results']['(&(objectClass=group)(|(member=cn=gryffindor,ou=groups,dc=hogwarts,dc=edu)(member=cn=students,ou=groups,dc=hogwarts,dc=edu)(member=cn=honors students,ou=groups,dc=hogwarts,dc=edu)))']['dc=hogwarts,dc=edu'] = [
|
|
186 |
0 => ['count' => 1, 'dn' => 'cn=users,ou=groups,dc=hogwarts,dc=edu'],
|
|
187 |
'count' => 1,
|
|
188 |
];
|
|
195 | 189 |
|
196 |
foreach (array('hpotter', 'hgrainger', 'ssnape', 'adumbledore') as $cn) {
|
|
190 |
foreach (['hpotter', 'hgrainger', 'ssnape', 'adumbledore'] as $cn) {
|
|
197 | 191 |
|
198 |
$conf['activedirectory1']['search_results']["(cn=$cn)"]['dc=hogwarts,dc=edu'] = array( |
|
199 |
0 => array( |
|
192 |
$conf['activedirectory1']['search_results']["(cn=$cn)"]['dc=hogwarts,dc=edu'] = [ |
|
193 |
0 => [ |
|
194 |
'count' => 1, |
|
195 |
'dn' => "cn=$cn,ou=people,dc=hogwarts,dc=edu", |
|
196 |
'FULLENTRY' => TRUE, |
|
197 |
], |
|
200 | 198 |
'count' => 1, |
201 |
'dn' => "cn=$cn,ou=people,dc=hogwarts,dc=edu",
|
|
202 |
'FULLENTRY' => TRUE, |
|
203 |
),
|
|
204 |
'count' => 1,
|
|
205 |
);
|
|
206 |
|
|
207 |
$conf['activedirectory1']['search_results']["(samaccountname=$cn)"]['dc=hogwarts,dc=edu'] = array(
|
|
208 |
0 => array(
|
|
199 |
];
|
|
200 |
|
|
201 |
$conf['activedirectory1']['search_results']["(samaccountname=$cn)"]['dc=hogwarts,dc=edu'] = [
|
|
202 |
0 => [
|
|
203 |
'count' => 1,
|
|
204 |
'dn' => "cn=$cn,ou=people,dc=hogwarts,dc=edu", |
|
205 |
'FULLENTRY' => TRUE,
|
|
206 |
],
|
|
209 | 207 |
'count' => 1, |
210 |
'dn' => "cn=$cn,ou=people,dc=hogwarts,dc=edu", |
|
211 |
'FULLENTRY' => TRUE, |
|
212 |
), |
|
213 |
'count' => 1, |
|
214 |
); |
|
215 |
|
|
216 |
} |
|
208 |
]; |
|
217 | 209 |
|
210 |
} |
|
218 | 211 |
|
219 |
$conf['activedirectory1']['search_results']['(samaccountname=hpotter-granger)']['dc=hogwarts,dc=edu'] = array( |
|
220 |
0 => array( |
|
212 |
$conf['activedirectory1']['search_results']['(samaccountname=hpotter-granger)']['dc=hogwarts,dc=edu'] = [ |
|
213 |
0 => [ |
|
214 |
'count' => 1, |
|
215 |
'dn' => 'cn=hpotter,ou=people,dc=hogwarts,dc=edu', |
|
216 |
'FULLENTRY' => TRUE, |
|
217 |
], |
|
221 | 218 |
'count' => 1, |
222 |
'dn' => 'cn=hpotter,ou=people,dc=hogwarts,dc=edu', |
|
223 |
'FULLENTRY' => TRUE, |
|
224 |
), |
|
225 |
'count' => 1, |
|
226 |
); |
|
227 |
|
|
228 |
|
|
219 |
]; |
|
229 | 220 |
|
230 |
return $conf; |
|
221 |
return $conf;
|
|
231 | 222 |
} |
Formats disponibles : Unified diff
Weekly update of contrib modules