summaryrefslogtreecommitdiffstats
path: root/src/util/util.h
diff options
context:
space:
mode:
authorPavel Březina <pbrezina@redhat.com>2013-09-02 15:15:59 +0200
committerJakub Hrozek <jhrozek@redhat.com>2013-09-17 16:13:32 +0200
commit1110ac9c5739ca19dd71917ddb4012110ff64469 (patch)
tree9fdf4e43bce83b0de354214988cebff60dd64fc1 /src/util/util.h
parentc4a1a6707426f97537190a32895922507844d547 (diff)
downloadsssd-1110ac9c5739ca19dd71917ddb4012110ff64469.tar.gz
sssd-1110ac9c5739ca19dd71917ddb4012110ff64469.tar.xz
sssd-1110ac9c5739ca19dd71917ddb4012110ff64469.zip
util: add find_subdomain_by_sid()
This function takes domain SID (doesn't have the last component) or object SID (have all components) and returns subdomain. The subdomain is found by comparing domain->domainid with the SID. E.g. domain SID: S-1-5-21-3940105347-3434501867-2690409756 object SID: S-1-5-21-3940105347-3434501867-2690409756-513 Resolves: https://fedorahosted.org/sssd/ticket/2034
Diffstat (limited to 'src/util/util.h')
-rw-r--r--src/util/util.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/util/util.h b/src/util/util.h
index cae4a49ab..3a1da2dcf 100644
--- a/src/util/util.h
+++ b/src/util/util.h
@@ -546,6 +546,8 @@ struct sss_domain_info *get_next_domain(struct sss_domain_info *domain,
struct sss_domain_info *find_subdomain_by_name(struct sss_domain_info *domain,
const char *name,
bool match_any);
+struct sss_domain_info *find_subdomain_by_sid(struct sss_domain_info *domain,
+ const char *sid);
bool subdomain_enumerates(struct sss_domain_info *parent,
const char *sd_name);