summaryrefslogtreecommitdiff
path: root/source3/nsswitch
diff options
context:
space:
mode:
Diffstat (limited to 'source3/nsswitch')
-rw-r--r--source3/nsswitch/wb_client.c14
-rw-r--r--source3/nsswitch/wbinfo.c2
-rw-r--r--source3/nsswitch/winbindd.h8
-rw-r--r--source3/nsswitch/winbindd_async.c30
-rw-r--r--source3/nsswitch/winbindd_cache.c28
-rw-r--r--source3/nsswitch/winbindd_creds.c2
-rw-r--r--source3/nsswitch/winbindd_group.c14
-rw-r--r--source3/nsswitch/winbindd_pam.c2
-rw-r--r--source3/nsswitch/winbindd_passdb.c8
-rw-r--r--source3/nsswitch/winbindd_reconnect.c6
-rw-r--r--source3/nsswitch/winbindd_rpc.c12
-rw-r--r--source3/nsswitch/winbindd_sid.c20
-rw-r--r--source3/nsswitch/winbindd_user.c4
-rw-r--r--source3/nsswitch/winbindd_util.c4
14 files changed, 77 insertions, 77 deletions
diff --git a/source3/nsswitch/wb_client.c b/source3/nsswitch/wb_client.c
index 2f0a694d68..77e2645b74 100644
--- a/source3/nsswitch/wb_client.c
+++ b/source3/nsswitch/wb_client.c
@@ -35,7 +35,7 @@ NSS_STATUS winbindd_request_response(int req_type,
/* Call winbindd to convert a name to a sid */
BOOL winbind_lookup_name(const char *dom_name, const char *name, DOM_SID *sid,
- enum SID_NAME_USE *name_type)
+ enum lsa_SidType *name_type)
{
struct winbindd_request request;
struct winbindd_response response;
@@ -56,7 +56,7 @@ BOOL winbind_lookup_name(const char *dom_name, const char *name, DOM_SID *sid,
&response)) == NSS_STATUS_SUCCESS) {
if (!string_to_sid(sid, response.data.sid.sid))
return False;
- *name_type = (enum SID_NAME_USE)response.data.sid.type;
+ *name_type = (enum lsa_SidType)response.data.sid.type;
}
return result == NSS_STATUS_SUCCESS;
@@ -66,7 +66,7 @@ BOOL winbind_lookup_name(const char *dom_name, const char *name, DOM_SID *sid,
BOOL winbind_lookup_sid(TALLOC_CTX *mem_ctx, const DOM_SID *sid,
const char **domain, const char **name,
- enum SID_NAME_USE *name_type)
+ enum lsa_SidType *name_type)
{
struct winbindd_request request;
struct winbindd_response response;
@@ -105,7 +105,7 @@ BOOL winbind_lookup_sid(TALLOC_CTX *mem_ctx, const DOM_SID *sid,
}
}
- *name_type = (enum SID_NAME_USE)response.data.name.type;
+ *name_type = (enum lsa_SidType)response.data.name.type;
DEBUG(10, ("winbind_lookup_sid: SUCCESS: SID %s -> %s %s\n",
sid_string_static(sid), response.data.name.dom_name,
@@ -117,7 +117,7 @@ BOOL winbind_lookup_rids(TALLOC_CTX *mem_ctx,
const DOM_SID *domain_sid,
int num_rids, uint32 *rids,
const char **domain_name,
- const char ***names, enum SID_NAME_USE **types)
+ const char ***names, enum lsa_SidType **types)
{
size_t i, buflen;
ssize_t len;
@@ -166,7 +166,7 @@ BOOL winbind_lookup_rids(TALLOC_CTX *mem_ctx,
*domain_name = talloc_strdup(mem_ctx, response.data.domain_name);
*names = TALLOC_ARRAY(mem_ctx, const char *, num_rids);
- *types = TALLOC_ARRAY(mem_ctx, enum SID_NAME_USE, num_rids);
+ *types = TALLOC_ARRAY(mem_ctx, enum lsa_SidType, num_rids);
if ((*names == NULL) || (*types == NULL)) {
goto fail;
@@ -183,7 +183,7 @@ BOOL winbind_lookup_rids(TALLOC_CTX *mem_ctx,
goto fail;
}
- (*types)[i] = (enum SID_NAME_USE)strtoul(p, &q, 10);
+ (*types)[i] = (enum lsa_SidType)strtoul(p, &q, 10);
if (*q != ' ') {
DEBUG(10, ("Got invalid reply: %s\n",
diff --git a/source3/nsswitch/wbinfo.c b/source3/nsswitch/wbinfo.c
index a393855f02..ffca4121fa 100644
--- a/source3/nsswitch/wbinfo.c
+++ b/source3/nsswitch/wbinfo.c
@@ -647,7 +647,7 @@ static BOOL wbinfo_lookuprids(char *domain_sid, char *arg)
const char *p;
char ridstr[32];
const char **names;
- enum SID_NAME_USE *types;
+ enum lsa_SidType *types;
const char *domain_name;
TALLOC_CTX *mem_ctx;
diff --git a/source3/nsswitch/winbindd.h b/source3/nsswitch/winbindd.h
index 73aaff9a11..98c0e12349 100644
--- a/source3/nsswitch/winbindd.h
+++ b/source3/nsswitch/winbindd.h
@@ -60,7 +60,7 @@ struct sid_ctr {
BOOL finished;
const char *domain;
const char *name;
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
};
struct winbindd_cli_state {
@@ -239,7 +239,7 @@ struct winbindd_methods {
const char *domain_name,
const char *name,
DOM_SID *sid,
- enum SID_NAME_USE *type);
+ enum lsa_SidType *type);
/* convert a sid to a user or group name */
NTSTATUS (*sid_to_name)(struct winbindd_domain *domain,
@@ -247,7 +247,7 @@ struct winbindd_methods {
const DOM_SID *sid,
char **domain_name,
char **name,
- enum SID_NAME_USE *type);
+ enum lsa_SidType *type);
NTSTATUS (*rids_to_names)(struct winbindd_domain *domain,
TALLOC_CTX *mem_ctx,
@@ -256,7 +256,7 @@ struct winbindd_methods {
size_t num_rids,
char **domain_name,
char ***names,
- enum SID_NAME_USE **types);
+ enum lsa_SidType **types);
/* lookup user info for a given SID */
NTSTATUS (*query_user)(struct winbindd_domain *domain,
diff --git a/source3/nsswitch/winbindd_async.c b/source3/nsswitch/winbindd_async.c
index bb8b523246..ccc4f219c6 100644
--- a/source3/nsswitch/winbindd_async.c
+++ b/source3/nsswitch/winbindd_async.c
@@ -551,9 +551,9 @@ static void lookupsid_recv(TALLOC_CTX *mem_ctx, BOOL success,
void *c, void *private_data)
{
void (*cont)(void *priv, BOOL succ, const char *dom_name,
- const char *name, enum SID_NAME_USE type) =
+ const char *name, enum lsa_SidType type) =
(void (*)(void *, BOOL, const char *, const char *,
- enum SID_NAME_USE))c;
+ enum lsa_SidType))c;
if (!success) {
DEBUG(5, ("Could not trigger lookupsid\n"));
@@ -569,14 +569,14 @@ static void lookupsid_recv(TALLOC_CTX *mem_ctx, BOOL success,
cont(private_data, True, response->data.name.dom_name,
response->data.name.name,
- (enum SID_NAME_USE)response->data.name.type);
+ (enum lsa_SidType)response->data.name.type);
}
void winbindd_lookupsid_async(TALLOC_CTX *mem_ctx, const DOM_SID *sid,
void (*cont)(void *private_data, BOOL success,
const char *dom_name,
const char *name,
- enum SID_NAME_USE type),
+ enum lsa_SidType type),
void *private_data)
{
struct winbindd_domain *domain;
@@ -601,7 +601,7 @@ void winbindd_lookupsid_async(TALLOC_CTX *mem_ctx, const DOM_SID *sid,
enum winbindd_result winbindd_dual_lookupsid(struct winbindd_domain *domain,
struct winbindd_cli_state *state)
{
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
DOM_SID sid;
fstring name;
fstring dom_name;
@@ -638,8 +638,8 @@ static void lookupname_recv(TALLOC_CTX *mem_ctx, BOOL success,
void *c, void *private_data)
{
void (*cont)(void *priv, BOOL succ, const DOM_SID *sid,
- enum SID_NAME_USE type) =
- (void (*)(void *, BOOL, const DOM_SID *, enum SID_NAME_USE))c;
+ enum lsa_SidType type) =
+ (void (*)(void *, BOOL, const DOM_SID *, enum lsa_SidType))c;
DOM_SID sid;
if (!success) {
@@ -662,14 +662,14 @@ static void lookupname_recv(TALLOC_CTX *mem_ctx, BOOL success,
}
cont(private_data, True, &sid,
- (enum SID_NAME_USE)response->data.sid.type);
+ (enum lsa_SidType)response->data.sid.type);
}
void winbindd_lookupname_async(TALLOC_CTX *mem_ctx, const char *dom_name,
const char *name,
void (*cont)(void *private_data, BOOL success,
const DOM_SID *sid,
- enum SID_NAME_USE type),
+ enum lsa_SidType type),
void *private_data)
{
struct winbindd_request request;
@@ -695,7 +695,7 @@ void winbindd_lookupname_async(TALLOC_CTX *mem_ctx, const char *dom_name,
enum winbindd_result winbindd_dual_lookupname(struct winbindd_domain *domain,
struct winbindd_cli_state *state)
{
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
char *name_domain, *name_user;
DOM_SID sid;
char *p;
@@ -812,7 +812,7 @@ enum winbindd_result winbindd_dual_lookuprids(struct winbindd_domain *domain,
DOM_SID domain_sid;
char *domain_name;
char **names;
- enum SID_NAME_USE *types;
+ enum lsa_SidType *types;
NTSTATUS status;
char *result;
@@ -1171,7 +1171,7 @@ struct sid2uid_state {
static void sid2uid_lookup_sid_recv(void *private_data, BOOL success,
const char *dom_name, const char *name,
- enum SID_NAME_USE type);
+ enum lsa_SidType type);
static void sid2uid_noalloc_recv(void *private_data, BOOL success, uid_t uid);
static void sid2uid_alloc_recv(void *private_data, BOOL success, uid_t uid);
static void sid2uid_name2uid_recv(void *private_data, BOOL success, uid_t uid);
@@ -1220,7 +1220,7 @@ void winbindd_sid2uid_async(TALLOC_CTX *mem_ctx, const DOM_SID *sid,
static void sid2uid_lookup_sid_recv(void *private_data, BOOL success,
const char *dom_name, const char *name,
- enum SID_NAME_USE type)
+ enum lsa_SidType type)
{
struct sid2uid_state *state =
talloc_get_type_abort(private_data, struct sid2uid_state);
@@ -1333,7 +1333,7 @@ struct sid2gid_state {
static void sid2gid_lookup_sid_recv(void *private_data, BOOL success,
const char *dom_name, const char *name,
- enum SID_NAME_USE type);
+ enum lsa_SidType type);
static void sid2gid_noalloc_recv(void *private_data, BOOL success, gid_t gid);
static void sid2gid_alloc_recv(void *private_data, BOOL success, gid_t gid);
static void sid2gid_name2gid_recv(void *private_data, BOOL success, gid_t gid);
@@ -1382,7 +1382,7 @@ void winbindd_sid2gid_async(TALLOC_CTX *mem_ctx, const DOM_SID *sid,
static void sid2gid_lookup_sid_recv(void *private_data, BOOL success,
const char *dom_name, const char *name,
- enum SID_NAME_USE type)
+ enum lsa_SidType type)
{
struct sid2gid_state *state =
talloc_get_type_abort(private_data, struct sid2gid_state);
diff --git a/source3/nsswitch/winbindd_cache.c b/source3/nsswitch/winbindd_cache.c
index cb4f405ee0..2cff894eb4 100644
--- a/source3/nsswitch/winbindd_cache.c
+++ b/source3/nsswitch/winbindd_cache.c
@@ -746,7 +746,7 @@ static void centry_end(struct cache_entry *centry, const char *format, ...)
static void wcache_save_name_to_sid(struct winbindd_domain *domain,
NTSTATUS status, const char *domain_name,
const char *name, const DOM_SID *sid,
- enum SID_NAME_USE type)
+ enum lsa_SidType type)
{
struct cache_entry *centry;
fstring uname;
@@ -765,7 +765,7 @@ static void wcache_save_name_to_sid(struct winbindd_domain *domain,
}
static void wcache_save_sid_to_name(struct winbindd_domain *domain, NTSTATUS status,
- const DOM_SID *sid, const char *domain_name, const char *name, enum SID_NAME_USE type)
+ const DOM_SID *sid, const char *domain_name, const char *name, enum lsa_SidType type)
{
struct cache_entry *centry;
fstring sid_string;
@@ -1266,7 +1266,7 @@ static NTSTATUS name_to_sid(struct winbindd_domain *domain,
const char *domain_name,
const char *name,
DOM_SID *sid,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
struct winbind_cache *cache = get_cache(domain);
struct cache_entry *centry = NULL;
@@ -1281,7 +1281,7 @@ static NTSTATUS name_to_sid(struct winbindd_domain *domain,
centry = wcache_fetch(cache, domain, "NS/%s/%s", domain_name, uname);
if (!centry)
goto do_query;
- *type = (enum SID_NAME_USE)centry_uint32(centry);
+ *type = (enum lsa_SidType)centry_uint32(centry);
status = centry->status;
if (NT_STATUS_IS_OK(status)) {
centry_sid(centry, mem_ctx, sid);
@@ -1333,7 +1333,7 @@ static NTSTATUS sid_to_name(struct winbindd_domain *domain,
const DOM_SID *sid,
char **domain_name,
char **name,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
struct winbind_cache *cache = get_cache(domain);
struct cache_entry *centry = NULL;
@@ -1347,7 +1347,7 @@ static NTSTATUS sid_to_name(struct winbindd_domain *domain,
if (!centry)
goto do_query;
if (NT_STATUS_IS_OK(centry->status)) {
- *type = (enum SID_NAME_USE)centry_uint32(centry);
+ *type = (enum lsa_SidType)centry_uint32(centry);
*domain_name = centry_string(centry, mem_ctx);
*name = centry_string(centry, mem_ctx);
}
@@ -1396,7 +1396,7 @@ static NTSTATUS rids_to_names(struct winbindd_domain *domain,
size_t num_rids,
char **domain_name,
char ***names,
- enum SID_NAME_USE **types)
+ enum lsa_SidType **types)
{
struct winbind_cache *cache = get_cache(domain);
size_t i;
@@ -1417,7 +1417,7 @@ static NTSTATUS rids_to_names(struct winbindd_domain *domain,
}
*names = TALLOC_ARRAY(mem_ctx, char *, num_rids);
- *types = TALLOC_ARRAY(mem_ctx, enum SID_NAME_USE, num_rids);
+ *types = TALLOC_ARRAY(mem_ctx, enum lsa_SidType, num_rids);
if ((*names == NULL) || (*types == NULL)) {
result = NT_STATUS_NO_MEMORY;
@@ -1447,7 +1447,7 @@ static NTSTATUS rids_to_names(struct winbindd_domain *domain,
if (NT_STATUS_IS_OK(centry->status)) {
char *dom;
have_mapped = True;
- (*types)[i] = (enum SID_NAME_USE)centry_uint32(centry);
+ (*types)[i] = (enum lsa_SidType)centry_uint32(centry);
dom = centry_string(centry, mem_ctx);
if (*domain_name == NULL) {
*domain_name = dom;
@@ -2208,7 +2208,7 @@ void cache_cleanup_response(pid_t pid)
BOOL lookup_cached_sid(TALLOC_CTX *mem_ctx, const DOM_SID *sid,
const char **domain_name, const char **name,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
struct winbindd_domain *domain;
struct winbind_cache *cache;
@@ -2232,7 +2232,7 @@ BOOL lookup_cached_sid(TALLOC_CTX *mem_ctx, const DOM_SID *sid,
}
if (NT_STATUS_IS_OK(centry->status)) {
- *type = (enum SID_NAME_USE)centry_uint32(centry);
+ *type = (enum lsa_SidType)centry_uint32(centry);
*domain_name = centry_string(centry, mem_ctx);
*name = centry_string(centry, mem_ctx);
}
@@ -2246,7 +2246,7 @@ BOOL lookup_cached_name(TALLOC_CTX *mem_ctx,
const char *domain_name,
const char *name,
DOM_SID *sid,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
struct winbindd_domain *domain;
struct winbind_cache *cache;
@@ -2274,7 +2274,7 @@ BOOL lookup_cached_name(TALLOC_CTX *mem_ctx,
}
if (NT_STATUS_IS_OK(centry->status)) {
- *type = (enum SID_NAME_USE)centry_uint32(centry);
+ *type = (enum lsa_SidType)centry_uint32(centry);
centry_sid(centry, mem_ctx, sid);
}
@@ -2286,7 +2286,7 @@ BOOL lookup_cached_name(TALLOC_CTX *mem_ctx,
void cache_name2sid(struct winbindd_domain *domain,
const char *domain_name, const char *name,
- enum SID_NAME_USE type, const DOM_SID *sid)
+ enum lsa_SidType type, const DOM_SID *sid)
{
wcache_save_name_to_sid(domain, NT_STATUS_OK, domain_name, name,
sid, type);
diff --git a/source3/nsswitch/winbindd_creds.c b/source3/nsswitch/winbindd_creds.c
index 75d21353fd..f11b80909b 100644
--- a/source3/nsswitch/winbindd_creds.c
+++ b/source3/nsswitch/winbindd_creds.c
@@ -80,7 +80,7 @@ NTSTATUS winbindd_store_creds(struct winbindd_domain *domain,
/* do lookup ourself */
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
if (!lookup_cached_name(mem_ctx,
domain->name,
diff --git a/source3/nsswitch/winbindd_group.c b/source3/nsswitch/winbindd_group.c
index 80d103336a..2067c43f8b 100644
--- a/source3/nsswitch/winbindd_group.c
+++ b/source3/nsswitch/winbindd_group.c
@@ -58,7 +58,7 @@ static BOOL fill_grent(struct winbindd_gr *gr, const char *dom_name,
static BOOL fill_grent_mem(struct winbindd_domain *domain,
DOM_SID *group_sid,
- enum SID_NAME_USE group_name_type,
+ enum lsa_SidType group_name_type,
size_t *num_gr_mem, char **gr_mem, size_t *gr_mem_len)
{
DOM_SID *sid_mem = NULL;
@@ -204,7 +204,7 @@ void winbindd_getgrnam(struct winbindd_cli_state *state)
DOM_SID group_sid, tmp_sid;
uint32 grp_rid;
struct winbindd_domain *domain;
- enum SID_NAME_USE name_type;
+ enum lsa_SidType name_type;
fstring name_domain, name_group;
char *tmp, *gr_mem;
size_t gr_mem_len;
@@ -332,7 +332,7 @@ void winbindd_getgrnam(struct winbindd_cli_state *state)
static void getgrgid_got_sid(struct winbindd_cli_state *state, DOM_SID group_sid)
{
struct winbindd_domain *domain;
- enum SID_NAME_USE name_type;
+ enum lsa_SidType name_type;
fstring dom_name;
fstring group_name;
size_t gr_mem_len;
@@ -392,7 +392,7 @@ static void getgrgid_got_sid(struct winbindd_cli_state *state, DOM_SID group_sid
static void getgrgid_recv(void *private_data, BOOL success, const char *sid)
{
struct winbindd_cli_state *state = talloc_get_type_abort(private_data, struct winbindd_cli_state);
- enum SID_NAME_USE name_type;
+ enum lsa_SidType name_type;
DOM_SID group_sid;
if (success) {
@@ -747,7 +747,7 @@ void winbindd_getgrent(struct winbindd_cli_state *state)
if (!NT_STATUS_IS_OK(idmap_sid_to_gid(&group_sid,
&group_gid, 0))) {
union unid_t id;
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
DEBUG(10, ("SID %s not in idmap\n",
sid_string_static(&group_sid)));
@@ -1002,7 +1002,7 @@ struct getgroups_state {
};
static void getgroups_usersid_recv(void *private_data, BOOL success,
- const DOM_SID *sid, enum SID_NAME_USE type);
+ const DOM_SID *sid, enum lsa_SidType type);
static void getgroups_tokensids_recv(void *private_data, BOOL success,
DOM_SID *token_sids, size_t num_token_sids);
static void getgroups_sid2gid_recv(void *private_data, BOOL success, gid_t gid);
@@ -1072,7 +1072,7 @@ void winbindd_getgroups(struct winbindd_cli_state *state)
}
static void getgroups_usersid_recv(void *private_data, BOOL success,
- const DOM_SID *sid, enum SID_NAME_USE type)
+ const DOM_SID *sid, enum lsa_SidType type)
{
struct getgroups_state *s =
(struct getgroups_state *)private_data;
diff --git a/source3/nsswitch/winbindd_pam.c b/source3/nsswitch/winbindd_pam.c
index 6741446a68..f27fc610a6 100644
--- a/source3/nsswitch/winbindd_pam.c
+++ b/source3/nsswitch/winbindd_pam.c
@@ -713,7 +713,7 @@ NTSTATUS winbindd_dual_pam_auth_cached(struct winbindd_domain *domain,
uint16 max_allowed_bad_attempts;
fstring name_domain, name_user;
DOM_SID sid;
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
uchar new_nt_pass[NT_HASH_LEN];
const uint8 *cached_nt_pass;
const uint8 *cached_salt;
diff --git a/source3/nsswitch/winbindd_passdb.c b/source3/nsswitch/winbindd_passdb.c
index d73917ef83..70590579cc 100644
--- a/source3/nsswitch/winbindd_passdb.c
+++ b/source3/nsswitch/winbindd_passdb.c
@@ -52,7 +52,7 @@ static void add_expanded_sid(const DOM_SID *sid, char **pp_members, size_t *p_nu
char *domain_name = NULL;
char *name = NULL;
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
uint32 num_names;
DOM_SID *sid_mem;
@@ -241,7 +241,7 @@ static NTSTATUS name_to_sid(struct winbindd_domain *domain,
const char *domain_name,
const char *name,
DOM_SID *sid,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
DEBUG(10, ("Finding name %s\n", name));
@@ -262,7 +262,7 @@ static NTSTATUS sid_to_name(struct winbindd_domain *domain,
const DOM_SID *sid,
char **domain_name,
char **name,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
const char *dom, *nam;
@@ -293,7 +293,7 @@ static NTSTATUS rids_to_names(struct winbindd_domain *domain,
size_t num_rids,
char **domain_name,
char ***names,
- enum SID_NAME_USE **types)
+ enum lsa_SidType **types)
{
return NT_STATUS_UNSUCCESSFUL;
}
diff --git a/source3/nsswitch/winbindd_reconnect.c b/source3/nsswitch/winbindd_reconnect.c
index 8c5d59f9af..6b484bdd06 100644
--- a/source3/nsswitch/winbindd_reconnect.c
+++ b/source3/nsswitch/winbindd_reconnect.c
@@ -87,7 +87,7 @@ static NTSTATUS name_to_sid(struct winbindd_domain *domain,
const char *domain_name,
const char *name,
DOM_SID *sid,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
NTSTATUS result;
@@ -111,7 +111,7 @@ static NTSTATUS sid_to_name(struct winbindd_domain *domain,
const DOM_SID *sid,
char **domain_name,
char **name,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
NTSTATUS result;
@@ -132,7 +132,7 @@ static NTSTATUS rids_to_names(struct winbindd_domain *domain,
size_t num_rids,
char **domain_name,
char ***names,
- enum SID_NAME_USE **types)
+ enum lsa_SidType **types)
{
NTSTATUS result;
diff --git a/source3/nsswitch/winbindd_rpc.c b/source3/nsswitch/winbindd_rpc.c
index abfaa104fc..dcf9b9b26e 100644
--- a/source3/nsswitch/winbindd_rpc.c
+++ b/source3/nsswitch/winbindd_rpc.c
@@ -241,11 +241,11 @@ NTSTATUS msrpc_name_to_sid(struct winbindd_domain *domain,
const char *domain_name,
const char *name,
DOM_SID *sid,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
NTSTATUS result;
DOM_SID *sids = NULL;
- enum SID_NAME_USE *types = NULL;
+ enum lsa_SidType *types = NULL;
const char *full_name;
struct rpc_pipe_client *cli;
POLICY_HND lsa_policy;
@@ -290,11 +290,11 @@ NTSTATUS msrpc_sid_to_name(struct winbindd_domain *domain,
const DOM_SID *sid,
char **domain_name,
char **name,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
char **domains;
char **names;
- enum SID_NAME_USE *types;
+ enum lsa_SidType *types;
NTSTATUS result;
struct rpc_pipe_client *cli;
POLICY_HND lsa_policy;
@@ -311,7 +311,7 @@ NTSTATUS msrpc_sid_to_name(struct winbindd_domain *domain,
if (!NT_STATUS_IS_OK(result))
return result;
- *type = (enum SID_NAME_USE)types[0];
+ *type = (enum lsa_SidType)types[0];
*domain_name = domains[0];
*name = names[0];
DEBUG(5,("Mapped sid to [%s]\\[%s]\n", domains[0], *name));
@@ -325,7 +325,7 @@ NTSTATUS msrpc_rids_to_names(struct winbindd_domain *domain,
size_t num_rids,
char **domain_name,
char ***names,
- enum SID_NAME_USE **types)
+ enum lsa_SidType **types)
{
char **domains;
NTSTATUS result;
diff --git a/source3/nsswitch/winbindd_sid.c b/source3/nsswitch/winbindd_sid.c
index 194104915a..b572771a25 100644
--- a/source3/nsswitch/winbindd_sid.c
+++ b/source3/nsswitch/winbindd_sid.c
@@ -30,7 +30,7 @@
static void lookupsid_recv(void *private_data, BOOL success,
const char *dom_name, const char *name,
- enum SID_NAME_USE type);
+ enum lsa_SidType type);
void winbindd_lookupsid(struct winbindd_cli_state *state)
{
@@ -53,7 +53,7 @@ void winbindd_lookupsid(struct winbindd_cli_state *state)
static void lookupsid_recv(void *private_data, BOOL success,
const char *dom_name, const char *name,
- enum SID_NAME_USE type)
+ enum lsa_SidType type)
{
struct winbindd_cli_state *state =
talloc_get_type_abort(private_data, struct winbindd_cli_state);
@@ -75,7 +75,7 @@ static void lookupsid_recv(void *private_data, BOOL success,
**/
static void lookupname_recv(void *private_data, BOOL success,
- const DOM_SID *sid, enum SID_NAME_USE type);
+ const DOM_SID *sid, enum lsa_SidType type);
void winbindd_lookupname(struct winbindd_cli_state *state)
{
@@ -107,7 +107,7 @@ void winbindd_lookupname(struct winbindd_cli_state *state)
}
static void lookupname_recv(void *private_data, BOOL success,
- const DOM_SID *sid, enum SID_NAME_USE type)
+ const DOM_SID *sid, enum lsa_SidType type)
{
struct winbindd_cli_state *state =
talloc_get_type_abort(private_data, struct winbindd_cli_state);
@@ -287,14 +287,14 @@ struct uid2sid_state {
uid_t uid;
fstring name;
DOM_SID sid;
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
};
static void uid2sid_uid2name_recv(void *private_data, BOOL success,
const char *username);
static void uid2sid_lookupname_recv(void *private_data, BOOL success,
const DOM_SID *sid,
- enum SID_NAME_USE type);
+ enum lsa_SidType type);
static void uid2sid_idmap_set_mapping_recv(void *private_data, BOOL success);
static void uid2sid_recv(void *private_data, BOOL success, const char *sid);
@@ -394,7 +394,7 @@ static void uid2sid_uid2name_recv(void *private_data, BOOL success,
}
static void uid2sid_lookupname_recv(void *private_data, BOOL success,
- const DOM_SID *sid, enum SID_NAME_USE type)
+ const DOM_SID *sid, enum lsa_SidType type)
{
struct uid2sid_state *state =
talloc_get_type_abort(private_data, struct uid2sid_state);
@@ -432,14 +432,14 @@ struct gid2sid_state {
gid_t gid;
fstring name;
DOM_SID sid;
- enum SID_NAME_USE type;
+ enum lsa_SidType type;
};
static void gid2sid_gid2name_recv(void *private_data, BOOL success,
const char *groupname);
static void gid2sid_lookupname_recv(void *private_data, BOOL success,
const DOM_SID *sid,
- enum SID_NAME_USE type);
+ enum lsa_SidType type);
static void gid2sid_idmap_set_mapping_recv(void *private_data, BOOL success);
static void gid2sid_recv(void *private_data, BOOL success, const char *sid);
@@ -542,7 +542,7 @@ static void gid2sid_gid2name_recv(void *private_data, BOOL success,
}
static void gid2sid_lookupname_recv(void *private_data, BOOL success,
- const DOM_SID *sid, enum SID_NAME_USE type)
+ const DOM_SID *sid, enum lsa_SidType type)
{
struct gid2sid_state *state =
talloc_get_type_abort(private_data, struct gid2sid_state);
diff --git a/source3/nsswitch/winbindd_user.c b/source3/nsswitch/winbindd_user.c
index 98df77c0f2..4cc4eac691 100644
--- a/source3/nsswitch/winbindd_user.c
+++ b/source3/nsswitch/winbindd_user.c
@@ -314,7 +314,7 @@ static void getpwsid_sid2gid_recv(void *private_data, BOOL success, gid_t gid)
/* Return a password structure from a username. */
static void getpwnam_name2sid_recv(void *private_data, BOOL success,
- const DOM_SID *sid, enum SID_NAME_USE type);
+ const DOM_SID *sid, enum lsa_SidType type);
void winbindd_getpwnam(struct winbindd_cli_state *state)
{
@@ -360,7 +360,7 @@ void winbindd_getpwnam(struct winbindd_cli_state *state)
}
static void getpwnam_name2sid_recv(void *private_data, BOOL success,
- const DOM_SID *sid, enum SID_NAME_USE type)
+ const DOM_SID *sid, enum lsa_SidType type)
{
struct winbindd_cli_state *state =
(struct winbindd_cli_state *)private_data;
diff --git a/source3/nsswitch/winbindd_util.c b/source3/nsswitch/winbindd_util.c
index acaca16f0a..cb1a810541 100644
--- a/source3/nsswitch/winbindd_util.c
+++ b/source3/nsswitch/winbindd_util.c
@@ -691,7 +691,7 @@ BOOL winbindd_lookup_sid_by_name(TALLOC_CTX *mem_ctx,
struct winbindd_domain *domain,
const char *domain_name,
const char *name, DOM_SID *sid,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
NTSTATUS result;
@@ -721,7 +721,7 @@ BOOL winbindd_lookup_name_by_sid(TALLOC_CTX *mem_ctx,
DOM_SID *sid,
fstring dom_name,
fstring name,
- enum SID_NAME_USE *type)
+ enum lsa_SidType *type)
{
char *names;
char *dom_names;