summaryrefslogtreecommitdiff
path: root/server/providers/krb5
diff options
context:
space:
mode:
authorStephen Gallagher <sgallagh@redhat.com>2009-09-22 09:47:41 -0400
committerStephen Gallagher <sgallagh@redhat.com>2009-09-25 09:03:29 -0400
commit8263230a0c543a737ab17a071a0ea964dcab4259 (patch)
tree373caef346d1b73f3dcf6d0d168402f3eecc4d23 /server/providers/krb5
parentc65b34ae1d5794fc4456a25705163f56283047d2 (diff)
downloadsssd-8263230a0c543a737ab17a071a0ea964dcab4259.tar.gz
sssd-8263230a0c543a737ab17a071a0ea964dcab4259.tar.bz2
sssd-8263230a0c543a737ab17a071a0ea964dcab4259.zip
Upgrade confdb to version 2
This converts a great many configuration options to the new standard format.
Diffstat (limited to 'server/providers/krb5')
-rw-r--r--server/providers/krb5/krb5_auth.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/server/providers/krb5/krb5_auth.c b/server/providers/krb5/krb5_auth.c
index 631f7086..7510c066 100644
--- a/server/providers/krb5/krb5_auth.c
+++ b/server/providers/krb5/krb5_auth.c
@@ -867,7 +867,7 @@ int sssm_krb5_auth_init(struct be_ctx *bectx,
ctx->action = INIT_PW;
ret = confdb_get_string(bectx->cdb, ctx, bectx->conf_path,
- "krb5KDCIP", NULL, &value);
+ CONFDB_KRB5_KDCIP, NULL, &value);
if (ret != EOK) goto fail;
if (value == NULL) {
DEBUG(2, ("Missing krb5KDCIP, authentication might fail.\n"));
@@ -881,7 +881,7 @@ int sssm_krb5_auth_init(struct be_ctx *bectx,
ctx->kdcip = value;
ret = confdb_get_string(bectx->cdb, ctx, bectx->conf_path,
- "krb5REALM", NULL, &value);
+ CONFDB_KRB5_REALM, NULL, &value);
if (ret != EOK) goto fail;
if (value == NULL) {
DEBUG(4, ("Missing krb5REALM authentication might fail.\n"));
@@ -895,7 +895,7 @@ int sssm_krb5_auth_init(struct be_ctx *bectx,
ctx->realm = value;
ret = confdb_get_string(bectx->cdb, ctx, bectx->conf_path,
- "krb5ccache_dir", "/tmp", &value);
+ CONFDB_KRB5_CCACHEDIR, "/tmp", &value);
if (ret != EOK) goto fail;
ret = lstat(value, &stat_buf);
if (ret != EOK) {
@@ -910,7 +910,8 @@ int sssm_krb5_auth_init(struct be_ctx *bectx,
ctx->ccache_dir = value;
ret = confdb_get_string(bectx->cdb, ctx, bectx->conf_path,
- "krb5ccname_template", "FILE:%d/krb5cc_%U_XXXXXX",
+ CONFDB_KRB5_CCNAME_TMPL,
+ "FILE:%d/krb5cc_%U_XXXXXX",
&value);
if (ret != EOK) goto fail;
if (value[0] != '/' && strncmp(value, "FILE:", 5) != 0) {
@@ -921,12 +922,14 @@ int sssm_krb5_auth_init(struct be_ctx *bectx,
ctx->ccname_template = value;
ret = confdb_get_bool(bectx->cdb, ctx, bectx->conf_path,
- "krb5try_simple_upn", false, &bool_value);
+ CONFDB_KRB5_TRY_SIMPLE_UPN, false,
+ &bool_value);
if (ret != EOK) goto fail;
ctx->try_simple_upn = bool_value;
ret = confdb_get_string(bectx->cdb, ctx, bectx->conf_path,
- "krb5changepw_principle", "kadmin/changepw",
+ CONFDB_KRB5_CHANGEPW_PRINC,
+ "kadmin/changepw",
&value);
if (ret != EOK) goto fail;
if (strchr(value, '@') == NULL) {
@@ -945,7 +948,7 @@ int sssm_krb5_auth_init(struct be_ctx *bectx,
}
ret = confdb_get_int(bectx->cdb, ctx, bectx->conf_path,
- "krb5auth_timeout", 15, &int_value);
+ CONFDB_KRB5_AUTH_TIMEOUT, 15, &int_value);
if (ret != EOK) goto fail;
if (int_value <= 0) {
DEBUG(4, ("krb5auth_timeout has to be a positive value.\n"));