From: Volker Lendecke Date: Tue, 29 Oct 2024 07:59:29 +0000 (+0100) Subject: libnet4: Call map_netlogon_samlogon_response directly X-Git-Tag: tdb-1.4.13~609 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d41efadde3c79e43ac7a95abdb530adeb05c9d8e;p=thirdparty%2Fsamba.git libnet4: Call map_netlogon_samlogon_response directly Avoid using a boolean flag passed down Signed-off-by: Volker Lendecke Reviewed-by: Stefan Metzmacher --- diff --git a/source4/libnet/libnet_site.c b/source4/libnet/libnet_site.c index 691e4b243ac..a3e3d5970dc 100644 --- a/source4/libnet/libnet_site.c +++ b/source4/libnet/libnet_site.c @@ -56,7 +56,6 @@ NTSTATUS libnet_FindSite(TALLOC_CTX *ctx, struct libnet_context *lctx, struct li search.in.dest_port = 0; search.in.acct_control = -1; search.in.version = NETLOGON_NT_VERSION_5 | NETLOGON_NT_VERSION_5EX; - search.in.map_response = true; ret = tsocket_address_inet_from_strings(tmp_ctx, "ip", r->in.dest_address, @@ -77,6 +76,9 @@ NTSTATUS libnet_FindSite(TALLOC_CTX *ctx, struct libnet_context *lctx, struct li return status; } status = cldap_netlogon(cldap, tmp_ctx, &search); + if (NT_STATUS_IS_OK(status)) { + map_netlogon_samlogon_response(&search.out.netlogon); + } if (!NT_STATUS_IS_OK(status) || search.out.netlogon.data.nt5_ex.client_site == NULL || search.out.netlogon.data.nt5_ex.client_site[0] == '\0') {