summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 6841d03)
raw | patch | inline | side by side (parent: 6841d03)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 26 Mar 2008 08:50:03 +0000 (08:50 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 26 Mar 2008 08:50:03 +0000 (08:50 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9984 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-core/setup/class_setupStep_Config2.inc | patch | blob | history | |
gosa-core/setup/class_setupStep_Migrate.inc | patch | blob | history | |
gosa-core/setup/class_setupStep_Schema.inc | patch | blob | history |
diff --git a/gosa-core/setup/class_setupStep_Config2.inc b/gosa-core/setup/class_setupStep_Config2.inc
index ecf986f830f501abb14701c273bc40db3542b3dc..450fe81e1c20c6ef30dbb700f57526944166cfba 100644 (file)
$this->mail_methods = $this->get_available_mail_classes();
/* On first call check for rid/sid base */
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$ldap->cd($cv['base']);
$ldap->search("(objectClass=sambaDomain)",array("dn"));
if($ldap->count()){
diff --git a/gosa-core/setup/class_setupStep_Migrate.inc b/gosa-core/setup/class_setupStep_Migrate.inc
index 1001e877029a755c385754e8aa27b87176139405..ed52e7cd5ea192f9391c25634d5af4eb5158befa 100644 (file)
*/
function check_uidNumber()
{
+ /* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$ldap->cd($cv['base']);
$res = $ldap->search("uidNumber=*",array("dn","uidNumber"));
if(!$res){
*/
function check_gidNumber()
{
+ /* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$ldap->cd($cv['base']);
$res = $ldap->search("(&(objectClass=posixGroup)(gidNumber=*))",array("dn","gidNumber"));
if(!$res){
*/
function search_outside_winstations()
{
+ /* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get winstation ou */
if($cv['generic_settings']['wws_ou_active']) {
$winstation_ou = $cv['generic_settings']['ws_ou'];
*/
function search_outside_groups()
{
+ /* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$group_ou = $cv['groupou'];
$ldap->cd($cv['base']);
*/
function search_outside_users()
{
+ /* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
*/
function check_ldap_permissions()
{
+ /* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Create dummy entry
*/
$name = "GOsa_setup_text_entry_".session_id().rand(0,999999);
$old = $this->users_to_migrate;
$this->users_to_migrate = array();
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get all invisible users
*/
$ldap->cd($cv['base']);
{
$this->show_details= $only_ldif;
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* 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();
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Skip GOsa internal departments */
$skip_dns = array("/".$cv['peopleou']."/","/".$cv['groupou']."/","/^ou=people,/","/^ou=groups,/",
"/(,|)ou=configs,/","/(,|)ou=systems,/",
{
$this->show_details= $only_ldif;
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Add gosaDepartment objectClass to each selected entry
*/
foreach($this->deps_to_migrate as $key => $dep){
{
/* 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']);
- /* Search for gosaAcls */
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
$res = $ldap->cat($cv['base']);
/* 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']);
+ $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 */
+ $attrs_new = array();
$attrs_new['objectClass'] = array("gosaACL");
for($i = 0; $i < $attrs['objectClass']['count']; $i ++){
return false;
}
-
- /* Establish ldap connection */
+ /* On first call check for rid/sid base */
$cv = $this->parent->captured_values;
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get current base attributes */
$ldap->cd($cv['base']);
}
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'];
}
$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;
{
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
{
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
{
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
/* Check if there was a destination department posted */
*/
function checkBase($just_check = TRUE)
{
- /* Get collected setup informations */
- $cv = $this->parent->captured_values;
-
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Check if root object exists */
$ldap->cd($cv['base']);
$res = $ldap->search("(objectClass=*)");
function get_user_list()
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
-
+
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
$ldap->search("(objectClass=gosaAccount)",array("dn"));
$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']);
+ $ldap = new ldapMultiplexer($ldap_l);
/*****************
* If people ou is NOT empty
function get_all_winstation_ous()
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Get winstation ou */
if($cv['generic_settings']['wws_ou_active']) {
$winstation_ou = $cv['generic_settings']['ws_ou'];
function get_all_group_ous()
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
$group_ou = trim($cv['groupou']);
if(!empty($group_ou)){
$group_ou = trim($group_ou);
function get_group_list()
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
+
+ $ldap = new ldapMultiplexer($ldap_l);
$ldap->cd($cv['base']);
$ldap->search("(objectClass=posixGroup)",array("dn"));
function move($source,$destination)
{
- /* Get collected configuration settings */
- $cv = $this->parent->captured_values;
-
/* 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']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Update object references in gosaGroupOfNames */
$ogs_to_fix = array();
$ldap->cd($cv['base']);
diff --git a/gosa-core/setup/class_setupStep_Schema.inc b/gosa-core/setup/class_setupStep_Schema.inc
index 63b6ce47334cf95873ec544d325fce93d64cef5a..0899c779289450f3b2676c45f3c9a4cc8b168579 100644 (file)
$cv = $this->parent->captured_values;
/* Establish ldap connection */
- $ldap = new LDAP($cv['admin'],
+ $ldap_l = new LDAP($cv['admin'],
$cv['password'],
$cv['connection'],
FALSE,
$cv['tls']);
+ $ldap = new ldapMultiplexer($ldap_l);
+
/* Check if root object exists */
$ldap->cd($cv['base']);
$res = $ldap->search("(objectClass=*)");