summaryrefslogtreecommitdiff
path: root/src/providers/proxy
diff options
context:
space:
mode:
Diffstat (limited to 'src/providers/proxy')
-rw-r--r--src/providers/proxy/proxy.h1
-rw-r--r--src/providers/proxy/proxy_id.c14
-rw-r--r--src/providers/proxy/proxy_init.c5
-rw-r--r--src/providers/proxy/proxy_netgroup.c3
-rw-r--r--src/providers/proxy/proxy_services.c6
5 files changed, 12 insertions, 17 deletions
diff --git a/src/providers/proxy/proxy.h b/src/providers/proxy/proxy.h
index e9a550fd..3641d6ee 100644
--- a/src/providers/proxy/proxy.h
+++ b/src/providers/proxy/proxy.h
@@ -100,7 +100,6 @@ struct authtok_conv {
struct proxy_id_ctx {
struct be_ctx *be;
- int entry_cache_timeout;
struct proxy_nss_ops ops;
void *handle;
};
diff --git a/src/providers/proxy/proxy_id.c b/src/providers/proxy/proxy_id.c
index b11750f7..206af294 100644
--- a/src/providers/proxy/proxy_id.c
+++ b/src/providers/proxy/proxy_id.c
@@ -100,7 +100,7 @@ static int get_pw_name(TALLOC_CTX *mem_ctx,
break;
}
- ret = save_user(sysdb, !dom->case_sensitive, pwd, ctx->entry_cache_timeout);
+ ret = save_user(sysdb, !dom->case_sensitive, pwd, dom->user_timeout);
if (ret) {
goto done;
}
@@ -263,7 +263,7 @@ static int get_pw_uid(TALLOC_CTX *mem_ctx,
break;
}
- ret = save_user(sysdb, !dom->case_sensitive, pwd, ctx->entry_cache_timeout);
+ ret = save_user(sysdb, !dom->case_sensitive, pwd, dom->user_timeout);
if (ret) {
goto done;
}
@@ -394,7 +394,7 @@ again:
goto again; /* skip */
}
- ret = save_user(sysdb, !dom->case_sensitive, pwd, ctx->entry_cache_timeout);
+ ret = save_user(sysdb, !dom->case_sensitive, pwd, dom->user_timeout);
if (ret) {
/* Do not fail completely on errors.
* Just report the failure to save and go on */
@@ -603,7 +603,7 @@ again:
break;
}
- ret = save_group(sysdb, dom, grp, ctx->entry_cache_timeout);
+ ret = save_group(sysdb, dom, grp, dom->group_timeout);
if (ret) {
goto done;
}
@@ -732,7 +732,7 @@ again:
break;
}
- ret = save_group(sysdb, dom, grp, ctx->entry_cache_timeout);
+ ret = save_group(sysdb, dom, grp, dom->group_timeout);
if (ret) {
goto done;
}
@@ -864,7 +864,7 @@ again:
goto again; /* skip */
}
- ret = save_group(sysdb, dom, grp, ctx->entry_cache_timeout);
+ ret = save_group(sysdb, dom, grp, dom->group_timeout);
if (ret) {
/* Do not fail completely on errors.
* Just report the failure to save and go on */
@@ -967,7 +967,7 @@ static int get_initgr(TALLOC_CTX *mem_ctx,
break;
}
- ret = save_user(sysdb, !dom->case_sensitive, pwd, ctx->entry_cache_timeout);
+ ret = save_user(sysdb, !dom->case_sensitive, pwd, dom->user_timeout);
if (ret) {
goto done;
}
diff --git a/src/providers/proxy/proxy_init.c b/src/providers/proxy/proxy_init.c
index d43550bf..46b2e7c3 100644
--- a/src/providers/proxy/proxy_init.c
+++ b/src/providers/proxy/proxy_init.c
@@ -101,11 +101,6 @@ int sssm_proxy_id_init(struct be_ctx *bectx,
}
ctx->be = bectx;
- ret = confdb_get_int(bectx->cdb, ctx, bectx->conf_path,
- CONFDB_DOMAIN_ENTRY_CACHE_TIMEOUT, 600,
- &ctx->entry_cache_timeout);
- if (ret != EOK) goto done;
-
ret = confdb_get_string(bectx->cdb, ctx, bectx->conf_path,
CONFDB_PROXY_LIBNAME, NULL, &libname);
if (ret != EOK) goto done;
diff --git a/src/providers/proxy/proxy_netgroup.c b/src/providers/proxy/proxy_netgroup.c
index c81e60c6..47a425b4 100644
--- a/src/providers/proxy/proxy_netgroup.c
+++ b/src/providers/proxy/proxy_netgroup.c
@@ -152,7 +152,8 @@ errno_t get_netgroup(struct proxy_id_ctx *ctx,
}
ret = save_netgroup(sysdb, name, attrs,
- !dom->case_sensitive, ctx->entry_cache_timeout);
+ !dom->case_sensitive,
+ dom->netgroup_timeout);
if (ret != EOK) {
DEBUG(1, ("sysdb_add_netgroup failed.\n"));
goto done;
diff --git a/src/providers/proxy/proxy_services.c b/src/providers/proxy/proxy_services.c
index 79508a21..e5654d75 100644
--- a/src/providers/proxy/proxy_services.c
+++ b/src/providers/proxy/proxy_services.c
@@ -138,7 +138,7 @@ get_serv_byname(struct proxy_id_ctx *ctx,
/* Results found. Save them into the cache */
ret = proxy_save_service(sysdb, result,
!dom->case_sensitive,
- ctx->entry_cache_timeout);
+ dom->service_timeout);
}
done:
@@ -191,7 +191,7 @@ get_serv_byport(struct proxy_id_ctx *ctx,
/* Results found. Save them into the cache */
ret = proxy_save_service(sysdb, result,
!dom->case_sensitive,
- ctx->entry_cache_timeout);
+ dom->service_timeout);
}
done:
@@ -339,7 +339,7 @@ again:
const_aliases,
protocols,
NULL, NULL,
- ctx->entry_cache_timeout,
+ dom->service_timeout,
now);
if (ret) {
/* Do not fail completely on errors.