mirror of
https://github.com/samba-team/samba.git
synced 2024-12-24 21:34:56 +03:00
winbindd: avoid automatic enumerating trusts on DCs
We have a static list of trust based on our configuration. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
This commit is contained in:
parent
29e6d55909
commit
40c91150e3
@ -1280,6 +1280,7 @@ bool winbindd_use_cache(void)
|
|||||||
static void winbindd_register_handlers(struct messaging_context *msg_ctx,
|
static void winbindd_register_handlers(struct messaging_context *msg_ctx,
|
||||||
bool foreground)
|
bool foreground)
|
||||||
{
|
{
|
||||||
|
bool scan_trusts = true;
|
||||||
NTSTATUS status;
|
NTSTATUS status;
|
||||||
/* Setup signal handlers */
|
/* Setup signal handlers */
|
||||||
|
|
||||||
@ -1362,7 +1363,15 @@ static void winbindd_register_handlers(struct messaging_context *msg_ctx,
|
|||||||
smb_nscd_flush_user_cache();
|
smb_nscd_flush_user_cache();
|
||||||
smb_nscd_flush_group_cache();
|
smb_nscd_flush_group_cache();
|
||||||
|
|
||||||
if (lp_allow_trusted_domains()) {
|
if (!lp_allow_trusted_domains()) {
|
||||||
|
scan_trusts = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (IS_DC) {
|
||||||
|
scan_trusts = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (scan_trusts) {
|
||||||
if (tevent_add_timer(server_event_context(), NULL, timeval_zero(),
|
if (tevent_add_timer(server_event_context(), NULL, timeval_zero(),
|
||||||
rescan_trusted_domains, NULL) == NULL) {
|
rescan_trusted_domains, NULL) == NULL) {
|
||||||
DEBUG(0, ("Could not trigger rescan_trusted_domains()\n"));
|
DEBUG(0, ("Could not trigger rescan_trusted_domains()\n"));
|
||||||
|
Loading…
Reference in New Issue
Block a user