Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
fusiondirectory
fusiondirectory
Commits
77965cbe
Commit
77965cbe
authored
Jul 30, 2014
by
Côme Bernigaud
Committed by
Benoit Mortier
Jul 30, 2014
Browse files
Fixes
#2919
Added missing ldap cd
parent
d1fbdc3a
Changes
2
Hide whitespace changes
Inline
Side-by-side
setup/class_setupStep_Ldap.inc
View file @
77965cbe
...
...
@@ -185,7 +185,7 @@ class Step_Ldap extends setupStep
}
elseif
(
$this
->
is_completed
)
{
$checked
=
check_schema
(
$this
->
parent
->
captured_values
,
"NO RFC CHECK"
);
$error
=
array
();
foreach
(
$
this
->
checked
as
$check
)
{
foreach
(
$checked
as
$check
)
{
if
(
!
$check
[
'STATUS'
])
{
$error
[]
=
$check
[
'MSG'
];
}
...
...
setup/class_setupStep_Migrate.inc
View file @
77965cbe
...
...
@@ -362,7 +362,7 @@ class Step_Migrate extends setup_step
$this
->
outside_groups
=
array
();
$this
->
groups_list
=
array
();;
while
(
$attrs
=
$ldap
->
fetch
())
{
$group_db_base
=
preg_replace
(
"/^[^,]+,"
.
preg_quote
(
$group_ou
,
'/'
)
.
"
+
/i"
,
""
,
$attrs
[
'dn'
]);
$group_db_base
=
preg_replace
(
"/^[^,]+,"
.
preg_quote
(
$group_ou
,
'/'
)
.
"/i"
,
""
,
$attrs
[
'dn'
]);
/* Check if entry is not an addressbook only user
* and verify that he is in a valid department
...
...
@@ -1049,12 +1049,14 @@ class Step_Migrate extends setup_step
/* Get collected configuration settings */
$ldap
=
$config
->
get_ldap_link
();
$ldap
->
cd
(
$config
->
current
[
'BASE'
]);
$ldap
->
search
(
"(&(objectClass=gosaRole)(gosaAclTemplate=*:all;cmdrw))"
,
array
(
'dn'
));
if
(
$attrs
=
$ldap
->
fetch
())
{
$roledn
=
$attrs
[
'dn'
];
}
else
{
$roledn
=
'cn=admin,'
.
get_ou
(
'aclRoleRDN'
)
.
$config
->
current
[
'BASE'
];
if
(
!
$only_ldif
)
{
$ldap
->
cd
(
$config
->
current
[
'BASE'
]);
$ldap
->
create_missing_trees
(
get_ou
(
'aclRoleRDN'
)
.
$config
->
current
[
'BASE'
]);
$ldap
->
cd
(
$roledn
);
$attrs_role
=
array
(
...
...
@@ -2051,6 +2053,7 @@ class Step_Migrate extends setup_step
* Get all valid ous, create one if necessary
************/
if
(
!
empty
(
$ou
))
{
$ldap
->
cd
(
$config
->
current
[
'BASE'
]);
$ldap
->
search
(
"(
$ou
)"
,
array
(
'dn'
));
if
(
$ldap
->
count
()
==
0
)
{
$ldap
->
create_missing_trees
(
$ou
.
','
.
$config
->
current
[
'BASE'
]);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment