summaryrefslogtreecommitdiff
path: root/source3/sam/idmap.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/sam/idmap.c')
-rw-r--r--source3/sam/idmap.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/source3/sam/idmap.c b/source3/sam/idmap.c
index d18157643b..91fe97e23a 100644
--- a/source3/sam/idmap.c
+++ b/source3/sam/idmap.c
@@ -153,11 +153,16 @@ BOOL idmap_init(const char **remote_backend)
Don't do id mapping. This is used to make winbind a netlogon proxy only.
**************************************************************************/
-void idmap_proxyonly(void)
+void idmap_set_proxyonly(void)
{
proxyonly = True;
}
+BOOL idmap_proxyonly(void)
+{
+ return proxyonly;
+}
+
/**************************************************************************
This is a rare operation, designed to allow an explicit mapping to be
set up for a sid to a POSIX id.
@@ -223,7 +228,7 @@ NTSTATUS idmap_get_id_from_sid(unid_t *id, int *id_type, const DOM_SID *sid)
return NT_STATUS_OK;
}
- if (remote_map == NULL) {
+ if ((remote_map == NULL) || (loc_type & ID_CACHE_ONLY)) {
return ret;
}
@@ -288,7 +293,7 @@ NTSTATUS idmap_get_sid_from_id(DOM_SID *sid, unid_t id, int id_type)
if (NT_STATUS_IS_OK(ret))
return ret;
- if (remote_map == NULL)
+ if ((remote_map == NULL) || (loc_type & ID_CACHE_ONLY))
return ret;
/* We have a second chance, ask our authoritative backend */