--- /dev/null
+<samba:parameter name="create krb5 conf"
+ context="G"
+ type="string"
+ advanced="1" developer="0"
+ xmlns:samba="http://www.samba.org/samba/DTD/samba-doc">
+<description>
+
+ <para>
+ Setting this paramter to <value type="example">no</value> prevents
+ winbind from creating custom krb5.conf files. Winbind normally does
+ this because the krb5 libraries are not AD-site-aware and thus would
+ pick any domain controller out of potentially very many. Winbind
+ is site-aware and makes the krb5 libraries use a local DC by
+ creating its own krb5.conf files.
+ </para>
+ <para>
+ Preventing winbind from doing this might become necessary if you
+ have to add special options into your system-krb5.conf that winbind
+ does not see.
+ </para>
+
+</description>
+<value type="default">yes</value>
+</samba:parameter>
bool lp_winbind_offline_logon(void);
bool lp_winbind_normalize_names(void);
bool lp_winbind_rpc_only(void);
+bool lp_create_krb5_conf(void);
const char **lp_idmap_domains(void);
const char *lp_idmap_backend(void);
char *lp_idmap_alloc_backend(void);
const char *sitename,
struct sockaddr_storage *pss)
{
- char *dname = lock_path("smb_krb5");
+ char *dname;
char *tmpname = NULL;
char *fname = NULL;
char *file_contents = NULL;
char *realm_upper = NULL;
bool result = false;
+ if (!lp_create_krb5_conf()) {
+ return false;
+ }
+
+ dname = lock_path("smb_krb5");
if (!dname) {
return false;
}
bool bWinbindOfflineLogon;
bool bWinbindNormalizeNames;
bool bWinbindRpcOnly;
+ bool bCreateKrb5Conf;
char *szIdmapBackend;
char *szIdmapAllocBackend;
char *szAddShareCommand;
.enum_list = NULL,
.flags = FLAG_ADVANCED,
},
+ {
+ .label = "create krb5 conf",
+ .type = P_BOOL,
+ .p_class = P_GLOBAL,
+ .ptr = &Globals.bCreateKrb5Conf,
+ .special = NULL,
+ .enum_list = NULL,
+ .flags = FLAG_ADVANCED,
+ },
{NULL, P_BOOL, P_NONE, NULL, NULL, NULL, 0}
};
#endif
Globals.bUnixExtensions = True;
Globals.bResetOnZeroVC = False;
+ Globals.bCreateKrb5Conf = true;
/* hostname lookups can be very expensive and are broken on
a large number of sites (tridge) */
FN_GLOBAL_BOOL(lp_winbind_offline_logon, &Globals.bWinbindOfflineLogon)
FN_GLOBAL_BOOL(lp_winbind_normalize_names, &Globals.bWinbindNormalizeNames)
FN_GLOBAL_BOOL(lp_winbind_rpc_only, &Globals.bWinbindRpcOnly)
+FN_GLOBAL_BOOL(lp_create_krb5_conf, &Globals.bCreateKrb5Conf)
FN_GLOBAL_CONST_STRING(lp_idmap_backend, &Globals.szIdmapBackend)
FN_GLOBAL_STRING(lp_idmap_alloc_backend, &Globals.szIdmapAllocBackend)