summaryrefslogtreecommitdiffstats
path: root/source4/winbind/wb_sid2domain.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2013-06-15 23:01:44 +1000
committerAndrew Bartlett <abartlet@samba.org>2013-06-20 15:30:00 +0200
commit88c72fceb1c86752c52651bdea5b116806dd92c5 (patch)
tree13524805d4e49fdf52d5f7bc6852b3f2898647ff /source4/winbind/wb_sid2domain.c
parentd4091c5809f174b68714fa50fa501c99617c016e (diff)
downloadsamba-88c72fceb1c86752c52651bdea5b116806dd92c5.tar.gz
samba-88c72fceb1c86752c52651bdea5b116806dd92c5.tar.xz
samba-88c72fceb1c86752c52651bdea5b116806dd92c5.zip
s4-winbind: Add special case for BUILTIN domain
This should mean that lookups for the BUILTIN domain cause less trouble then they have in the past, because they will no longer go via the trusted domain handler. Andrew Bartlett Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Thu Jun 20 15:30:00 CEST 2013 on sn-devel-104
Diffstat (limited to 'source4/winbind/wb_sid2domain.c')
-rw-r--r--source4/winbind/wb_sid2domain.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/source4/winbind/wb_sid2domain.c b/source4/winbind/wb_sid2domain.c
index 637fe1d8afc..172a6d0a09a 100644
--- a/source4/winbind/wb_sid2domain.c
+++ b/source4/winbind/wb_sid2domain.c
@@ -98,6 +98,20 @@ static struct tevent_req *_wb_sid2domain_send(TALLOC_CTX *mem_ctx,
return req;
}
+ if (dom_sid_equal(&global_sid_Builtin, sid) ||
+ dom_sid_in_domain(&global_sid_Builtin, sid)) {
+ ctx = wb_get_dom_info_send(state, service,
+ "BUILTIN", NULL,
+ &global_sid_Builtin);
+ if (tevent_req_nomem(ctx, req)) {
+ return tevent_req_post(req, ev);
+ }
+ ctx->async.fn = wb_sid2domain_recv_dom_info;
+ ctx->async.private_data = req;
+
+ return req;
+ }
+
ctx = wb_cmd_lookupsid_send(state, service, &state->sid);
if (tevent_req_nomem(ctx, req)) {
return tevent_req_post(req, ev);