summaryrefslogtreecommitdiffstats
path: root/source/rpc_server
diff options
context:
space:
mode:
authorJim McDonough <jmcd@samba.org>2004-04-06 22:02:47 +0000
committerJim McDonough <jmcd@samba.org>2004-04-06 22:02:47 +0000
commit36295bfb1f99edb558119ce33d06b1b5c4175a1a (patch)
treece450862933044d85cc5a86759147d2aed940598 /source/rpc_server
parent0a588b992c900342a3d42a1f8f86bdf3bd871626 (diff)
downloadsamba-36295bfb1f99edb558119ce33d06b1b5c4175a1a.tar.gz
samba-36295bfb1f99edb558119ce33d06b1b5c4175a1a.tar.xz
samba-36295bfb1f99edb558119ce33d06b1b5c4175a1a.zip
r91: Fix lsalookupnames. Previously we'd fail if we didn't find the name, but
we never checked if it was a domain user and didn't find a local one.
Diffstat (limited to 'source/rpc_server')
-rw-r--r--source/rpc_server/srv_lsa_nt.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/rpc_server/srv_lsa_nt.c b/source/rpc_server/srv_lsa_nt.c
index 07c024e1ca9..9801ce47f8f 100644
--- a/source/rpc_server/srv_lsa_nt.c
+++ b/source/rpc_server/srv_lsa_nt.c
@@ -165,6 +165,12 @@ static void init_lsa_rid2s(DOM_R_REF *ref, DOM_RID2 *rid2,
status = lookup_name(dom_name, user, &sid, &name_type);
+ if((name_type == SID_NAME_UNKNOWN) && (lp_server_role() == ROLE_DOMAIN_MEMBER) && (strncmp(dom_name, full_name, strlen(dom_name)) != 0)) {
+ DEBUG(5, ("init_lsa_rid2s: domain name not provided and local account not found, using member domain\n"));
+ fstrcpy(dom_name, lp_workgroup());
+ status = lookup_name(dom_name, user, &sid, &name_type);
+ }
+
DEBUG(5, ("init_lsa_rid2s: %s\n", status ? "found" :
"not found"));