1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
samba-mirror/source4
Andrew Bartlett 401f555c28 dsdb: Do not permit nested event loops when in a transaction, use a nested event context
It is never safe to execute arbitary code inside a transaction - we
need to get in and get out, not run other events for the rest of the
server.

This patch avoids that by creating a private event loop during
transactions, so no unexpected operations fire, and returning the
original one when we finish it.

If an event fires during an LDB transaction, an unrelated operation
can occur during the transaction, and if the transaction were to be
cancelled, there would be a silent rollback (despite the client having
been indicated success).

Additionally, other processes could be called via IRPC that need to
operate on the database but are locked out due to the ongoing
transaction.

Andrew Bartlett

BUG: https://bugzilla.samba.org/show_bug.cgi?id=10582
Change-Id: I22322fc006e61d7291da17cdf6431416ebb7b30f
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue May  6 13:36:20 CEST 2014 on sn-devel-104
2014-05-06 13:36:20 +02:00
..
auth kerberos: Remove un-used event context argument from smb_krb5_init_context() 2014-04-28 02:24:57 +02:00
build/pasn1
cldap_server s4:lib/socket: simplify iface_list_wildcard() and its callers 2014-03-07 02:18:17 +01:00
client s4:client: fix some compiler warnings 2014-02-13 11:54:13 +01:00
cluster s4:cluster: use DBWRAP_LOCK_ODER_NONE for local_db_tmp_open() 2014-02-07 16:06:07 +01:00
dns_server kerberos: Remove un-used event context argument from smb_krb5_init_context() 2014-04-28 02:24:57 +02:00
dsdb dsdb: Do not permit nested event loops when in a transaction, use a nested event context 2014-05-06 13:36:20 +02:00
echo_server s4:echo_server fix compiler warnings 2013-12-12 14:21:28 -08:00
heimdal heimdal: Only indicate successful authentication after successful authz 2014-04-02 17:12:47 +02:00
heimdal_build Remove special nss_wrapper code 2014-04-17 14:56:06 +02:00
include Replace all uses of setXX[ug]id() and setgroups with samba_setXX[ug]id() calls. 2012-06-28 17:15:16 -07:00
kdc kerberos: Remove un-used event context argument from smb_krb5_init_context() 2014-04-28 02:24:57 +02:00
ldap_server s4:ldap_server: make use of gensec_update_ev() 2014-03-27 00:36:31 +01:00
lib s4:lib/tls: explicitly use allow_warnings=True 2014-04-02 09:03:46 +02:00
libcli selftest: Rename WINBINDD_SOCKET_DIR environment variable. 2014-04-17 14:56:06 +02:00
libnet Fix an empty if statement. 2014-05-05 20:19:13 +02:00
librpc s4:librpc: explicitly use allow_warnings=True where needed 2014-04-02 09:03:46 +02:00
nbt_server lib/param: handle non-constant strings properly by passing in a memory context 2014-02-20 10:11:06 +13:00
ntp_signd build: Build with system md5.h on OpenIndiana 2013-06-19 21:32:36 +02:00
ntptr spoolss: make spoolss deal with ndr64 SetForm by using proper container object. 2013-01-17 17:11:37 +01:00
ntvfs s4-ntfs: Improve uid check in wrapper mode. 2014-04-17 14:56:05 +02:00
param s4:param/tests: add missing #include "torture/local/proto.h" 2014-04-02 09:03:45 +02:00
rpc_server s4:samr: allow builtin groups for samr_OpenGroup. 2014-05-03 07:57:13 +02:00
script lib/param: generate the param_functions.h containing the prototypes 2014-02-12 13:17:13 +13:00
scripting s4:samba_kcc: Use 'dburl' passed from command line rather than lp.samdb_url() 2014-04-22 23:34:15 +02:00
selftest selftest: Add tests for dbcheck detection and removal of partial objects 2014-05-03 07:57:13 +02:00
setup selftest: make blackbox_setpassword.sh test run independently 2014-04-02 17:12:45 +02:00
smb_server s4:smb_server/smb: fix invalid pointer type warnings in negprot.c 2014-04-02 09:03:44 +02:00
smbd ad-dc: use exit_daemon() to communicate status of startup to systemd 2014-04-23 04:44:46 +02:00
torture kerberos: Remove un-used event context argument from smb_krb5_init_context() 2014-04-28 02:24:57 +02:00
utils Typo: s/preceeded/preceded/ 2014-04-14 03:51:15 +02:00
web_server s4:lib/socket: simplify iface_list_wildcard() and its callers 2014-03-07 02:18:17 +01:00
winbind winbind: Allow winbindd to be run from inside "samba" 2014-04-29 05:28:39 +02:00
wrepl_server Remove all uses of the NT_STATUS_NOT_OK_RETURN_AND_FREE macro from the codebase. 2014-03-05 16:33:22 +01:00
.clang_complete s3-build: Add .clang_complete. 2011-10-27 17:09:50 +02:00
.valgrind_suppressions
wscript_build Do not install smbclient4 and nmblookup4 2014-04-15 03:25:13 +02:00