ipa_id.h revision 8eb981dd8bc85aee7a913c6f0096ad47f3382339
5717e8e12768ab1d667cd3e908e5f3ffe540655aTimo Sirainen/*
5717e8e12768ab1d667cd3e908e5f3ffe540655aTimo Sirainen SSSD
70267341ccf430f6c77646e69c24e33d111b65a8Pascal Volk
70267341ccf430f6c77646e69c24e33d111b65a8Pascal Volk IPA Identity Backend Module
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk Authors:
3188bfdf2c36fed3cbbea5e3901850e34e174a56Timo Sirainen Jan Zeleny <jzeleny@redhat.com>
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk Copyright (C) 2011 Red Hat
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk This program is free software; you can redistribute it and/or modify
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk it under the terms of the GNU General Public License as published by
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk the Free Software Foundation; either version 3 of the License, or
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk (at your option) any later version.
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk This program is distributed in the hope that it will be useful,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk but WITHOUT ANY WARRANTY; without even the implied warranty of
0610b6dfbdcb6a8f234a6495ec243bcf996b5572Pascal Volk MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk GNU General Public License for more details.
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk You should have received a copy of the GNU General Public License
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk along with this program. If not, see <http://www.gnu.org/licenses/>.
0610b6dfbdcb6a8f234a6495ec243bcf996b5572Pascal Volk*/
88c816e8be4e1a29bca8b67d67a92c67a33f3795Timo Sirainen
e0579d45910f8a4ed55aa670f136db183344a786Timo Sirainen
ed1ad90a15ea48d43edef858da3a598adca8b1feTimo Sirainen#ifndef _IPA_ID_H_
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk#define _IPA_ID_H_
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk#include "providers/ldap/ldap_common.h"
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk#include "providers/ipa/ipa_common.h"
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk#include "providers/ldap/sdap.h"
e0579d45910f8a4ed55aa670f136db183344a786Timo Sirainen#include "providers/ipa/ipa_subdomains.h"
f6b42d6832887ee5a94deb278f924bae7216e660Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk#define IPA_DEFAULT_VIEW_NAME "Default Trust View"
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volkvoid ipa_account_info_handler(struct be_req *breq);
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volkstruct tevent_req *ipa_get_netgroups_send(TALLOC_CTX *memctx,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct tevent_context *ev,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sysdb_ctx *sysdb,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sss_domain_info *dom,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sdap_options *opts,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct ipa_options *ipa_options,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sdap_handle *sh,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk const char **attrs,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk const char *filter,
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volk int timeout);
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volk
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volkint ipa_get_netgroups_recv(struct tevent_req *req,
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volk TALLOC_CTX *mem_ctx,
44c6dbf0a48ebf3d18aec72849bd114b54f4b0aaPascal Volk size_t *reply_count,
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volk struct sysdb_attrs ***reply);
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volk
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volkvoid ipa_check_online(struct be_req *be_req);
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volkstruct tevent_req *ipa_s2n_get_acct_info_send(TALLOC_CTX *mem_ctx,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct tevent_context *ev,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct ipa_id_ctx *ipa_ctx,
0610b6dfbdcb6a8f234a6495ec243bcf996b5572Pascal Volk struct sdap_options *opts,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sss_domain_info *dom,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sysdb_attrs *override_attrs,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sdap_handle *sh,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk int entry_type,
2f45711505ab4564ee8a64ed7af87ae725a3f5d8Timo Sirainen struct req_input *req_input);
88c816e8be4e1a29bca8b67d67a92c67a33f3795Timo Sirainenint ipa_s2n_get_acct_info_recv(struct tevent_req *req);
e0579d45910f8a4ed55aa670f136db183344a786Timo Sirainen
ed1ad90a15ea48d43edef858da3a598adca8b1feTimo Sirainenstruct tevent_req *ipa_get_subdom_acct_send(TALLOC_CTX *memctx,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct tevent_context *ev,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct ipa_id_ctx *ipa_ctx,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sysdb_attrs *override_attrs,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct be_acct_req *ar);
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volkint ipa_get_subdom_acct_recv(struct tevent_req *req, int *dp_error_out);
e0579d45910f8a4ed55aa670f136db183344a786Timo Sirainen
f6b42d6832887ee5a94deb278f924bae7216e660Pascal Volkstruct tevent_req *ipa_get_ad_acct_send(TALLOC_CTX *mem_ctx,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct tevent_context *ev,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct ipa_id_ctx *ipa_ctx,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct be_req *be_req,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sysdb_attrs *override_attrs,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct be_acct_req *ar);
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volkerrno_t ipa_get_ad_acct_recv(struct tevent_req *req, int *dp_error_out);
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volkerrno_t get_be_acct_req_for_sid(TALLOC_CTX *mem_ctx, const char *sid,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk const char *domain_name,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct be_acct_req **_ar);
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volk
28372fb7f889fbf9d0b5266f154f7f3004e26324Pascal Volkstruct tevent_req *ipa_get_ad_override_send(TALLOC_CTX *mem_ctx,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct tevent_context *ev,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct sdap_id_ctx *sdap_id_ctx,
fa9f5378ec558c451f1f1c47a4c41aa7c916c929Pascal Volk struct ipa_options *ipa_options,
70267341ccf430f6c77646e69c24e33d111b65a8Pascal Volk const char *ipa_realm,
5717e8e12768ab1d667cd3e908e5f3ffe540655aTimo Sirainen const char *view_name,
ea954a624a8c31a4d7f05ceaa2d7d3b7768da58bDennis Schridde struct be_acct_req *ar);
errno_t ipa_get_ad_override_recv(struct tevent_req *req, int *dp_error_out,
TALLOC_CTX *mem_ctx,
struct sysdb_attrs **override_attrs);
struct tevent_req *ipa_subdomain_account_send(TALLOC_CTX *memctx,
struct tevent_context *ev,
struct ipa_id_ctx *ipa_ctx,
struct be_req *be_req,
struct be_acct_req *ar);
errno_t ipa_subdomain_account_recv(struct tevent_req *req, int *dp_error_out);
errno_t split_ipa_anchor(TALLOC_CTX *mem_ctx, const char *anchor,
char **_anchor_domain, char **_ipa_uuid);
#endif