summaryrefslogtreecommitdiff
path: root/source3/param
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2002-09-27 01:02:37 +0000
committerAndrew Bartlett <abartlet@samba.org>2002-09-27 01:02:37 +0000
commit9e7a6d6b8b4f5bf38d6faa2fca211657fc8b2959 (patch)
treecbe22cb9b2494f674c925534c5a619eef6d6501e /source3/param
parentc60f6f066ea47f7d85fc8028f9d657cfe5841893 (diff)
downloadsamba-9e7a6d6b8b4f5bf38d6faa2fca211657fc8b2959.tar.gz
samba-9e7a6d6b8b4f5bf38d6faa2fca211657fc8b2959.tar.bz2
samba-9e7a6d6b8b4f5bf38d6faa2fca211657fc8b2959.zip
Readd the 2.2 --with-ldapsam paramaters so as to allow a smooth upgrade path to
a 3.0 based PDC. Change defaults to use SSL, so that this also matches. Andrew Bartlett (This used to be commit 36c2a3820faa1d90cd331881720be0e61ab93460)
Diffstat (limited to 'source3/param')
-rw-r--r--source3/param/loadparm.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
index c484439837..ba16d68624 100644
--- a/source3/param/loadparm.c
+++ b/source3/param/loadparm.c
@@ -207,6 +207,10 @@ typedef struct
int iLockSpinTime;
char *szLdapMachineSuffix;
char *szLdapUserSuffix;
+#ifdef WITH_LDAP_SAMCONFIG
+ int ldap_port;
+ char *szLdapServer;
+#endif
int ldap_ssl;
char *szLdapSuffix;
char *szLdapFilter;
@@ -1003,6 +1007,10 @@ static struct parm_struct parm_table[] = {
{"Ldap Options", P_SEP, P_SEPARATOR},
+#ifdef WITH_LDAP_SAMCONFIG
+ {"ldap server", P_STRING, P_GLOBAL, &Globals.szLdapServer, NULL, NULL, 0},
+ {"ldap port", P_INTEGER, P_GLOBAL, &Globals.ldap_port, NULL, NULL, 0},
+#endif
{"ldap suffix", P_STRING, P_GLOBAL, &Globals.szLdapSuffix, handle_ldap_suffix, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
{"ldap machine suffix", P_STRING, P_GLOBAL, &Globals.szLdapMachineSuffix, handle_ldap_machine_suffix, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
{"ldap user suffix", P_STRING, P_GLOBAL, &Globals.szLdapUserSuffix, handle_ldap_user_suffix, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
@@ -1367,6 +1375,11 @@ static void init_globals(void)
a large number of sites (tridge) */
Globals.bHostnameLookups = False;
+#ifdef WITH_LDAP_SAMCONFIG
+ string_set(&Globals.szLdapServer, "localhost");
+ Globals.ldap_port = 636;
+#endif /* WITH_LDAP_SAMCONFIG */
+
string_set(&Globals.szLdapSuffix, "");
string_set(&Globals.szLdapMachineSuffix, "");
string_set(&Globals.szLdapUserSuffix, "");
@@ -1582,6 +1595,11 @@ FN_GLOBAL_STRING(lp_winbind_separator, &Globals.szWinbindSeparator)
FN_GLOBAL_BOOL(lp_winbind_enum_users, &Globals.bWinbindEnumUsers)
FN_GLOBAL_BOOL(lp_winbind_enum_groups, &Globals.bWinbindEnumGroups)
FN_GLOBAL_BOOL(lp_winbind_use_default_domain, &Globals.bWinbindUseDefaultDomain)
+
+#ifdef WITH_LDAP_SAMCONFIG
+FN_GLOBAL_STRING(lp_ldap_server, &Globals.szLdapServer)
+FN_GLOBAL_INTEGER(lp_ldap_port, &Globals.ldap_port)
+#endif
FN_GLOBAL_STRING(lp_ldap_suffix, &Globals.szLdapSuffix)
FN_GLOBAL_STRING(lp_ldap_machine_suffix, &Globals.szLdapMachineSuffix)
FN_GLOBAL_STRING(lp_ldap_user_suffix, &Globals.szLdapUserSuffix)