s3:winbindd: fix endless forest trust scan
authorStefan Metzmacher <metze@samba.org>
Thu, 2 Mar 2017 07:13:57 +0000 (08:13 +0100)
committerKarolin Seeger <kseeger@samba.org>
Mon, 6 Mar 2017 11:26:19 +0000 (12:26 +0100)
commit3f71253ae50d4d51d24956245b254fb8c9fa5f1d
tree8f09ae0c1e4422e2bb835f9dd2ca3be86a3ac7be
parent0915fd4e840311ae45a71f71e14462314a27240a
s3:winbindd: fix endless forest trust scan

Commit 0392ebcd1d48e9f472f2148b85316a77d9cc953b effectively
disabled the enumeration of trusts in other forests.

The fixes for https://bugzilla.samba.org/show_bug.cgi?id=11691
changed the way we fill domain->domain_flags for domains
in other forests.

Commit fffefe72fcc62d9688b45f53a5327667dc0b2fe6 readded the
ability to enumerate trusts of other forests again, in order to
fix https://bugzilla.samba.org/show_bug.cgi?id=11830

Now we have the problem that multiple domains
(even outside of our forest) are considert to be
our forest root, as they have the following flags:
NETR_TRUST_FLAG_TREEROOT and NETR_TRUST_FLAG_IN_FOREST.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12605

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Thu Mar  2 17:53:14 CET 2017 on sn-devel-144

(cherry picked from commit f9aaddcdd8f9ea648c9c5ea804f56ee3ff6c4c67)
source3/winbindd/winbindd_ads.c
source3/winbindd/winbindd_util.c