The branch, master has been updated via 536d4d4... s3: Fix an uninitialized variable via a847f13... s3: Use pipe_struct->client_id->name for pjob.clientmachine via 29093bc... s3: Move initializing pjob.clientname to print_job_start() via 4b5e252... s3: Add "client_id" to pipes_struct via 6d10684... s3: Remove unneeded "client_address" from connection_struct via 7b6835e... s3: Add smbd_server_connection->client_id via ac7b633... s3: Lift smbd_server_fd from reload_services() from 59289d4... s3-build: only include smb_signing.h where needed.
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log ----------------------------------------------------------------- commit 536d4d48bfc3e915be210988fa7d9f6433d875f2 Author: Volker Lendecke <v...@samba.org> Date: Wed Aug 18 11:17:52 2010 +0200 s3: Fix an uninitialized variable commit a847f13d7b0c8606471792a50e9c64d1f6bd430c Author: Volker Lendecke <v...@samba.org> Date: Tue Aug 17 09:34:27 2010 +0200 s3: Use pipe_struct->client_id->name for pjob.clientmachine commit 29093bc0009bbcd5f9a98a2f4611fc3eb65f2539 Author: Volker Lendecke <v...@samba.org> Date: Tue Aug 17 09:17:26 2010 +0200 s3: Move initializing pjob.clientname to print_job_start() commit 4b5e252354660501576c8452f48514852f40270e Author: Volker Lendecke <v...@samba.org> Date: Mon Aug 16 11:01:26 2010 +0200 s3: Add "client_id" to pipes_struct commit 6d10684556e9f9e847ec03dd8af057e8d4558e35 Author: Volker Lendecke <v...@samba.org> Date: Mon Aug 16 09:39:29 2010 +0200 s3: Remove unneeded "client_address" from connection_struct commit 7b6835ec1da127713d0a412edcbe0a3c1bcc6192 Author: Volker Lendecke <v...@samba.org> Date: Mon Aug 16 08:30:36 2010 +0200 s3: Add smbd_server_connection->client_id commit ac7b63384d3f8afdb768f95e7744380f4df07d76 Author: Volker Lendecke <v...@samba.org> Date: Sun Aug 15 16:13:00 2010 +0200 s3: Lift smbd_server_fd from reload_services() ----------------------------------------------------------------------- Summary of changes: source3/auth/auth_ntlmssp.c | 2 +- source3/include/ntdomain.h | 2 +- source3/include/printing.h | 1 + source3/include/proto.h | 7 +++++-- source3/include/smb.h | 7 +++++-- source3/lib/util_sock.c | 5 ++--- source3/printing/nt_printing_migrate.c | 1 + source3/printing/printing.c | 11 +++-------- source3/rpc_server/rpc_ncacn_np_internal.c | 15 ++++++++++++--- source3/rpc_server/srv_netlog_nt.c | 5 +++-- source3/rpc_server/srv_pipe_hnd.c | 17 +++-------------- source3/rpc_server/srv_spoolss_nt.c | 15 ++++++++------- source3/rpc_server/srv_spoolss_util.c | 1 + source3/smbd/connection.c | 2 +- source3/smbd/globals.h | 1 + source3/smbd/lanman.c | 14 +++++++++++--- source3/smbd/negprot.c | 4 ++-- source3/smbd/pipes.c | 1 + source3/smbd/process.c | 6 +++--- source3/smbd/reply.c | 2 +- source3/smbd/server.c | 27 ++++++++++++++++++++++++--- source3/smbd/server_reload.c | 11 ++++++----- source3/smbd/service.c | 14 ++------------ source3/smbd/sesssetup.c | 10 +++++----- source3/smbd/smb2_sesssetup.c | 2 +- source3/torture/vfstest.c | 2 +- source3/winbindd/winbindd_samr.c | 2 ++ 27 files changed, 107 insertions(+), 80 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/auth/auth_ntlmssp.c b/source3/auth/auth_ntlmssp.c index a910201..d533ac9 100644 --- a/source3/auth/auth_ntlmssp.c +++ b/source3/auth/auth_ntlmssp.c @@ -122,7 +122,7 @@ static NTSTATUS auth_ntlmssp_check_password(struct ntlmssp_state *ntlmssp_state, /* sub_set_smb_name checks for weird internally */ sub_set_smb_name(auth_ntlmssp_state->ntlmssp_state->user); - reload_services(smbd_messaging_context(), True); + reload_services(smbd_messaging_context(), smbd_server_fd(), True); nt_status = make_user_info_map(&user_info, auth_ntlmssp_state->ntlmssp_state->user, diff --git a/source3/include/ntdomain.h b/source3/include/ntdomain.h index 071e915..073efe5 100644 --- a/source3/include/ntdomain.h +++ b/source3/include/ntdomain.h @@ -131,7 +131,7 @@ struct pipe_auth_data { struct pipes_struct { struct pipes_struct *next, *prev; - char client_address[INET6_ADDRSTRLEN]; + struct client_address *client_id; struct auth_serversupplied_info *server_info; struct messaging_context *msg_ctx; diff --git a/source3/include/printing.h b/source3/include/printing.h index b5fd98d..a16917f 100644 --- a/source3/include/printing.h +++ b/source3/include/printing.h @@ -142,6 +142,7 @@ int print_queue_length(struct messaging_context *msg_ctx, int snum, print_status_struct *pstatus); WERROR print_job_start(struct auth_serversupplied_info *server_info, struct messaging_context *msg_ctx, + const char *clientmachine, int snum, const char *docname, const char *filename, struct spoolss_DeviceMode *devmode, uint32_t *_jobid); void print_job_endpage(struct messaging_context *msg_ctx, diff --git a/source3/include/proto.h b/source3/include/proto.h index fe9dec4..5c664eb 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -4535,12 +4535,13 @@ NTSTATUS rpc_pipe_open_ncalrpc(TALLOC_CTX *mem_ctx, const char *socket_path, struct rpc_pipe_client **presult); struct pipes_struct *make_internal_rpc_pipe_p(TALLOC_CTX *mem_ctx, const struct ndr_syntax_id *syntax, - const char *client_address, + struct client_address *client_id, struct auth_serversupplied_info *server_info, struct messaging_context *msg_ctx); NTSTATUS rpc_pipe_open_internal(TALLOC_CTX *mem_ctx, const struct ndr_syntax_id *abstract_syntax, struct auth_serversupplied_info *serversupplied_info, + struct client_address *client_id, struct messaging_context *msg_ctx, struct rpc_pipe_client **presult); NTSTATUS rpc_connect_spoolss_pipe(connection_struct *conn, @@ -4752,6 +4753,7 @@ struct tsocket_address; NTSTATUS np_open(TALLOC_CTX *mem_ctx, const char *name, const struct tsocket_address *local_address, const struct tsocket_address *remote_address, + struct client_address *client_id, struct auth_serversupplied_info *server_info, struct messaging_context *msg_ctx, struct fake_file_handle **phandle); @@ -5786,7 +5788,8 @@ struct event_context *smbd_event_context(void); struct messaging_context *smbd_messaging_context(void); struct memcache *smbd_memcache(void); void reload_printers(struct messaging_context *msg_ctx); -bool reload_services(struct messaging_context *msg_ctx, bool test); +bool reload_services(struct messaging_context *msg_ctx, int smb_sock, + bool test); void exit_server(const char *const explanation); void exit_server_cleanly(const char *const explanation); void exit_server_fault(void); diff --git a/source3/include/smb.h b/source3/include/smb.h index de104a5..ab1b4b2 100644 --- a/source3/include/smb.h +++ b/source3/include/smb.h @@ -407,6 +407,11 @@ typedef struct files_struct { #include "ntquotas.h" #include "sysquotas.h" +struct client_address { + char addr[INET6_ADDRSTRLEN]; + const char *name; +}; + struct vuid_cache_entry { struct auth_serversupplied_info *server_info; uint16_t vuid; @@ -517,8 +522,6 @@ typedef struct connection_struct { */ gid_t force_group_gid; - char client_address[INET6_ADDRSTRLEN]; /* String version of client IP address. */ - uint16 vuid; /* vuid of user who *opened* this connection, or UID_FIELD_INVALID */ time_t lastused; diff --git a/source3/lib/util_sock.c b/source3/lib/util_sock.c index 3bc60db..e9626f3 100644 --- a/source3/lib/util_sock.c +++ b/source3/lib/util_sock.c @@ -442,7 +442,6 @@ NTSTATUS read_fd_with_timeout(int fd, char *buf, ssize_t readret; size_t nread = 0; struct timeval timeout; - int save_errno; /* just checking .... */ if (maxcnt <= 0) @@ -464,7 +463,7 @@ NTSTATUS read_fd_with_timeout(int fd, char *buf, } if (readret == -1) { - return map_nt_error_from_unix(save_errno); + return map_nt_error_from_unix(errno); } nread += readret; } @@ -489,7 +488,7 @@ NTSTATUS read_fd_with_timeout(int fd, char *buf, /* Check if error */ if (selrtn == -1) { - return map_nt_error_from_unix(save_errno); + return map_nt_error_from_unix(errno); } /* Did we timeout ? */ diff --git a/source3/printing/nt_printing_migrate.c b/source3/printing/nt_printing_migrate.c index 7b37926..362eb90 100644 --- a/source3/printing/nt_printing_migrate.c +++ b/source3/printing/nt_printing_migrate.c @@ -613,6 +613,7 @@ bool nt_printing_tdb_migrate(struct messaging_context *msg_ctx) status = rpc_pipe_open_internal(tmp_ctx, &ndr_table_spoolss.syntax_id, server_info, + NULL, msg_ctx, &spoolss_pipe); if (!NT_STATUS_IS_OK(status)) { diff --git a/source3/printing/printing.c b/source3/printing/printing.c index 82516b3..4240ddf 100644 --- a/source3/printing/printing.c +++ b/source3/printing/printing.c @@ -2685,6 +2685,7 @@ static WERROR print_job_spool_file(int snum, uint32_t jobid, WERROR print_job_start(struct auth_serversupplied_info *server_info, struct messaging_context *msg_ctx, + const char *clientmachine, int snum, const char *docname, const char *filename, struct spoolss_DeviceMode *devmode, uint32_t *_jobid) { @@ -2733,6 +2734,8 @@ WERROR print_job_start(struct auth_serversupplied_info *server_info, fstrcpy(pjob.jobname, docname); + fstrcpy(pjob.clientmachine, clientmachine); + fstrcpy(pjob.user, lp_printjob_username(snum)); standard_sub_advanced(sharename, server_info->sanitized_username, path, server_info->utok.gid, @@ -2811,8 +2814,6 @@ NTSTATUS print_job_end(struct messaging_context *msg_ctx, int snum, SMB_STRUCT_STAT sbuf; struct printif *current_printif = get_printer_fns( snum ); NTSTATUS status = NT_STATUS_UNSUCCESSFUL; - const char *clientname; - char addr[INET6_ADDRSTRLEN]; pjob = print_job_find(sharename, jobid); @@ -2875,12 +2876,6 @@ NTSTATUS print_job_end(struct messaging_context *msg_ctx, int snum, return NT_STATUS_OK; } - clientname = client_name(smbd_server_fd()); - if (strcmp(clientname, "UNKNOWN") == 0) { - clientname = client_addr(smbd_server_fd(),addr,sizeof(addr)); - } - fstrcpy(pjob->clientmachine, clientname); - ret = (*(current_printif->job_submit))(snum, pjob); if (ret) { diff --git a/source3/rpc_server/rpc_ncacn_np_internal.c b/source3/rpc_server/rpc_ncacn_np_internal.c index 71a14be..bbb6338 100644 --- a/source3/rpc_server/rpc_ncacn_np_internal.c +++ b/source3/rpc_server/rpc_ncacn_np_internal.c @@ -114,7 +114,7 @@ static int close_internal_rpc_pipe_hnd(struct pipes_struct *p) struct pipes_struct *make_internal_rpc_pipe_p(TALLOC_CTX *mem_ctx, const struct ndr_syntax_id *syntax, - const char *client_address, + struct client_address *client_id, struct auth_serversupplied_info *server_info, struct messaging_context *msg_ctx) { @@ -157,7 +157,7 @@ struct pipes_struct *make_internal_rpc_pipe_p(TALLOC_CTX *mem_ctx, DLIST_ADD(InternalPipes, p); - strlcpy(p->client_address, client_address, sizeof(p->client_address)); + p->client_id = client_id; p->endian = RPC_LITTLE_ENDIAN; @@ -469,6 +469,7 @@ static struct dcerpc_binding_handle *rpcint_binding_handle(struct pipes_struct * NTSTATUS rpc_pipe_open_internal(TALLOC_CTX *mem_ctx, const struct ndr_syntax_id *abstract_syntax, struct auth_serversupplied_info *serversupplied_info, + struct client_address *client_id, struct messaging_context *msg_ctx, struct rpc_pipe_client **presult) { @@ -482,8 +483,16 @@ NTSTATUS rpc_pipe_open_internal(TALLOC_CTX *mem_ctx, result->abstract_syntax = *abstract_syntax; result->transfer_syntax = ndr_transfer_syntax; + if (client_id == NULL) { + static struct client_address unknown; + strlcpy(unknown.addr, "<UNKNOWN>", sizeof(unknown.addr)); + unknown.name = "<UNKNOWN>"; + client_id = &unknown; + } + result->pipes_struct = make_internal_rpc_pipe_p( - result, abstract_syntax, "", serversupplied_info, msg_ctx); + result, abstract_syntax, client_id, serversupplied_info, + msg_ctx); if (result->pipes_struct == NULL) { TALLOC_FREE(result); return NT_STATUS_NO_MEMORY; diff --git a/source3/rpc_server/srv_netlog_nt.c b/source3/rpc_server/srv_netlog_nt.c index 4433a70..1b0544f 100644 --- a/source3/rpc_server/srv_netlog_nt.c +++ b/source3/rpc_server/srv_netlog_nt.c @@ -406,6 +406,7 @@ NTSTATUS _netr_NetrEnumerateTrustedDomains(struct pipes_struct *p, status = rpc_pipe_open_internal(p->mem_ctx, &ndr_table_lsarpc.syntax_id, p->server_info, + p->client_id, p->msg_ctx, &cli); if (!NT_STATUS_IS_OK(status)) { @@ -631,7 +632,7 @@ static NTSTATUS get_md4pw(struct samr_Password *md4pw, const char *mach_acct, ZERO_STRUCT(user_handle); status = rpc_pipe_open_internal(mem_ctx, &ndr_table_samr.syntax_id, - server_info, msg_ctx, + server_info, NULL, msg_ctx, &cli); if (!NT_STATUS_IS_OK(status)) { goto out; @@ -1035,7 +1036,7 @@ static NTSTATUS netr_set_machine_account_password(TALLOC_CTX *mem_ctx, ZERO_STRUCT(user_handle); status = rpc_pipe_open_internal(mem_ctx, &ndr_table_samr.syntax_id, - server_info, msg_ctx, + server_info, NULL, msg_ctx, &cli); if (!NT_STATUS_IS_OK(status)) { goto out; diff --git a/source3/rpc_server/srv_pipe_hnd.c b/source3/rpc_server/srv_pipe_hnd.c index 37efe06..4c6e651 100644 --- a/source3/rpc_server/srv_pipe_hnd.c +++ b/source3/rpc_server/srv_pipe_hnd.c @@ -537,6 +537,7 @@ static struct np_proxy_state *make_external_rpc_pipe_p(TALLOC_CTX *mem_ctx, NTSTATUS np_open(TALLOC_CTX *mem_ctx, const char *name, const struct tsocket_address *local_address, const struct tsocket_address *remote_address, + struct client_address *client_id, struct auth_serversupplied_info *server_info, struct messaging_context *msg_ctx, struct fake_file_handle **phandle) @@ -564,26 +565,13 @@ NTSTATUS np_open(TALLOC_CTX *mem_ctx, const char *name, } else { struct pipes_struct *p; struct ndr_syntax_id syntax; - const char *client_address; if (!is_known_pipename(name, &syntax)) { TALLOC_FREE(handle); return NT_STATUS_OBJECT_NAME_NOT_FOUND; } - if (tsocket_address_is_inet(remote_address, "ip")) { - client_address = tsocket_address_inet_addr_string( - remote_address, - talloc_tos()); - if (client_address == NULL) { - TALLOC_FREE(handle); - return NT_STATUS_NO_MEMORY; - } - } else { - client_address = ""; - } - - p = make_internal_rpc_pipe_p(handle, &syntax, client_address, + p = make_internal_rpc_pipe_p(handle, &syntax, client_id, server_info, msg_ctx); handle->type = FAKE_FILE_TYPE_NAMED_PIPE; @@ -930,6 +918,7 @@ NTSTATUS rpc_connect_spoolss_pipe(connection_struct *conn, status = rpc_pipe_open_internal(conn, &ndr_table_spoolss.syntax_id, conn->server_info, + &conn->sconn->client_id, conn->sconn->msg_ctx, &conn->spoolss_pipe); if (!NT_STATUS_IS_OK(status)) { diff --git a/source3/rpc_server/srv_spoolss_nt.c b/source3/rpc_server/srv_spoolss_nt.c index 893ddce..46e47f5 100644 --- a/source3/rpc_server/srv_spoolss_nt.c +++ b/source3/rpc_server/srv_spoolss_nt.c @@ -341,7 +341,7 @@ static WERROR delete_printer_hook(TALLOC_CTX *ctx, NT_USER_TOKEN *token, /* go ahead and re-read the services immediately */ become_root(); - reload_services(msg_ctx, false); + reload_services(msg_ctx, smbd_server_fd(), false); unbecome_root(); if ( lp_servicenumber( sharename ) > 0 ) @@ -2451,9 +2451,9 @@ WERROR _spoolss_RemoteFindFirstPrinterChangeNotifyEx(struct pipes_struct *p, return WERR_BADFID; DEBUG(10,("_spoolss_RemoteFindFirstPrinterChangeNotifyEx: " - "client_address is %s\n", p->client_address)); + "client_address is %s\n", p->client_id->addr)); - if (!interpret_string_addr(&client_ss, p->client_address, + if (!interpret_string_addr(&client_ss, p->client_id->addr, AI_NUMERICHOST)) { return WERR_SERVER_UNAVAILABLE; } @@ -5291,7 +5291,8 @@ WERROR _spoolss_StartDocPrinter(struct pipes_struct *p, return WERR_BADFID; } - werr = print_job_start(p->server_info, p->msg_ctx, snum, + werr = print_job_start(p->server_info, p->msg_ctx, + p->client_id->name, snum, info_1->document_name, info_1->output_file, Printer->devmode, &Printer->jobid); @@ -5724,7 +5725,7 @@ static bool add_printer_hook(TALLOC_CTX *ctx, NT_USER_TOKEN *token, /* reload our services immediately */ become_root(); - reload_services(msg_ctx, false); + reload_services(msg_ctx, smbd_server_fd(), false); unbecome_root(); numlines = 0; @@ -6111,7 +6112,7 @@ static WERROR update_printer(struct pipes_struct *p, { /* add_printer_hook() will call reload_services() */ if (!add_printer_hook(tmp_ctx, p->server_info->ptok, - printer, p->client_address, + printer, p->client_id->addr, p->msg_ctx)) { result = WERR_ACCESS_DENIED; goto done; @@ -7420,7 +7421,7 @@ static WERROR spoolss_addprinterex_level_2(struct pipes_struct *p, if (*lp_addprinter_cmd() ) { if ( !add_printer_hook(p->mem_ctx, p->server_info->ptok, - info2, p->client_address, + info2, p->client_id->addr, p->msg_ctx) ) { return WERR_ACCESS_DENIED; } diff --git a/source3/rpc_server/srv_spoolss_util.c b/source3/rpc_server/srv_spoolss_util.c index 2de45b7..5fbdc0b 100644 --- a/source3/rpc_server/srv_spoolss_util.c +++ b/source3/rpc_server/srv_spoolss_util.c @@ -262,6 +262,7 @@ static WERROR winreg_printer_openkey(TALLOC_CTX *mem_ctx, status = rpc_pipe_open_internal(mem_ctx, &ndr_table_winreg.syntax_id, server_info, + NULL, msg_ctx, &pipe_handle); if (!NT_STATUS_IS_OK(status)) { diff --git a/source3/smbd/connection.c b/source3/smbd/connection.c index f4f4fc2..9b766d5 100644 --- a/source3/smbd/connection.c +++ b/source3/smbd/connection.c @@ -147,7 +147,7 @@ bool claim_connection(connection_struct *conn, const char *name) crec.start = time(NULL); strlcpy(crec.machine,get_remote_machine_name(),sizeof(crec.machine)); - strlcpy(crec.addr, conn->client_address, sizeof(crec.addr)); + strlcpy(crec.addr, conn->sconn->client_id.addr, sizeof(crec.addr)); dbuf.dptr = (uint8 *)&crec; dbuf.dsize = sizeof(crec); diff --git a/source3/smbd/globals.h b/source3/smbd/globals.h index cf23509..e4f4b79 100644 --- a/source3/smbd/globals.h +++ b/source3/smbd/globals.h @@ -458,6 +458,7 @@ struct pending_auth_data; struct smbd_server_connection { int sock; + struct client_address client_id; const struct tsocket_address *local_address; const struct tsocket_address *remote_address; struct messaging_context *msg_ctx; diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c index 2be2a8c..493a8ec 100644 --- a/source3/smbd/lanman.c +++ b/source3/smbd/lanman.c @@ -2236,6 +2236,7 @@ static bool api_RNetShareAdd(struct smbd_server_connection *sconn, status = rpc_pipe_open_internal(mem_ctx, &ndr_table_srvsvc.syntax_id, conn->server_info, + &conn->sconn->client_id, conn->sconn->msg_ctx, &cli); if (!NT_STATUS_IS_OK(status)) { @@ -2343,7 +2344,8 @@ static bool api_RNetGroupEnum(struct smbd_server_connection *sconn, status = rpc_pipe_open_internal( talloc_tos(), &ndr_table_samr.syntax_id, - conn->server_info, conn->sconn->msg_ctx, &samr_pipe); + conn->server_info, &conn->sconn->client_id, + conn->sconn->msg_ctx, &samr_pipe); if (!NT_STATUS_IS_OK(status)) { DEBUG(0, ("api_RNetUserEnum: Could not connect to samr: %s\n", nt_errstr(status))); @@ -2525,7 +2527,8 @@ static bool api_NetUserGetGroups(struct smbd_server_connection *sconn, status = rpc_pipe_open_internal( talloc_tos(), &ndr_table_samr.syntax_id, - conn->server_info, conn->sconn->msg_ctx, &samr_pipe); + conn->server_info, &conn->sconn->client_id, + conn->sconn->msg_ctx, &samr_pipe); if (!NT_STATUS_IS_OK(status)) { DEBUG(0, ("api_RNetUserEnum: Could not connect to samr: %s\n", nt_errstr(status))); @@ -2681,7 +2684,8 @@ static bool api_RNetUserEnum(struct smbd_server_connection *sconn, status = rpc_pipe_open_internal( talloc_tos(), &ndr_table_samr.syntax_id, - conn->server_info, conn->sconn->msg_ctx, &samr_pipe); + conn->server_info, &conn->sconn->client_id, + conn->sconn->msg_ctx, &samr_pipe); if (!NT_STATUS_IS_OK(status)) { DEBUG(0, ("api_RNetUserEnum: Could not connect to samr: %s\n", nt_errstr(status))); @@ -2924,6 +2928,7 @@ static bool api_SetUserPassword(struct smbd_server_connection *sconn, status = rpc_pipe_open_internal(mem_ctx, &ndr_table_samr.syntax_id, conn->server_info, + &conn->sconn->client_id, conn->sconn->msg_ctx, &cli); if (!NT_STATUS_IS_OK(status)) { @@ -3141,6 +3146,7 @@ static bool api_SamOEMChangePassword(struct smbd_server_connection *sconn, status = rpc_pipe_open_internal(mem_ctx, &ndr_table_samr.syntax_id, conn->server_info, + &conn->sconn->client_id, conn->sconn->msg_ctx, &cli); if (!NT_STATUS_IS_OK(status)) { @@ -3695,6 +3701,7 @@ static bool api_RNetServerGetInfo(struct smbd_server_connection *sconn, status = rpc_pipe_open_internal(mem_ctx, &ndr_table_srvsvc.syntax_id, conn->server_info, + &conn->sconn->client_id, conn->sconn->msg_ctx, &cli); if (!NT_STATUS_IS_OK(status)) { @@ -4118,6 +4125,7 @@ static bool api_RNetUserGetInfo(struct smbd_server_connection *sconn, status = rpc_pipe_open_internal(mem_ctx, &ndr_table_samr.syntax_id, conn->server_info, + &conn->sconn->client_id, conn->sconn->msg_ctx, &cli); if (!NT_STATUS_IS_OK(status)) { diff --git a/source3/smbd/negprot.c b/source3/smbd/negprot.c index 9151d1b..2908c26 100644 --- a/source3/smbd/negprot.c +++ b/source3/smbd/negprot.c @@ -667,7 +667,7 @@ void reply_negprot(struct smb_request *req) } /* possibly reload - change of architecture */ - reload_services(sconn->msg_ctx, True); + reload_services(sconn->msg_ctx, sconn->sock, True); /* moved from the netbios session setup code since we don't have that when the client connects to port 445. Of course there is a small @@ -693,7 +693,7 @@ void reply_negprot(struct smb_request *req) if(choice != -1) { -- Samba Shared Repository