make samba forwarding a runtime configure option

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13859 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2004-05-23 21:33:26 +00:00
parent da93cd9630
commit 1824e16f28

View File

@@ -52,6 +52,7 @@ LDAP_message2entry(krb5_context context, HDB * db, LDAPMessage * msg,
static const char *default_structural_object = "account";
static char *structural_object;
static int samba_forwardable;
/*
*
@@ -1204,7 +1205,8 @@ LDAP_message2entry(krb5_context context, HDB * db, LDAPMessage * msg,
goto out2;
/* Allow forwarding */
ent->flags.forwardable = TRUE;
if (samba_forwardable)
ent->flags.forwardable = TRUE;
for (i=0; i < flags_len; i++) {
switch (samba_acct_flags[i]) {
@@ -1673,6 +1675,10 @@ hdb_ldap_create(krb5_context context, HDB ** db, const char *arg)
}
}
samba_forwardable =
krb5_config_get_bool_default(context, NULL, TRUE,
"kdc", "hdb-samba-forwardable", NULL);
*db = malloc(sizeof(**db));
if (*db == NULL) {
krb5_set_error_string(context, "malloc: out of memory");