From: Stefan Metzmacher Date: Fri, 4 Mar 2022 10:41:20 +0000 (+0100) Subject: s3:rpc_client: let rpccli_netlogon_network_logon() fallback to workstation = lp_netbi... X-Git-Tag: tevent-0.12.0~496 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5c04c01354944fc3a64bb109bf3e9bf89086cc6f;p=thirdparty%2Fsamba.git s3:rpc_client: let rpccli_netlogon_network_logon() fallback to workstation = lp_netbios_name() BUG: https://bugzilla.samba.org/show_bug.cgi?id=13879 BUG: https://bugzilla.samba.org/show_bug.cgi?id=14641 Signed-off-by: Stefan Metzmacher Reviewed-by: Andrew Bartlett --- diff --git a/source3/rpc_client/cli_netlogon.c b/source3/rpc_client/cli_netlogon.c index 049186e5a51..50dae9d7f3e 100644 --- a/source3/rpc_client/cli_netlogon.c +++ b/source3/rpc_client/cli_netlogon.c @@ -687,6 +687,10 @@ NTSTATUS rpccli_netlogon_network_logon( return NT_STATUS_NO_MEMORY; } + if (workstation == NULL) { + workstation = lp_netbios_name(); + } + if (workstation[0] != '\\' && workstation[1] != '\\') { workstation_name_slash = talloc_asprintf(mem_ctx, "\\\\%s", workstation); } else {