2009-08-04 01:44:46 +04:00
#include "idl_types.h"
2011-03-23 20:18:13 +03:00
import "lsa.idl", "netlogon.idl", "misc.idl", "security.idl", "idmap.idl";
2009-08-04 01:44:46 +04:00
2009-07-28 23:06:11 +04:00
[
uuid("bf09192c-ed60-4928-9dff-d0d7bcb03ed8"),
endpoint("ncalrpc:"),
pointer_default(unique),
version(1.0),
2010-05-13 01:57:27 +04:00
helpstring("winbind parent-child protocol"),
no_srv_register
2009-07-28 23:06:11 +04:00
]
2014-05-08 04:17:32 +04:00
interface winbind
2009-07-28 23:06:11 +04:00
{
2014-05-08 04:17:32 +04:00
/* Private methods */
2009-07-28 23:06:11 +04:00
void wbint_Ping(
[in] uint32 in_data,
[out] uint32 *out_data
);
2009-08-04 01:44:46 +04:00
NTSTATUS wbint_LookupSid(
[in] dom_sid *sid,
[out] lsa_SidType *type,
[out,string,charset(UTF8)] char **domain,
[out,string,charset(UTF8)] char **name
);
2009-08-04 15:22:34 +04:00
2011-03-11 14:48:11 +03:00
NTSTATUS wbint_LookupSids(
[in] lsa_SidArray *sids,
[out,ref] lsa_RefDomainList *domains,
[out,ref] lsa_TransNameArray *names
);
2009-08-04 15:22:34 +04:00
NTSTATUS wbint_LookupName(
[in,string,charset(UTF8)] char *domain,
[in,string,charset(UTF8)] char *name,
[in] uint32 flags,
[out] lsa_SidType *type,
[out] dom_sid *sid
);
2009-08-04 21:28:59 +04:00
2011-03-23 20:18:13 +03:00
typedef struct {
id_type type;
uint32 domain_index;
uint32 rid;
2012-11-18 16:51:13 +04:00
unixid xid;
2011-03-23 20:18:13 +03:00
} wbint_TransID;
typedef struct {
uint32 num_ids;
[size_is(num_ids)] wbint_TransID ids[];
} wbint_TransIDArray;
NTSTATUS wbint_Sids2UnixIDs(
[in] lsa_RefDomainList *domains,
[in,out] wbint_TransIDArray *ids
);
2009-08-04 21:52:39 +04:00
NTSTATUS wbint_Uid2Sid(
[in,unique,string,charset(UTF8)] char *dom_name,
[in] hyper uid,
[out] dom_sid *sid
);
2009-08-04 22:19:03 +04:00
NTSTATUS wbint_Gid2Sid(
[in,unique,string,charset(UTF8)] char *dom_name,
[in] hyper gid,
[out] dom_sid *sid
);
2009-08-04 23:23:13 +04:00
2009-08-30 11:41:43 +04:00
NTSTATUS wbint_AllocateUid(
[out] hyper *uid
);
2009-08-30 11:46:34 +04:00
NTSTATUS wbint_AllocateGid(
[out] hyper *gid
);
2009-08-04 23:23:13 +04:00
typedef [public] struct {
[string,charset(UTF8)] char *acct_name;
[string,charset(UTF8)] char *full_name;
[string,charset(UTF8)] char *homedir;
[string,charset(UTF8)] char *shell;
hyper primary_gid;
dom_sid user_sid;
dom_sid group_sid;
} wbint_userinfo;
NTSTATUS wbint_QueryUser(
[in] dom_sid *sid,
[out] wbint_userinfo *info
);
2009-08-04 23:54:05 +04:00
typedef [public] struct {
uint32 num_sids;
[size_is(num_sids)] dom_sid sids[];
} wbint_SidArray;
typedef [public] struct {
uint32 num_rids;
[size_is(num_rids)] uint32 rids[];
} wbint_RidArray;
NTSTATUS wbint_LookupUserAliases(
[in] wbint_SidArray *sids,
[out] wbint_RidArray *rids
);
2009-08-05 00:07:01 +04:00
NTSTATUS wbint_LookupUserGroups(
[in] dom_sid *sid,
[out] wbint_SidArray *sids
);
2009-08-15 13:16:28 +04:00
NTSTATUS wbint_QuerySequenceNumber(
[out] uint32 *sequence
);
2009-08-16 12:58:43 +04:00
typedef [public] struct {
dom_sid sid;
lsa_SidType type;
2009-08-23 14:38:35 +04:00
[string,charset(UTF8)] char *name;
} wbint_Principal;
2009-08-16 12:58:43 +04:00
typedef [public] struct {
2009-08-23 14:43:43 +04:00
int num_principals;
[size_is(num_principals)] wbint_Principal principals[];
} wbint_Principals;
2009-08-16 12:58:43 +04:00
NTSTATUS wbint_LookupGroupMembers(
[in] dom_sid *sid,
[in] lsa_SidType type,
2009-08-23 14:43:43 +04:00
[out] wbint_Principals *members
2009-08-16 12:58:43 +04:00
);
2009-08-18 00:40:19 +04:00
typedef [public] struct {
uint32 num_userinfos;
[size_is(num_userinfos)] wbint_userinfo userinfos[];
} wbint_userinfos;
NTSTATUS wbint_QueryUserList(
[out] wbint_userinfos *users
);
2009-08-26 00:13:34 +04:00
2009-08-27 21:54:18 +04:00
NTSTATUS wbint_QueryGroupList(
[out] wbint_Principals *groups
);
2009-08-26 00:13:34 +04:00
NTSTATUS wbint_DsGetDcName(
[in,string,charset(UTF8)] char *domain_name,
[in,unique] GUID *domain_guid,
[in,string,unique,charset(UTF8)] char *site_name,
[in] uint32 flags,
[out] netr_DsRGetDCNameInfo **dc_info
);
2009-08-27 19:11:24 +04:00
NTSTATUS wbint_LookupRids(
2011-06-27 16:34:39 +04:00
[in] dom_sid *domain_sid,
2009-08-27 19:11:24 +04:00
[in] wbint_RidArray *rids,
2010-12-04 22:16:00 +03:00
[out,string,charset(UTF8)] char **domain_name,
2009-08-27 19:11:24 +04:00
[out] wbint_Principals *names
);
2009-09-06 11:32:34 +04:00
NTSTATUS wbint_CheckMachineAccount(
);
2009-09-06 16:47:06 +04:00
2009-10-06 20:26:33 +04:00
NTSTATUS wbint_ChangeMachineAccount(
);
2009-12-21 23:50:43 +03:00
NTSTATUS wbint_PingDc(
2012-08-10 19:10:42 +04:00
[out,string,charset(UTF8)] char **dcname
2009-12-21 23:50:43 +03:00
);
2014-05-06 09:00:09 +04:00
2014-05-08 04:17:32 +04:00
/* Public methods available via IRPC */
typedef [switch_type(uint16)] union netr_LogonLevel netr_LogonLevel;
typedef [switch_type(uint16)] union netr_Validation netr_Validation;
/*
* do a netr_LogonSamLogon() against the right DC
*/
NTSTATUS winbind_SamLogon(
[in] uint16 logon_level,
[in] [switch_is(logon_level)] netr_LogonLevel logon,
[in] uint16 validation_level,
[out] [switch_is(validation_level)] netr_Validation validation,
[out] uint8 authoritative
);
NTSTATUS winbind_DsrUpdateReadOnlyServerDnsRecords(
2014-05-06 09:00:09 +04:00
[in,unique] [string,charset(UTF16)] uint16 *site_name,
[in] uint32 dns_ttl,
[in,out,ref] NL_DNS_NAME_INFO_ARRAY *dns_names
);
2014-05-08 04:17:32 +04:00
2014-12-19 12:36:29 +03:00
/*
* do a netr_LogonControl2Ex() against the right DC
*/
typedef [v1_enum] enum netr_LogonControlCode netr_LogonControlCode;
typedef [switch_type(netr_LogonControlCode)] union netr_CONTROL_DATA_INFORMATION netr_CONTROL_DATA_INFORMATION;
typedef [switch_type(uint32)] union netr_CONTROL_QUERY_INFORMATION netr_CONTROL_QUERY_INFORMATION;
WERROR winbind_LogonControl(
[in] netr_LogonControlCode function_code,
[in] uint32 level,
[in,ref][switch_is(function_code)] netr_CONTROL_DATA_INFORMATION *data,
[out,ref][switch_is(level)] netr_CONTROL_QUERY_INFORMATION *query
);
2009-10-06 20:26:33 +04:00
}