diff --git a/gosa-core/setup/class_setupStep_Migrate.inc b/gosa-core/setup/class_setupStep_Migrate.inc
index 20d563b5f9a1b90b81cc8f53df2a9058f8f9676d..e43d1a15c435a0fbd4f0580fa27f3dc0880f0f04 100644 (file)
var $check_gidNumbers = array();
var $check_gidNumbers_dialog = FALSE;
var $check_gidNumbers = array();
var $check_gidNumbers_dialog = FALSE;
+ var $group_list = array();
function Step_Migrate()
{
function Step_Migrate()
{
$this->checks['deps_visible']['STATUS'] = FALSE;
$this->checks['deps_visible']['STATUS_MSG']= "";
$this->checks['deps_visible']['ERROR_MSG'] = "";
$this->checks['deps_visible']['STATUS'] = FALSE;
$this->checks['deps_visible']['STATUS_MSG']= "";
$this->checks['deps_visible']['ERROR_MSG'] = "";
- $this->check_organizationalUnits();
$this->checks['users_visible']['TITLE'] = _("Checking for invisible users");
$this->checks['users_visible']['STATUS'] = FALSE;
$this->checks['users_visible']['TITLE'] = _("Checking for invisible users");
$this->checks['users_visible']['STATUS'] = FALSE;
$this->checks['outside_groups']['STATUS_MSG']= "";
$this->checks['outside_groups']['ERROR_MSG'] = "";
$this->search_outside_groups();
$this->checks['outside_groups']['STATUS_MSG']= "";
$this->checks['outside_groups']['ERROR_MSG'] = "";
$this->search_outside_groups();
+ $this->check_organizationalUnits();
$this->checks['outside_winstations']['TITLE'] = _("Checking for windows workstations outside the winstation tree");
$this->checks['outside_winstations']['STATUS'] = FALSE;
$this->checks['outside_winstations']['TITLE'] = _("Checking for windows workstations outside the winstation tree");
$this->checks['outside_winstations']['STATUS'] = FALSE;
$this->checks['outside_winstations']['ERROR_MSG'] = "";
$this->search_outside_winstations();
$this->checks['outside_winstations']['ERROR_MSG'] = "";
$this->search_outside_winstations();
- $this->checks['uidNumber_usage']['TITLE'] = _("Checking for duplicate uid numbers");
+ $this->checks['uidNumber_usage']['TITLE'] = _("Checking for duplicated UID numbers");
$this->checks['uidNumber_usage']['STATUS'] = FALSE;
$this->checks['uidNumber_usage']['STATUS_MSG']= "";
$this->checks['uidNumber_usage']['ERROR_MSG'] = "";
$this->check_uidNumber();
$this->checks['uidNumber_usage']['STATUS'] = FALSE;
$this->checks['uidNumber_usage']['STATUS_MSG']= "";
$this->checks['uidNumber_usage']['ERROR_MSG'] = "";
$this->check_uidNumber();
- $this->checks['gidNumber_usage']['TITLE'] = _("Checking for duplicate gid numbers");
+ $this->checks['gidNumber_usage']['TITLE'] = _("Checking for duplicate GID numbers");
$this->checks['gidNumber_usage']['STATUS'] = FALSE;
$this->checks['gidNumber_usage']['STATUS_MSG']= "";
$this->checks['gidNumber_usage']['ERROR_MSG'] = "";
$this->checks['gidNumber_usage']['STATUS'] = FALSE;
$this->checks['gidNumber_usage']['STATUS_MSG']= "";
$this->checks['gidNumber_usage']['ERROR_MSG'] = "";
*/
function check_uidNumber()
{
*/
function check_uidNumber()
{
+ /* Establish ldap connection */
$cv = $this->parent->captured_values;
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$ldap->cd($cv['base']);
$ldap->cd($cv['base']);
- $res = $ldap->search("uidNumber=*",array("dn","uidNumber"));
+ $res = $ldap->search("(&(objectClass=posixAccount)(uidNumber=*))",array("dn","uidNumber"));
if(!$res){
$this->checks['uidNumber_usage']['STATUS'] = FALSE;
$this->checks['uidNumber_usage']['STATUS_MSG']= _("LDAP query failed");
if(!$res){
$this->checks['uidNumber_usage']['STATUS'] = FALSE;
$this->checks['uidNumber_usage']['STATUS_MSG']= _("LDAP query failed");
*/
function check_gidNumber()
{
*/
function check_gidNumber()
{
+ /* Establish ldap connection */
$cv = $this->parent->captured_values;
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$ldap->cd($cv['base']);
$res = $ldap->search("(&(objectClass=posixGroup)(gidNumber=*))",array("dn","gidNumber"));
if(!$res){
$ldap->cd($cv['base']);
$res = $ldap->search("(&(objectClass=posixGroup)(gidNumber=*))",array("dn","gidNumber"));
if(!$res){
*/
function search_outside_winstations()
{
*/
function search_outside_winstations()
{
+ /* Establish ldap connection */
$cv = $this->parent->captured_values;
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get winstation ou */
if($cv['generic_settings']['wws_ou_active']) {
$winstation_ou = $cv['generic_settings']['ws_ou'];
/* Get winstation ou */
if($cv['generic_settings']['wws_ou_active']) {
$winstation_ou = $cv['generic_settings']['ws_ou'];
*/
function search_outside_groups()
{
*/
function search_outside_groups()
{
+ /* Establish ldap connection */
$cv = $this->parent->captured_values;
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$group_ou = $cv['groupou'];
$ldap->cd($cv['base']);
$group_ou = $cv['groupou'];
$ldap->cd($cv['base']);
}
$this->outside_groups = array();
}
$this->outside_groups = array();
+ $this->groups_list = array();;
while($attrs = $ldap->fetch()){
$group_db_base = preg_replace("/^[^,]+,".normalizePreg($group_ou)."+,/i","",$attrs['dn']);
while($attrs = $ldap->fetch()){
$group_db_base = preg_replace("/^[^,]+,".normalizePreg($group_ou)."+,/i","",$attrs['dn']);
$attrs['ldif'] = "";
$this->outside_groups[base64_encode($attrs['dn'])] = $attrs;
}
$attrs['ldif'] = "";
$this->outside_groups[base64_encode($attrs['dn'])] = $attrs;
}
+ $this->group_list[] = $attrs['dn'];
}
if(count($this->outside_groups)){
}
if(count($this->outside_groups)){
*/
function search_outside_users()
{
*/
function search_outside_users()
{
+ /* Establish ldap connection */
$cv = $this->parent->captured_values;
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
$ldap->cd($cv['base']);
*/
function check_ldap_permissions()
{
*/
function check_ldap_permissions()
{
+ /* Establish ldap connection */
$cv = $this->parent->captured_values;
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Create dummy entry
*/
$name = "GOsa_setup_text_entry_".session_id().rand(0,999999);
/* Create dummy entry
*/
$name = "GOsa_setup_text_entry_".session_id().rand(0,999999);
$old = $this->users_to_migrate;
$this->users_to_migrate = array();
$old = $this->users_to_migrate;
$this->users_to_migrate = array();
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get all invisible users
*/
$ldap->cd($cv['base']);
/* Get all invisible users
*/
$ldap->cd($cv['base']);
{
$this->show_details= $only_ldif;
{
$this->show_details= $only_ldif;
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Add gosaAccount objectClass to the selected users
*/
foreach($this->users_to_migrate as $key => $dep){
/* Add gosaAccount objectClass to the selected users
*/
foreach($this->users_to_migrate as $key => $dep){
$old = $this->deps_to_migrate;
$this->deps_to_migrate = array();
$old = $this->deps_to_migrate;
$this->deps_to_migrate = array();
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Skip GOsa internal departments */
/* Skip GOsa internal departments */
- $skip_dns = array("/".$cv['peopleou']."/","/".$cv['groupou']."/","/^ou=people,/","/^ou=groups,/",
+ $skip_dns = array("/".$cv['peopleou']."/","/".$cv['groupou']."/","/^ou=people,/","/^ou=groups,/","/^ou=sudoers,/",
"/(,|)ou=configs,/","/(,|)ou=systems,/",
"/(,|)ou=apps,/","/(,|)ou=mime,/","/(,|)ou=devices/","/^ou=aclroles,/","/^ou=incoming,/",
"/ou=snapshots,/","/(,|)dc=addressbook,/","/^(,|)ou=machineaccounts,/",
"/(,|)ou=configs,/","/(,|)ou=systems,/",
"/(,|)ou=apps,/","/(,|)ou=mime,/","/(,|)ou=devices/","/^ou=aclroles,/","/^ou=incoming,/",
"/ou=snapshots,/","/(,|)dc=addressbook,/","/^(,|)ou=machineaccounts,/",
foreach($this->deps_to_migrate as $key => $attrs){
$dn = $attrs['dn'];
$skip = false;;
foreach($this->deps_to_migrate as $key => $attrs){
$dn = $attrs['dn'];
$skip = false;;
+
+ /* Check if this object is an application release object
+ e.g. groups-> application menus.
+ */
+ if(preg_match("/^.*,[ ]*cn=/",$dn)){
+ $cn_dn = preg_replace("/^.*,[ ]*cn=/","cn=",$dn);
+ if(in_array($cn_dn,$this->group_list)){
+ $skip = true;
+ }
+ }
+
foreach($skip_dns as $skip_dn){
if(preg_match($skip_dn,$dn)){
$skip = true;
foreach($skip_dns as $skip_dn){
if(preg_match($skip_dn,$dn)){
$skip = true;
{
$this->show_details= $only_ldif;
{
$this->show_details= $only_ldif;
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Add gosaDepartment objectClass to each selected entry
*/
foreach($this->deps_to_migrate as $key => $dep){
/* Add gosaDepartment objectClass to each selected entry
*/
foreach($this->deps_to_migrate as $key => $dep){
{
/* Establish ldap connection */
$cv = $this->parent->captured_values;
{
/* Establish ldap connection */
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
- /* Search for gosaAcls */
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
$res = $ldap->cat($cv['base']);
$ldap->cd($cv['base']);
$res = $ldap->cat($cv['base']);
/* Get collected configuration settings */
$cv = $this->parent->captured_values;
/* Get collected configuration settings */
$cv = $this->parent->captured_values;
- /* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ /* On first call check for rid/sid base */
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get current base attributes */
$ldap->cd($cv['base']);
$ldap->cat($cv['base'],array("dn","objectClass","gosaAclEntry"));
$attrs = $ldap->fetch();
/* Add acls for the selcted user to the base */
/* Get current base attributes */
$ldap->cd($cv['base']);
$ldap->cat($cv['base'],array("dn","objectClass","gosaAclEntry"));
$attrs = $ldap->fetch();
/* Add acls for the selcted user to the base */
+ $attrs_new = array();
$attrs_new['objectClass'] = array("gosaACL");
for($i = 0; $i < $attrs['objectClass']['count']; $i ++){
$attrs_new['objectClass'] = array("gosaACL");
for($i = 0; $i < $attrs['objectClass']['count']; $i ++){
return false;
}
return false;
}
-
- /* Establish ldap connection */
+ /* On first call check for rid/sid base */
$cv = $this->parent->captured_values;
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get current base attributes */
$ldap->cd($cv['base']);
/* Get current base attributes */
$ldap->cd($cv['base']);
}
if($cv['peopledn'] == "cn"){
}
if($cv['peopledn'] == "cn"){
- $dn = "cn=System Administrator,".$people_ou.$cv['base'];
+ $dn = "cn=System Administrator-".$uid.",".$people_ou.$cv['base'];
}else{
$dn = "uid=".$uid.",".$people_ou.$cv['base'];
}
}else{
$dn = "uid=".$uid.",".$people_ou.$cv['base'];
}
- $methods = @passwordMethod::get_available_methods();
- $p_m = $methods[$cv['encryption']];
- $p_c = new $p_m(array());
- $hash = $p_c->generate_hash($pw2);
+ $hash = passwordMethod::make_hash($pw2, $cv['encryption']);
$new_user=array();
$new_user['objectClass']= array("top","person","gosaAccount","organizationalPerson","inetOrgPerson");
$new_user['givenName'] = "System";
$new_user['sn'] = "Administrator";
$new_user=array();
$new_user['objectClass']= array("top","person","gosaAccount","organizationalPerson","inetOrgPerson");
$new_user['givenName'] = "System";
$new_user['sn'] = "Administrator";
- $new_user['cn'] = "System Administrator";
+ $new_user['cn'] = "System Administrator-".$uid;
$new_user['uid'] = $uid;
$new_user['userPassword'] = $hash;
$new_user['uid'] = $uid;
$new_user['userPassword'] = $hash;
{
/* Establish ldap connection */
$cv = $this->parent->captured_values;
{
/* Establish ldap connection */
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
{
/* Establish ldap connection */
$cv = $this->parent->captured_values;
{
/* Establish ldap connection */
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
{
/* Establish ldap connection */
$cv = $this->parent->captured_values;
{
/* Establish ldap connection */
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
*/
function checkBase($just_check = TRUE)
{
*/
function checkBase($just_check = TRUE)
{
- /* Get collected setup informations */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Check if root object exists */
$ldap->cd($cv['base']);
/* Check if root object exists */
$ldap->cd($cv['base']);
+ $ldap->set_size_limit(1);
$res = $ldap->search("(objectClass=*)");
$res = $ldap->search("(objectClass=*)");
+ $ldap->set_size_limit(0);
$err = ldap_errno($ldap->cid);
if( !$res ||
$err = ldap_errno($ldap->cid);
if( !$res ||
function get_user_list()
{
function get_user_list()
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
-
+
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
$ldap->search("(objectClass=gosaAccount)",array("dn"));
$ldap->cd($cv['base']);
$ldap->search("(objectClass=gosaAccount)",array("dn"));
$people_ou = trim($cv['peopleou']);
/* Establish ldap connection */
$people_ou = trim($cv['peopleou']);
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
/*****************
* If people ou is NOT empty
/*****************
* If people ou is NOT empty
function get_all_winstation_ous()
{
function get_all_winstation_ous()
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get winstation ou */
if($cv['generic_settings']['wws_ou_active']) {
$winstation_ou = $cv['generic_settings']['ws_ou'];
/* Get winstation ou */
if($cv['generic_settings']['wws_ou_active']) {
$winstation_ou = $cv['generic_settings']['ws_ou'];
function get_all_group_ous()
{
function get_all_group_ous()
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$group_ou = trim($cv['groupou']);
if(!empty($group_ou)){
$group_ou = trim($group_ou);
$group_ou = trim($cv['groupou']);
if(!empty($group_ou)){
$group_ou = trim($group_ou);
function get_group_list()
{
function get_group_list()
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
$ldap->search("(objectClass=posixGroup)",array("dn"));
$ldap->cd($cv['base']);
$ldap->search("(objectClass=posixGroup)",array("dn"));
function move($source,$destination)
{
function move($source,$destination)
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* Establish ldap connection */
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $cv = $this->parent->captured_values;
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Update object references in gosaGroupOfNames */
$ogs_to_fix = array();
$ldap->cd($cv['base']);
/* Update object references in gosaGroupOfNames */
$ogs_to_fix = array();
$ldap->cd($cv['base']);
msg_dialog::display(_("LDAP error"), sprintf(_("Copy '%s' to '%s' failed:")."<br><br><i>%s</i>", LDAP::fix($source), LDAP::fix($destination), $ldap->get_error()), ERROR_DIALOG);
}else{
$res = $ldap->rmDir($source);
msg_dialog::display(_("LDAP error"), sprintf(_("Copy '%s' to '%s' failed:")."<br><br><i>%s</i>", LDAP::fix($source), LDAP::fix($destination), $ldap->get_error()), ERROR_DIALOG);
}else{
$res = $ldap->rmDir($source);
- show_ldap_error($ldap->get_error(),_("Problem copying DNs"));
+ if (!$ldap->success()){
+ msg_dialog::display(_("LDAP error"), msgPool::ldaperror($ldap->get_error(), $source, LDAP_DEL, get_class()));
+ }
/* Object is copied, so update its references */
foreach($ogs_to_fix as $dn => $data){
/* Object is copied, so update its references */
foreach($ogs_to_fix as $dn => $data){