[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via e742661bd25 tstream: Add tstream_npa_existing_stream() via 1b47dd65a38 tstream_npa: Allow NULL output parameters via bbfdf2708e8 tstream_npa: Return named_pipe_auth_req_info4 from accept_existing via 3a03c0a1ad7 tstream_npa: Keep "named_pipe_auth_req" around in tstream_npa_accept_existing_send()/recv() via 0736a9f5c39 wbinfo: Allow SID for -R via 4e174b5a0f4 dynconfig: Introduce and expose SAMBA_LIBEXECDIR via 206c99f6e5e srv_winreg: Align integer types via 6a6676488ea printing: Align integer types via 23056f537c6 smbd: Factor out a bool expr into a descriptive variable via 6f4e6fc631a test: Add a test for background_job_send crash via cabd67d69f7 lib: Fix rundown of jobs sent with background_job_send() via 74720bd9acd lib: Add required includes to source3/lib/background.h from 97e657b89b6 asn1: Remove unused function asn1_check_enumerated() https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit e742661bd2507d39dfa47e40531dc1dca636cbbe Author: Volker Lendecke Date: Tue Feb 16 17:22:40 2021 +0100 tstream: Add tstream_npa_existing_stream() Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison Autobuild-User(master): Jeremy Allison Autobuild-Date(master): Thu Apr 1 20:36:19 UTC 2021 on sn-devel-184 commit 1b47dd65a3815e38537af335792353fca6c40f03 Author: Volker Lendecke Date: Mon Jan 18 21:28:30 2021 +0100 tstream_npa: Allow NULL output parameters When reading the info4, the substructs might not be interesting for you. Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit bbfdf2708e8e85cee56aeff43c9216d2003ed310 Author: Volker Lendecke Date: Mon Jan 18 17:30:42 2021 +0100 tstream_npa: Return named_pipe_auth_req_info4 from accept_existing Callers might want the full picture. We need to make named_pipe_auth_req_info4 public for that. Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit 3a03c0a1ad7ea81d9dcae88016c42a1f9e000b47 Author: Volker Lendecke Date: Mon Jan 18 16:54:07 2021 +0100 tstream_npa: Keep "named_pipe_auth_req" around in tstream_npa_accept_existing_send()/recv() This will make it simpler to return a copy of the struct named_pipe_auth_req_info4 in the next commit. Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit 0736a9f5c39b93e06a9172a74b766eb9a029f1f0 Author: Volker Lendecke Date: Tue Feb 23 16:04:02 2021 +0100 wbinfo: Allow SID for -R Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit 4e174b5a0f42b042f363640d6b02ef6ba4e9883a Author: Volker Lendecke Date: Tue Feb 2 16:50:48 2021 +0100 dynconfig: Introduce and expose SAMBA_LIBEXECDIR Right now the smbspool_krb5_wrapper lives there, but we'll have more in the future. Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit 206c99f6e5e0720eff4e3240d61a51ba151204f7 Author: Volker Lendecke Date: Sat Mar 27 16:42:29 2021 +0100 srv_winreg: Align integer types Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit 6a6676488ea4849b8ed1e6d851fa3363b6a72d6d Author: Volker Lendecke Date: Sat Mar 27 16:42:52 2021 +0100 printing: Align integer types Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit 23056f537c6c12e656fbccac86643088db7f14da Author: Volker Lendecke Date: Fri Mar 26 18:50:00 2021 +0100 smbd: Factor out a bool expr into a descriptive variable Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit 6f4e6fc631a4f43d22fe65cd53daf635b4324d53 Author: Volker Lendecke Date: Wed Mar 31 11:22:16 2021 + test: Add a test for background_job_send crash I haven't figured out how to properly add a crashing test to "knownfail", so this is added after the fix. Signed-off-by: Volker Lendecke commit cabd67d69f7fa24a132b6e7850b9678aac269ec5 Author: Volker Lendecke Date: Tue Mar 30 17:18:10 2021 +0200 lib: Fix rundown of jobs sent with background_job_send() When using this with a trigger message in smbd it will crash at rundown in messaging_deregister because the global messaging context can be TALLOC_FREE'ed before the background job is freed. Using messaging_filtered_send already takes care of this situation properly. Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison commit 74720bd9acd4951dd03f562748cae4dbe26092a0 Author: Volker Lendecke Date: Wed Mar 31 11:21:52 2021 + lib: Add required includes to source3/lib/background.h Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 97e657b89b6 asn1: Remove unused function asn1_check_enumerated() from 1b183f57512 selftest: Allow to set the 'log level' for clients https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 97e657b89b63f1df1e3280ffc563876c27439f44 Author: Joseph Sutton Date: Fri Mar 19 12:47:57 2021 +1300 asn1: Remove unused function asn1_check_enumerated() This function was reported as containing a bug, but it is unused and so can be safely removed. BUG: https://bugzilla.samba.org/show_bug.cgi?id=4153 Signed-off-by: Joseph Sutton Reviewed-by: Jeremy Allison Reviewed-by: David Mulder Autobuild-User(master): Jeremy Allison Autobuild-Date(master): Thu Apr 1 17:50:49 UTC 2021 on sn-devel-184 --- Summary of changes: lib/util/asn1.c | 14 -- lib/util/asn1.h | 1 - 2 files changed, 15 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/util/asn1.c b/lib/util/asn1.c index 9ab9e1b0844..1a92a55c247 100644 --- a/lib/util/asn1.c +++ b/lib/util/asn1.c @@ -1085,20 +1085,6 @@ bool asn1_read_enumerated(struct asn1_data *data, int *v) return asn1_end_tag(data); } -/* check a enumerated value is correct */ -bool asn1_check_enumerated(struct asn1_data *data, int v) -{ - uint8_t b; - if (!asn1_start_tag(data, ASN1_ENUMERATED)) return false; - if (!asn1_read_uint8(data, )) return false; - if (!asn1_end_tag(data)) return false; - - if (v != b) - data->has_error = false; - - return !data->has_error; -} - /* write an enumerated value to the stream */ bool asn1_write_enumerated(struct asn1_data *data, uint8_t v) { diff --git a/lib/util/asn1.h b/lib/util/asn1.h index de92a767f14..9043c34f46e 100644 --- a/lib/util/asn1.h +++ b/lib/util/asn1.h @@ -99,7 +99,6 @@ bool asn1_read_implicit_Integer(struct asn1_data *data, int *i); bool asn1_read_Integer(struct asn1_data *data, int *i); bool asn1_read_BitString(struct asn1_data *data, TALLOC_CTX *mem_ctx, DATA_BLOB *blob, uint8_t *padding); bool asn1_read_enumerated(struct asn1_data *data, int *v); -bool asn1_check_enumerated(struct asn1_data *data, int v); bool asn1_write_enumerated(struct asn1_data *data, uint8_t v); bool asn1_blob(const struct asn1_data *asn1, DATA_BLOB *blob); bool asn1_extract_blob(struct asn1_data *asn1, TALLOC_CTX *mem_ctx, -- Samba Shared Repository
[SCM] Samba Shared Repository - branch v4-13-test updated
The branch, v4-13-test has been updated via 7436dde6ef6 s3: smbd: fix deferred renames via a85f7995740 s4: torture. Add smb2.lease.rename_wait test to reproduce regression in delay rename for lease break code. via 3644afc38c7 rpc_server3: Fix a memleak for internal pipes via 85b5657cbd6 spools: avoid leaking memory into the callers mem_ctx via 890cc945e33 pidl: set the per-request memory context in the pidl generator from 42e7b36454d smbd: free open_rec state in remove_deferred_open_message_smb2_internal() https://git.samba.org/?p=samba.git;a=shortlog;h=v4-13-test - Log - commit 7436dde6ef68826174b9f74a014e2a2040cb14a2 Author: Ralph Boehme Date: Mon Mar 29 12:24:39 2021 +0200 s3: smbd: fix deferred renames This was broken by c7a9e0e4cdfb22e66533b5c8e20af3cfdb8ae78c. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14679 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1875 Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison Autobuild-User(master): Ralph Böhme Autobuild-Date(master): Wed Mar 31 06:13:39 UTC 2021 on sn-devel-184 (cherry picked from commit 10d753868e810604d8f60673bbd48f55aaff0797) Autobuild-User(v4-13-test): Karolin Seeger Autobuild-Date(v4-13-test): Thu Apr 1 12:19:23 UTC 2021 on sn-devel-184 commit a85f79957407b0369166c63e30537b5170ba0ea7 Author: Jeremy Allison Date: Tue Mar 30 15:05:47 2021 -0700 s4: torture. Add smb2.lease.rename_wait test to reproduce regression in delay rename for lease break code. Passes against Windows 10. Add to knownfail, the next commit will fix this. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14679 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1875 Back-ported from 8d9a0b8d57713781c72440c7e91746b5d89e6f6a. Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme commit 3644afc38c726a19f39f1d4f96badfb7827fb1a4 Author: Volker Lendecke Date: Tue Mar 23 17:06:15 2021 +0100 rpc_server3: Fix a memleak for internal pipes state->call should not be talloc'ed off a long-lived context BUG: https://bugzilla.samba.org/show_bug.cgi?id=14675 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1861 RN: Memory leak in the RPC server Signed-off-by: Volker Lendecke Reviewed-by: Samuel Cabrero Reviewed-by: Ralph Boehme Autobuild-User(master): Ralph Böhme Autobuild-Date(master): Wed Mar 31 12:14:01 UTC 2021 on sn-devel-184 (cherry picked from commit 12f516e4680753460e7fe8811e6c6ff70057580c) commit 85b5657cbd685968045fcaad2e7d3323b902edc9 Author: Ralph Boehme Date: Mon Mar 22 12:06:39 2021 +0100 spools: avoid leaking memory into the callers mem_ctx BUG: https://bugzilla.samba.org/show_bug.cgi?id=14675 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1861 Signed-off-by: Ralph Boehme Reviewed-by: Volker Lendecke (cherry picked from commit 481176ec745c14b78fca68e01a61c83405a4b97b) commit 890cc945e338bbe3047bee45772330ec32feb5a2 Author: Ralph Boehme Date: Tue Mar 23 11:40:21 2021 +0100 pidl: set the per-request memory context in the pidl generator The talloc memory context referenced by the pipe_struct mem_ctx member is used as talloc parent for RPC response data by the RPC service implementations. In Samba versions up to 4.10 all talloc children of p->mem_ctx were freed after a RPC response was delivered by calling talloc_free_children(p->mem_ctx). Commit 60fa8e255254d38e9443bf96f2c0f31430be6ab8 removed this call which resulted in all memory allocations on this context not getting released, which can consume significant memory in long running RPC connections. Instead of putting the talloc_free_children(p->mem_ctx) back, just use the mem_ctx argument of the ${pipename}_op_dispatch_internal() function which is a dcesrv_call_state object created by dcesrv_process_ncacn_packet() and released by the RPC server when the RPC request processing is finished. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14675 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1861 Signed-off-by: Ralph Boehme Reviewed-by: Volker Lendecke (cherry picked from commit 4c3fb2a5912966a61e7ebdb05eb3231a0e1d6033) --- Summary of changes: pidl/lib/Parse/Pidl/Samba4/NDR/ServerCompat.pm | 2 + source3/rpc_server/rpc_handles.c | 6 - source3/rpc_server/rpc_ncacn_np.c | 2 +- source3/rpc_server/spoolss/srv_spoolss_nt.c| 6 +- source3/smbd/smb2_setinfo.c| 1 + source4/torture/smb2/lease.c | 145 + 6 files changed, 153 insertions(+), 9
[SCM] Samba Shared Repository - branch v4-14-test updated
The branch, v4-14-test has been updated via 0662726974b s3: smbd: fix deferred renames via f5bb7a55018 s4: torture. Add smb2.lease.rename_wait test to reproduce regression in delay rename for lease break code. via e85d111f54f rpc_server3: Fix a memleak for internal pipes via ed30ce7aa0c spools: avoid leaking memory into the callers mem_ctx via 55c76604ca2 pidl: set the per-request memory context in the pidl generator from 051585ef361 smbd: free open_rec state in remove_deferred_open_message_smb2_internal() https://git.samba.org/?p=samba.git;a=shortlog;h=v4-14-test - Log - commit 0662726974b43c2caa9d4a143c98d6935ca28eb7 Author: Ralph Boehme Date: Mon Mar 29 12:24:39 2021 +0200 s3: smbd: fix deferred renames This was broken by c7a9e0e4cdfb22e66533b5c8e20af3cfdb8ae78c. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14679 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1875 Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison Autobuild-User(master): Ralph Böhme Autobuild-Date(master): Wed Mar 31 06:13:39 UTC 2021 on sn-devel-184 (cherry picked from commit 10d753868e810604d8f60673bbd48f55aaff0797) Autobuild-User(v4-14-test): Karolin Seeger Autobuild-Date(v4-14-test): Thu Apr 1 11:26:31 UTC 2021 on sn-devel-184 commit f5bb7a550180a60d929d854e01aeb84ddb00791f Author: Jeremy Allison Date: Tue Mar 30 15:05:47 2021 -0700 s4: torture. Add smb2.lease.rename_wait test to reproduce regression in delay rename for lease break code. Passes against Windows 10. Add to knownfail, the next commit will fix this. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14679 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1875 Back-ported from 8d9a0b8d57713781c72440c7e91746b5d89e6f6a. Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme commit e85d111f54f7aa77803f1e9fef92d5dd97968fd9 Author: Volker Lendecke Date: Tue Mar 23 17:06:15 2021 +0100 rpc_server3: Fix a memleak for internal pipes state->call should not be talloc'ed off a long-lived context BUG: https://bugzilla.samba.org/show_bug.cgi?id=14675 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1861 RN: Memory leak in the RPC server Signed-off-by: Volker Lendecke Reviewed-by: Samuel Cabrero Reviewed-by: Ralph Boehme Autobuild-User(master): Ralph Böhme Autobuild-Date(master): Wed Mar 31 12:14:01 UTC 2021 on sn-devel-184 (cherry picked from commit 12f516e4680753460e7fe8811e6c6ff70057580c) commit ed30ce7aa0cce39bf0e0a6a97afc8716873692fc Author: Ralph Boehme Date: Mon Mar 22 12:06:39 2021 +0100 spools: avoid leaking memory into the callers mem_ctx BUG: https://bugzilla.samba.org/show_bug.cgi?id=14675 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1861 Signed-off-by: Ralph Boehme Reviewed-by: Volker Lendecke (cherry picked from commit 481176ec745c14b78fca68e01a61c83405a4b97b) commit 55c76604ca2fac7348a6bddba1dfdc128c728f30 Author: Ralph Boehme Date: Tue Mar 23 11:40:21 2021 +0100 pidl: set the per-request memory context in the pidl generator The talloc memory context referenced by the pipe_struct mem_ctx member is used as talloc parent for RPC response data by the RPC service implementations. In Samba versions up to 4.10 all talloc children of p->mem_ctx were freed after a RPC response was delivered by calling talloc_free_children(p->mem_ctx). Commit 60fa8e255254d38e9443bf96f2c0f31430be6ab8 removed this call which resulted in all memory allocations on this context not getting released, which can consume significant memory in long running RPC connections. Instead of putting the talloc_free_children(p->mem_ctx) back, just use the mem_ctx argument of the ${pipename}_op_dispatch_internal() function which is a dcesrv_call_state object created by dcesrv_process_ncacn_packet() and released by the RPC server when the RPC request processing is finished. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14675 CI: https://gitlab.com/samba-team/samba/-/merge_requests/1861 Signed-off-by: Ralph Boehme Reviewed-by: Volker Lendecke (cherry picked from commit 4c3fb2a5912966a61e7ebdb05eb3231a0e1d6033) --- Summary of changes: pidl/lib/Parse/Pidl/Samba4/NDR/ServerCompat.pm | 2 + source3/rpc_server/rpc_handles.c | 6 - source3/rpc_server/rpc_ncacn_np.c | 2 +- source3/rpc_server/spoolss/srv_spoolss_nt.c| 6 +- source3/smbd/smb2_setinfo.c| 1 + source4/torture/smb2/lease.c | 145 + 6 files changed, 153 insertions(+), 9