--- /dev/null
+config_file=/etc/ldap/slapd.conf
+schema_dir=/etc/ldap/schema
+slapd=slapd
+ldap_user=ldap
+browse_max=100
schema_dir=/etc/ldap/schema
slapd=slapd
ldap_user=ldap
+browse_max=100
+start_cmd=/etc/init.d/ldap start
+stop_cmd=/etc/init.d/ldap stop
+apply_cmd=/etc/init.d/ldap restart
+init_name=ldap
--- /dev/null
+config_file=/etc/ldap/slapd.conf
+schema_dir=/etc/ldap/schema
+slapd=slapd
+ldap_user=ldap
+browse_max=100
+start_cmd=/etc/init.d/slapd start
+stop_cmd=/etc/init.d/slapd stop
+apply_cmd=/etc/init.d/slapd restart
+init_name=slapd
--- /dev/null
+config_file=/etc/openldap/slapd.conf
+schema_dir=/etc/openldap/schema
+slapd=slapd
+ldap_user=ldap
+browse_max=100
+start_cmd=/etc/rc./init.d/ldap start
+stop_cmd=/etc/rc./init.d/ldap stop
+apply_cmd=/etc/rc./init.d/ldap restart
+init_name=ldap
--- /dev/null
+config_file=/etc/openldap/slapd.conf
+schema_dir=/etc/openldap/schema
+slapd=slapd
+ldap_user=ldap
+browse_max=100
+start_cmd=/etc/init.d/ldap start
+stop_cmd=/etc/init.d/ldap stop
+apply_cmd=/etc/init.d/ldap restart
+init_name=ldap
--- /dev/null
+config_file=/opt/csw/etc/openldap/slapd.conf
+alt_config_file=/opt/csw/etc/openldap/slapd.conf.default
+schema_dir=/opt/csw/etc/openldap/schema
+slapd=/opt/csw/libexec/slapd
+ldap_user=ldap
+browse_max=100
--- /dev/null
+config_file=/etc/openldap/slapd.conf
+schema_dir=/etc/openldap/schema
+slapd=slapd
+ldap_user=ldap
+browse_max=100
+start_cmd=/etc/init.d/ldap start
+stop_cmd=/etc/init.d/ldap stop
+apply_cmd=/etc/init.d/ldap restart
+init_name=ldap
--- /dev/null
+config_file=/etc/openldap/slapd.conf
+schema_dir=/etc/openldap/schema
+slapd=slapd
+ldap_user=ldap
+browse_max=100
+start_cmd=/etc/rc./init.d/ldap start
+stop_cmd=/etc/rc./init.d/ldap stop
+apply_cmd=/etc/rc./init.d/ldap restart
+init_name=ldap
config_file=OpenLDAP server configuration file,8
schema_dir=OpenLDAP schema directory,7
ldap_user=User OpenLDAP server runs as,5
+init_name=OpenLDAP server boot script name,3,Same as module name
line2=User interface settings,11
browse_max=Maximum number of sub-objects to display,3,Unlimited
# Actually create a new base DN
require './ldap-server-lib.pl';
+&ReadParse();
&error_setup($text{'create_err'});
$access{'create'} || &error($text{'create_ecannot'});
$ldap = &connect_ldap_db();
# Add the example user/alias
if ($in{'example'} == 1 || $in{'example'} == 2) {
# User
+ $edn = "uid=example, ".$dn;
+ @attrs = ( "cn", "Example user",
+ "uid", "example",
+ "uidNumber", 9999,
+ "gidNumber", 9999,
+ "loginShell", "/bin/sh",
+ "homeDirectory", "/home/example",
+ "objectClass", [ "posixAccount" ],
+ "userPassword", "*LK*" );
+ if ($in{'example'} == 2) {
+ # With mail
+ push(@attrs, "mail", "example\@example.com");
+ }
}
elsif ($in{'example'} == 3) {
# Virtuser
+ # XXX not sure about these .. is there any standard?
+ $edn = "cn=example\@example.com, ".$dn;
+ @attrs = ( "mail", "example\@example.com",
+ "mailForwardingAddress", "example\@somewhere.com",
+ "objectClass", [ "top" ] );
}
print &text('create_doingex',
}
# Start at boot button
- # XXX
+ if (&foreign_check("init")) {
+ $iname = $config{'init_name'} || $module_name;
+ &foreign_require("init", "init-lib.pl");
+ $st = &init::action_status($iname);
+ print &ui_buttons_row("bootup.cgi", $text{'index_boot'},
+ $text{'index_bootdesc'},
+ &ui_hidden("iname", $iname),
+ &ui_yesno_radio("boot",$st == 2 ? 1 : 0));
+ }
print &ui_buttons_end();
}
index_start=Start Server
index_startdesc=Click this button to start up the OpenLDAP server with the current configuration. User accounts and mail aliases stored in its database will not be accessible until it is started.
index_return=module index
+index_boot=Start at boot?
+index_bootdesc=Change this selection to determine if the OpenLDAP server is started at boot time or not.
connect_eserver=The LDAP server $1 does not exist
connect_euser=No user to login as has been configured
# Functions for configuring and talking to an LDAP server
# XXX help pages
-# XXX initial setup
-# XXX install ldap server
-# XXX default configs for various systems (include search max of 100)
+# XXX init ldap server
+# XXX start at boot
do '../web-lib.pl';
&init_config();
if (!$config{'server'} || &to_ipaddress($config{'server'}) eq '127.0.0.1' ||
&to_ipaddress($config{'server'}) eq &to_ipaddress(&get_system_hostname())) {
# Local .. but is it installed?
+ if (!-r $config{'config_file'} &&
+ -r $config{'alt_config_file'}) {
+ ©_source_dest($config{'alt_config_file'},
+ $config{'config_file'});
+ }
return !&has_command($config{'slapd'}) ? -1 :
!-r $config{'config_file'} ? -2 : 1;
}