diff options
author | Jakub Hrozek <jhrozek@redhat.com> | 2013-05-27 08:48:02 +0200 |
---|---|---|
committer | Jakub Hrozek <jhrozek@redhat.com> | 2013-06-07 00:14:13 +0200 |
commit | 749cfb5d3270b5daf389d51a0dbd3fd2aec6e05d (patch) | |
tree | 65abb8438d2d31bd627861ff2fdc8cda6c07c960 /src/providers/ldap/sdap.h | |
parent | 9aa117a93e315f790a1922d9ac7bd484878b621e (diff) | |
download | sssd-749cfb5d3270b5daf389d51a0dbd3fd2aec6e05d.tar.gz sssd-749cfb5d3270b5daf389d51a0dbd3fd2aec6e05d.tar.xz sssd-749cfb5d3270b5daf389d51a0dbd3fd2aec6e05d.zip |
LDAP: new SDAP domain structure
Previously an sdap_id_ctx was always tied to one domain with a single
set of search bases. But with the introduction of Global Catalog
lookups, primary domain and subdomains might have different search
bases.
This patch introduces a new structure sdap_domain that contains an sssd
domain or subdomain and a set of search bases. With this patch, there is
only one sdap_domain that describes the primary domain.
Diffstat (limited to 'src/providers/ldap/sdap.h')
-rw-r--r-- | src/providers/ldap/sdap.h | 28 |
1 files changed, 20 insertions, 8 deletions
diff --git a/src/providers/ldap/sdap.h b/src/providers/ldap/sdap.h index 162250fff..f77636b3c 100644 --- a/src/providers/ldap/sdap.h +++ b/src/providers/ldap/sdap.h @@ -366,6 +366,22 @@ enum dc_functional_level { DS_BEHAVIOR_WIN2012 = 5 }; +struct sdap_domain { + struct sss_domain_info *dom; + + struct sdap_search_base **search_bases; + struct sdap_search_base **user_search_bases; + struct sdap_search_base **group_search_bases; + struct sdap_search_base **netgroup_search_bases; + struct sdap_search_base **sudo_search_bases; + struct sdap_search_base **service_search_bases; + struct sdap_search_base **autofs_search_bases; + + struct sdap_domain *next, *prev; + /* Need to modify the list from a talloc destructor */ + struct sdap_domain **head; +}; + struct sdap_options { struct dp_option *basic; struct sdap_attr_map *gen_map; @@ -390,13 +406,8 @@ struct sdap_options { SDAP_SCHEMA_AD = 4 /* AD's member/memberof */ } schema_type; - struct sdap_search_base **search_bases; - struct sdap_search_base **user_search_bases; - struct sdap_search_base **group_search_bases; - struct sdap_search_base **netgroup_search_bases; - struct sdap_search_base **sudo_search_bases; - struct sdap_search_base **service_search_bases; - struct sdap_search_base **autofs_search_bases; + /* The search bases for the domain or its subdomain */ + struct sdap_domain *sdom; bool support_matching_rule; enum dc_functional_level dc_functional_level; @@ -474,7 +485,8 @@ int sdap_control_create(struct sdap_handle *sh, const char *oid, int iscritical, int sdap_replace_id(struct sysdb_attrs *entry, const char *attr, id_t val); errno_t sdap_set_config_options_with_rootdse(struct sysdb_attrs *rootdse, - struct sdap_options *opts); + struct sdap_options *opts, + struct sdap_domain *sdom); int sdap_get_server_opts_from_rootdse(TALLOC_CTX *memctx, const char *server, struct sysdb_attrs *rootdse, |