summaryrefslogtreecommitdiff
path: root/src/providers/ipa
diff options
context:
space:
mode:
authorStephen Gallagher <sgallagh@redhat.com>2011-09-13 09:07:26 -0400
committerStephen Gallagher <sgallagh@redhat.com>2011-11-02 11:12:12 -0400
commit09b663e6dfd2ed09cead04f926d3e99e9ac01894 (patch)
treec5764cb1f1c5e59099a37478dd2e3fe35f289054 /src/providers/ipa
parent82962098e3848ed039a57522d74fc500bc6df8ad (diff)
downloadsssd-09b663e6dfd2ed09cead04f926d3e99e9ac01894.tar.gz
sssd-09b663e6dfd2ed09cead04f926d3e99e9ac01894.tar.bz2
sssd-09b663e6dfd2ed09cead04f926d3e99e9ac01894.zip
LDAP: Add parser for multiple search bases
Diffstat (limited to 'src/providers/ipa')
-rw-r--r--src/providers/ipa/ipa_common.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/providers/ipa/ipa_common.c b/src/providers/ipa/ipa_common.c
index c6229456..12c0bb67 100644
--- a/src/providers/ipa/ipa_common.c
+++ b/src/providers/ipa/ipa_common.c
@@ -332,10 +332,15 @@ int ipa_get_id_options(struct ipa_options *ipa_opts,
if (ret != EOK) {
goto done;
}
+
DEBUG(6, ("Option %s set to %s\n",
ipa_opts->id->basic[SDAP_SEARCH_BASE].opt_name,
dp_opt_get_string(ipa_opts->id->basic, SDAP_SEARCH_BASE)));
}
+ ret = sdap_parse_search_base(ipa_opts->id, ipa_opts->id,
+ SDAP_SEARCH_BASE,
+ &ipa_opts->id->search_bases);
+ if (ret != EOK) goto done;
/* set krb realm */
if (NULL == dp_opt_get_string(ipa_opts->id->basic, SDAP_KRB5_REALM)) {
@@ -414,11 +419,16 @@ int ipa_get_id_options(struct ipa_options *ipa_opts,
if (ret != EOK) {
goto done;
}
+
DEBUG(6, ("Option %s set to %s\n",
ipa_opts->id->basic[SDAP_USER_SEARCH_BASE].opt_name,
dp_opt_get_string(ipa_opts->id->basic,
SDAP_USER_SEARCH_BASE)));
}
+ ret = sdap_parse_search_base(ipa_opts->id, ipa_opts->id,
+ SDAP_USER_SEARCH_BASE,
+ &ipa_opts->id->user_search_bases);
+ if (ret != EOK) goto done;
if (NULL == dp_opt_get_string(ipa_opts->id->basic,
SDAP_GROUP_SEARCH_BASE)) {
@@ -428,11 +438,16 @@ int ipa_get_id_options(struct ipa_options *ipa_opts,
if (ret != EOK) {
goto done;
}
+
DEBUG(6, ("Option %s set to %s\n",
ipa_opts->id->basic[SDAP_GROUP_SEARCH_BASE].opt_name,
dp_opt_get_string(ipa_opts->id->basic,
SDAP_GROUP_SEARCH_BASE)));
}
+ ret = sdap_parse_search_base(ipa_opts->id, ipa_opts->id,
+ SDAP_GROUP_SEARCH_BASE,
+ &ipa_opts->id->group_search_bases);
+ if (ret != EOK) goto done;
if (NULL == dp_opt_get_string(ipa_opts->id->basic,
SDAP_NETGROUP_SEARCH_BASE)) {
@@ -461,11 +476,16 @@ int ipa_get_id_options(struct ipa_options *ipa_opts,
goto done;
}
#endif
+
DEBUG(6, ("Option %s set to %s\n",
ipa_opts->id->basic[SDAP_NETGROUP_SEARCH_BASE].opt_name,
dp_opt_get_string(ipa_opts->id->basic,
SDAP_NETGROUP_SEARCH_BASE)));
}
+ ret = sdap_parse_search_base(ipa_opts->id, ipa_opts->id,
+ SDAP_NETGROUP_SEARCH_BASE,
+ &ipa_opts->id->netgroup_search_bases);
+ if (ret != EOK) goto done;
value = dp_opt_get_string(ipa_opts->id->basic, SDAP_DEREF);
if (value != NULL) {