summaryrefslogtreecommitdiff
path: root/source3/rpc_server/srv_lsa_nt.c
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2009-04-16 01:42:35 +0200
committerGünther Deschner <gd@samba.org>2009-04-16 01:52:56 +0200
commit14304fc5e5d1334328d0f181cbdd4d3a644af62b (patch)
tree3074007f6db3c46ad32516b55ad74265ac9c37b2 /source3/rpc_server/srv_lsa_nt.c
parentd9804ae3cc2c435f9983ca47f6f1b6b96e5c03ca (diff)
downloadsamba-14304fc5e5d1334328d0f181cbdd4d3a644af62b.tar.gz
samba-14304fc5e5d1334328d0f181cbdd4d3a644af62b.tar.bz2
samba-14304fc5e5d1334328d0f181cbdd4d3a644af62b.zip
s3-lsa: Fix Bug #6263. Unexpected LookupSids reply crashes XP pre-SP3.
LookupSids needs to bounce back string sids in case of NT_STATUS_NONE_MAPPED. Guenther (cherry picked from commit 1c9266c8caa59e287b993393b6050732a0b33547)
Diffstat (limited to 'source3/rpc_server/srv_lsa_nt.c')
-rw-r--r--source3/rpc_server/srv_lsa_nt.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/source3/rpc_server/srv_lsa_nt.c b/source3/rpc_server/srv_lsa_nt.c
index 0ce2b40f65..9481c206f6 100644
--- a/source3/rpc_server/srv_lsa_nt.c
+++ b/source3/rpc_server/srv_lsa_nt.c
@@ -827,7 +827,15 @@ NTSTATUS _lsa_LookupSids(pipes_struct *p,
&names,
&mapped_count);
- if (NT_STATUS_IS_ERR(status)) {
+ /* Only return here when there is a real error.
+ NT_STATUS_NONE_MAPPED is a special case as it indicates that none of
+ the requested sids could be resolved. Older versions of XP (pre SP3)
+ rely that we return with the string representations of those SIDs in
+ that case. If we don't, XP crashes - Guenther
+ */
+
+ if (NT_STATUS_IS_ERR(status) &&
+ !NT_STATUS_EQUAL(status, NT_STATUS_NONE_MAPPED)) {
return status;
}