diff options
Diffstat (limited to 'ldap_wizard/Ldap.pm')
-rw-r--r-- | ldap_wizard/Ldap.pm | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/ldap_wizard/Ldap.pm b/ldap_wizard/Ldap.pm index ddda4e37..9518a2c8 100644 --- a/ldap_wizard/Ldap.pm +++ b/ldap_wizard/Ldap.pm @@ -1,7 +1,7 @@ #!/usr/bin/perl # version 0.1 # GPL like -# aginies@mandrakesoft.com +# vguardiola@mandrakesoft.com package MDK::Wizard::Ldap; use lib qw(/usr/lib/libDrakX); @@ -52,7 +52,7 @@ my $o = { }, needed_rpm => [ 'openldap-servers','openldap-clients' ], defaultimage => "$ENV{__WIZ_HOME__}ldap_wizard/images/ldap.png", - }; + }; my $wiz = new MDK::Wizard::Wizcommon; @@ -181,7 +181,7 @@ $o->{pages} = { next => 'summary_add_user' }, set_srv => { - name => "\n". N("Configuring LDAP Server") ."\n\n" . N("LDAP directory tree") . "\n" . N("The DNS naming is used for LDAP directory tree definition") . "\n" . N("Domain name: ") . $wiz_domain_name . "\n" . ("LDAP Diretory Tree: " . $o->{var}{suffix} ) . "\n\n" . N("LDAP Administrator") . "\n" . N("Administrator is a power user with grant access on LDAP database") . "\n" . "cn=".N("Administrator").",".$o->{var}{suffix} . "\n\n", + name => "\n". N("Configuring LDAP Server") ."\n\n" . N("LDAP directory tree") . "\n" . N("The DNS naming is used for LDAP directory tree definition") . "\n" . N("Domain name: ") . $wiz_domain_name . "\n" . ("LDAP Diretory Tree: " . $o->{var}{suffix} ) . "\n\n" . N("LDAP Administrator") . "\n" . N("Administrator is a power user with grant access on LDAP database") . "\n" . "cn=".N("Adrministrator").",".$o->{var}{suffix} . "\n\n", data => [ { label => " " }, { label => N("LDAP directory tree:"), val => \$o->{var}{suffix}, help => "aide p" }, @@ -302,7 +302,7 @@ sub do_it_setldap { # s/example/$dcall substInFile { - s/example/$o->{var}{suffix}/g; + s/dc=example,dc=com/$o->{var}{suffix}/g; } $LDAPCONF; # set rootdn @@ -327,19 +327,8 @@ sub do_it_setldap { } - # create config file in /etc/sysconfig/ldapconf - - output($conf_file, <<EOF); -srv=$o->{var}{srv} -suffix=$o->{var}{suffix} -rootdn=$o->{var}{rootdn} -rootpass=$o->{var}{rootpass} -users=$o->{var}{defou} -EOF - # reset premisions system("chown -R root.ldap /etc/openldap"); - # better use status, maybe ? services::restart('ldap'); sleep(4); init_ldap(); @@ -387,7 +376,18 @@ objectClass: organizationalUnit RootLdif - close($LDAP) + close($LDAP); + + # create config file in /etc/sysconfig/ldapwiz + output($conf_file, <<EOF); +srv=$o->{var}{srv} +suffix=$o->{var}{suffix} +rootdn=$o->{var}{rootdn} +rootpass=$o->{var}{rootpass} +users=$o->{var}{defou} +EOF + + } |