]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
winbindd: explicit check for well-known SIDs in wb_lookupsids_bulk()
authorRalph Boehme <slow@samba.org>
Sun, 2 Apr 2017 11:42:45 +0000 (13:42 +0200)
committerKarolin Seeger <kseeger@samba.org>
Thu, 20 Apr 2017 10:23:18 +0000 (12:23 +0200)
Those are implicitly already catched by the

  if (sid->num_auths != 5)

check, but I'd like to make the desired behaviour more obvious.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=12727

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
(cherry picked from commit 167bb5ead8c7193d173fdba8a453279d422fa7ea)

source3/winbindd/wb_lookupsids.c

index 2cf09eb62d12413b99aca50c47dca31401e3b890..979bbc79facc15caa78f234625b49f212c00cad2 100644 (file)
@@ -284,7 +284,10 @@ static bool wb_lookupsids_bulk(const struct dom_sid *sid)
            sid_check_is_in_unix_users(sid) ||
            sid_check_is_unix_users(sid) ||
            sid_check_is_in_builtin(sid) ||
-           sid_check_is_builtin(sid)) {
+           sid_check_is_builtin(sid) ||
+           sid_check_is_wellknown_domain(sid, NULL) ||
+           sid_check_is_in_wellknown_domain(sid))
+       {
                /*
                 * These are locally done piece by piece anyway, no
                 * need for bulk optimizations.