summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 8f730bf)
raw | patch | inline | side by side (parent: 8f730bf)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 24 May 2007 13:09:05 +0000 (13:09 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 24 May 2007 13:09:05 +0000 (13:09 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@6469 594d385d-05f5-0310-b6e9-bd551577e9d8
setup/class_setupStep_Migrate.inc | patch | blob | history |
index cf487a90b68a27b72deb35156048fa9665065258..3daa0e3c6a277384d29b75ce872094b88ab826b2 100644 (file)
}
}else{
- $new_group_dn = "cn=GOsa Administrators,".$cv['groupou'].",".$cv['base'];
+
+ $group_ou = trim($cv['groupou']);
+ if(!empty($group_ou)){
+ $group_ou = trim($group_ou).",";
+ }
+
+ $new_group_dn = "cn=GOsa Administrators,".$group_ou.$cv['base'];
$new_group_attrs['objectClass'] = array("gosaObject","posixGroup");
$new_group_attrs['cn'] = "GOsa Administrators";
$new_group_attrs['gosaSubtreeACL'] = ":all";
/* Get current base attributes */
$ldap->cd($cv['base']);
-
+
+ $people_ou = trim($cv['peopleou']);
+ if(!empty($people_ou)){
+ $people_ou = trim($people_ou).",";
+ }
+
if($cv['peopledn'] == "cn"){
- $dn = "cn=System Administrator,".$cv['peopleou'].",".$cv['base'];
+ $dn = "cn=System Administrator,".$people_ou.$cv['base'];
}else{
- $dn = "uid=".$uid.",".$cv['peopleou'].",".$cv['base'];
+ $dn = "uid=".$uid.",".$people_ou.$cv['base'];
}
$methods = @passwordMethod::get_available_methods_if_not_loaded();
$new_user['userPassword'] = $hash;
$ldap->cd($cv['base']);
-
$ldap->cat($dn,array("dn"));
if($ldap->count()){
print_red(sprintf(_("Could not add administrative user, there is already an object with the same dn '%s' in your ldap database."),