sfrench/samba-autobuild/.git
10 years agoscannedonly: Fix CID 242109 Unchecked return value from library
Volker Lendecke [Sun, 15 Dec 2013 20:07:00 +0000 (21:07 +0100)]
scannedonly: Fix CID 242109 Unchecked return value from library

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agontvfs: Fix CID 241291 Argument cannot be negative
Volker Lendecke [Sun, 15 Dec 2013 20:00:04 +0000 (21:00 +0100)]
ntvfs: Fix CID 241291 Argument cannot be negative

getgroups can return -1, which talloc_array won't be happy about

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agotevent: Fix CID 1138326 Unchecked return value
Volker Lendecke [Sun, 15 Dec 2013 19:40:06 +0000 (20:40 +0100)]
tevent: Fix CID 1138326 Unchecked return value

For this case we explicitly have added tevent_req_oom

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agoFix CID 1138340 Resource leak
Volker Lendecke [Sun, 15 Dec 2013 19:28:53 +0000 (20:28 +0100)]
Fix CID 1138340 Resource leak

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agoFix CID 1138341 Resource leak
Volker Lendecke [Sun, 15 Dec 2013 19:28:04 +0000 (20:28 +0100)]
Fix CID 1138341 Resource leak

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agotdb_util: Fix whitespace
Volker Lendecke [Sun, 15 Dec 2013 19:23:16 +0000 (20:23 +0100)]
tdb_util: Fix whitespace

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agotdb_util: Fix CID 1138343 Uninitialized scalar variable
Volker Lendecke [Sun, 15 Dec 2013 19:22:36 +0000 (20:22 +0100)]
tdb_util: Fix CID 1138343 Uninitialized scalar variable

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3: Handle stat call with capability in vfs_gpfs
Abhidnya Joshi [Tue, 10 Dec 2013 10:01:43 +0000 (11:01 +0100)]
s3: Handle stat call with capability in vfs_gpfs

Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
Autobuild-User(master): Christof Schmitt <cs@samba.org>
Autobuild-Date(master): Mon Dec 16 20:05:23 CET 2013 on sn-devel-104

10 years agos3: Add DAC_OVERRIDE capability support
Abhidnya Joshi [Tue, 10 Dec 2013 08:10:21 +0000 (09:10 +0100)]
s3: Add DAC_OVERRIDE capability support

Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
10 years agogencache: Fix a type-punned warning
Volker Lendecke [Mon, 16 Dec 2013 11:42:46 +0000 (12:42 +0100)]
gencache: Fix a type-punned warning

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Mon Dec 16 17:11:13 CET 2013 on sn-devel-104

10 years agos3: smbpasswd - fix crashes on invalid input.
Jeremy Allison [Thu, 12 Dec 2013 17:37:25 +0000 (09:37 -0800)]
s3: smbpasswd - fix crashes on invalid input.

get_pass can return NULL on error. Ensure that
this is always the case and fix all callers to cope
(some already did).

Reported by Joonas Kuorilehto <joneskoo@codenomicon.com>

BUG: https://bugzilla.samba.org/show_bug.cgi?id=10320

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Mon Dec 16 15:17:58 CET 2013 on sn-devel-104

10 years agoauth_samba4: Describe the slightly unusual role of auth_samba4
Andrew Bartlett [Fri, 13 Dec 2013 00:38:29 +0000 (13:38 +1300)]
auth_samba4: Describe the slightly unusual role of auth_samba4

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon Dec 16 03:18:00 CET 2013 on sn-devel-104

10 years agos3:smbd: avoid calling fd_is_readable() without async echo handler
Stefan Metzmacher [Wed, 11 Dec 2013 14:02:27 +0000 (15:02 +0100)]
s3:smbd: avoid calling fd_is_readable() without async echo handler

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Sat Dec 14 20:19:10 CET 2013 on sn-devel-104

10 years agos3:lib: avoid talloc_zero_array() in poll_one_fd()
Stefan Metzmacher [Wed, 4 Dec 2013 22:31:10 +0000 (23:31 +0100)]
s3:lib: avoid talloc_zero_array() in poll_one_fd()

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agos3:smbd: use PATH_MAX for the buffer passed to full_path_tos()
Stefan Metzmacher [Sat, 14 Dec 2013 09:45:42 +0000 (10:45 +0100)]
s3:smbd: use PATH_MAX for the buffer passed to full_path_tos()

We use this in other places too and it's better than a hardcoded value.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotdb: Avoid reallocs for lockrecs
Volker Lendecke [Mon, 9 Dec 2013 09:56:33 +0000 (09:56 +0000)]
tdb: Avoid reallocs for lockrecs

In normal operations we have at most 3 entries in this array. Don't
bother with shrinking.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Sat Dec 14 13:19:47 CET 2013 on sn-devel-104

10 years agosmbd: Early exit
Volker Lendecke [Fri, 6 Dec 2013 10:31:22 +0000 (10:31 +0000)]
smbd: Early exit

Yes, this also showed up in profiles

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agosmbd: Implement and use full_path_tos
Volker Lendecke [Fri, 6 Dec 2013 14:34:05 +0000 (14:34 +0000)]
smbd: Implement and use full_path_tos

Yes, this looks like a hack, but talloc_asprintf does show up high in
profiles called from these routines

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agosmbd: Avoid pointless strcsequal calls
Volker Lendecke [Fri, 6 Dec 2013 12:10:37 +0000 (12:10 +0000)]
smbd: Avoid pointless strcsequal calls

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agodbwrap: No lock_order check if not required
Volker Lendecke [Fri, 6 Dec 2013 11:57:42 +0000 (11:57 +0000)]
dbwrap: No lock_order check if not required

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agodbwrap_cache: Check negative first
Volker Lendecke [Sat, 7 Dec 2013 12:58:43 +0000 (12:58 +0000)]
dbwrap_cache: Check negative first

dbwrap_cache is right now used for notify most, and we hope to have very
few notifies around. So negative hits will be more likely than positive

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agodbwrap_cache: Fix dbwrap_cache_validate
Volker Lendecke [Sat, 7 Dec 2013 12:58:07 +0000 (12:58 +0000)]
dbwrap_cache: Fix dbwrap_cache_validate

Classic brown paper bag bug :-(

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agosmbd: Simplify get_share_mode_lock a bit
Volker Lendecke [Fri, 6 Dec 2013 07:40:03 +0000 (07:40 +0000)]
smbd: Simplify get_share_mode_lock a bit

This does two things: It gets rid of a talloc_stackframe in a hot
code path and to me it makes the code easier to understand. It makes
the talloc hierarchy more obvious to follow.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agodbwrap: Avoid a stackframe in fetch_locked_internal
Volker Lendecke [Fri, 6 Dec 2013 11:38:12 +0000 (11:38 +0000)]
dbwrap: Avoid a stackframe in fetch_locked_internal

This shows in profiles. We call this so often that this is a pretty
hot code path.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agoiconv: Use a static buffer in iconf not to spoil the talloc_pool
Volker Lendecke [Fri, 6 Dec 2013 10:31:07 +0000 (10:31 +0000)]
iconv: Use a static buffer in iconf not to spoil the talloc_pool

This is a buffer that is strictly used like a stack variable. This
patch makes it one and while there it fixes an error path memleak.
In the "pull_failed" case we did not talloc_free(cvtbuf). With
talloc_tos(), this does not really matter, but for code without
this it does.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agosmbd: Fix a false DEBUG fn name
Volker Lendecke [Sun, 8 Dec 2013 16:41:04 +0000 (16:41 +0000)]
smbd: Fix a false DEBUG fn name

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agotorture3: Do not depend on epoll
Volker Lendecke [Fri, 13 Dec 2013 13:55:45 +0000 (14:55 +0100)]
torture3: Do not depend on epoll

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agosecacl: Slightly simplify make_sec_acl
Volker Lendecke [Fri, 6 Dec 2013 09:29:19 +0000 (09:29 +0000)]
secacl: Slightly simplify make_sec_acl

This avoids a complex if-expression

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sat Dec 14 00:10:21 CET 2013 on sn-devel-104

10 years agosecacl: Fix a memleak in an error path
Volker Lendecke [Fri, 6 Dec 2013 09:28:40 +0000 (09:28 +0000)]
secacl: Fix a memleak in an error path

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agosecacl: Don't use talloc_zero
Volker Lendecke [Fri, 6 Dec 2013 09:26:25 +0000 (09:26 +0000)]
secacl: Don't use talloc_zero

We initialize all but one field anyway

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agosecacl: Fix whitespace
Volker Lendecke [Fri, 6 Dec 2013 09:25:20 +0000 (09:25 +0000)]
secacl: Fix whitespace

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:rpc_server/lsa_lookup fix a compile warning
Christian Ambach [Tue, 10 Dec 2013 19:31:21 +0000 (20:31 +0100)]
s4:rpc_server/lsa_lookup fix a compile warning

about a set, but unused variable

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Dec 13 01:49:50 CET 2013 on sn-devel-104

10 years agos4:libcli fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:54:37 +0000 (17:54 +0100)]
s4:libcli fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:kdc fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:54:05 +0000 (17:54 +0100)]
s4:kdc fix compiler warnings

about set but unused variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:echo_server fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:53:49 +0000 (17:53 +0100)]
s4:echo_server fix compiler warnings

about set but unused variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:dsdb fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:53:15 +0000 (17:53 +0100)]
s4:dsdb fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:dsdb fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:52:30 +0000 (17:52 +0100)]
s4:dsdb fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:dsdb fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:52:29 +0000 (17:52 +0100)]
s4:dsdb fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:dsdb fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:52:29 +0000 (17:52 +0100)]
s4:dsdb fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:dsdb fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:52:29 +0000 (17:52 +0100)]
s4:dsdb fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos4:dsdb fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:52:29 +0000 (17:52 +0100)]
s4:dsdb fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3:winbindd fix a compiler warning
Christian Ambach [Tue, 10 Dec 2013 16:50:36 +0000 (17:50 +0100)]
s3:winbindd fix a compiler warning

about a potentially uninitialized variable

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3:smbd/smb2 fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:49:44 +0000 (17:49 +0100)]
s3:smbd/smb2 fix compiler warnings

about a potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3:printing fix a compiler warning
Christian Ambach [Tue, 10 Dec 2013 16:49:18 +0000 (17:49 +0100)]
s3:printing fix a compiler warning

about a potentially uninitialized variable

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3:libsmb fix a compiler warning
Christian Ambach [Tue, 10 Dec 2013 16:48:59 +0000 (17:48 +0100)]
s3:libsmb fix a compiler warning

about a potentially uninitialized variable

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agolibcli: fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:48:25 +0000 (17:48 +0100)]
libcli: fix compiler warnings

about missing prototypes

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agolib/clap fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:47:50 +0000 (17:47 +0100)]
lib/clap fix compiler warnings

about set but unused variable

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agolib/tdb: fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:47:05 +0000 (17:47 +0100)]
lib/tdb: fix compiler warnings

about a variable shadowing a global declaration

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agolib/ldb fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:46:30 +0000 (17:46 +0100)]
lib/ldb fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agolib/ldb fix compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:45:58 +0000 (17:45 +0100)]
lib/ldb fix compiler warnings

about potentially uninitialized variables

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agolib/ldb-samba: fix a compiler warning
Christian Ambach [Tue, 10 Dec 2013 16:45:14 +0000 (17:45 +0100)]
lib/ldb-samba: fix a compiler warning

about macro redefinition

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agolib/compression: fix a compiler warnings
Christian Ambach [Tue, 10 Dec 2013 16:43:55 +0000 (17:43 +0100)]
lib/compression: fix a compiler warnings

about set but unused variable

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agowaf docs: build the new vfs worm man page
Björn Baumbach [Wed, 20 Nov 2013 13:24:21 +0000 (14:24 +0100)]
waf docs: build the new vfs worm man page

Signed-off-by: Björn Baumbach <bb@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agodocs-man: add manual page for the new worm vfs module
Björn Baumbach [Wed, 20 Nov 2013 12:00:04 +0000 (13:00 +0100)]
docs-man: add manual page for the new worm vfs module

Signed-off-by: Björn Baumbach <bb@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3-waf: build new vfs_worm module
Volker Lendecke [Wed, 20 Nov 2013 11:11:41 +0000 (12:11 +0100)]
s3-waf: build new vfs_worm module

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3-modules: add new vfs_worm module
Volker Lendecke [Wed, 20 Nov 2013 11:09:47 +0000 (12:09 +0100)]
s3-modules: add new vfs_worm module

VFS module to disallow writes for older files.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agolib-util: add functions to get elapsed from given timespec structs
Volker Lendecke [Wed, 20 Nov 2013 11:00:17 +0000 (12:00 +0100)]
lib-util: add functions to get elapsed from given timespec structs

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agodocs: Add kill-client-ip to smbcontrol manpage
Christof Schmitt [Fri, 6 Dec 2013 23:03:30 +0000 (16:03 -0700)]
docs: Add kill-client-ip to smbcontrol manpage

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Christof Schmitt <cs@samba.org>
Autobuild-Date(master): Thu Dec 12 20:45:44 CET 2013 on sn-devel-104

10 years agos3:utils/smbcontrol implement kill-client-ip in smbcontrol
Christian Ambach [Fri, 15 Mar 2013 14:09:18 +0000 (15:09 +0100)]
s3:utils/smbcontrol implement kill-client-ip in smbcontrol

allows the admin to forcefully shutdown the connection of a specified client by IP address

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3:smbd react on message that client should be disconnected
Christian Ambach [Fri, 15 Mar 2013 14:08:22 +0000 (15:08 +0100)]
s3:smbd react on message that client should be disconnected

if MSG_SMB_KILL_CLIENT_IP message comes in and our client has
the IP address given as argument, then shutdown the connection immediately

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agos3:messaging add MSG_SMB_KILL_CLIENT_IP message
Christian Ambach [Fri, 15 Mar 2013 14:06:41 +0000 (15:06 +0100)]
s3:messaging add MSG_SMB_KILL_CLIENT_IP message

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
10 years agoshadow_copy2: Fix some typos
David Keegel [Thu, 12 Dec 2013 11:08:58 +0000 (12:08 +0100)]
shadow_copy2: Fix some typos

Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Thu Dec 12 17:58:24 CET 2013 on sn-devel-104

10 years agolibgpo/security_CSE: more preamble header checks of SecEdit/GptTmpl.inf files.
Günther Deschner [Tue, 10 Dec 2013 23:59:55 +0000 (00:59 +0100)]
libgpo/security_CSE: more preamble header checks of SecEdit/GptTmpl.inf files.

$CHICAGO$ needs to be double quoted.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Thu Dec 12 15:31:14 CET 2013 on sn-devel-104

10 years agolibgpo/security_CSE: fix unicode preamble check of SecEdit/GptTmpl.inf files.
Günther Deschner [Tue, 10 Dec 2013 23:50:03 +0000 (00:50 +0100)]
libgpo/security_CSE: fix unicode preamble check of SecEdit/GptTmpl.inf files.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolibgpo: add gp_inifile_getbool().
Günther Deschner [Tue, 10 Dec 2013 23:44:49 +0000 (00:44 +0100)]
libgpo: add gp_inifile_getbool().

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolibgpo: fix segfault in gpo_process_gpo_list().
Günther Deschner [Tue, 10 Dec 2013 17:06:14 +0000 (18:06 +0100)]
libgpo: fix segfault in gpo_process_gpo_list().

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolibgpo: make sure we correctly can store the group policy state.
Günther Deschner [Tue, 10 Dec 2013 16:39:54 +0000 (17:39 +0100)]
libgpo: make sure we correctly can store the group policy state.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolibgpo: remove use of deprecated talloc functions.
Günther Deschner [Tue, 10 Dec 2013 22:44:23 +0000 (23:44 +0100)]
libgpo: remove use of deprecated talloc functions.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolibgpo: remove unused libgpo wscript_build.
Günther Deschner [Tue, 10 Dec 2013 22:18:17 +0000 (23:18 +0100)]
libgpo: remove unused libgpo wscript_build.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolibgpo: use existing connection to the ds for the sysvol queries.
Günther Deschner [Tue, 10 Dec 2013 21:50:47 +0000 (22:50 +0100)]
libgpo: use existing connection to the ds for the sysvol queries.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolibgpo: remove unused loadparm_context from functions.
Günther Deschner [Tue, 10 Dec 2013 17:26:51 +0000 (18:26 +0100)]
libgpo: remove unused loadparm_context from functions.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolibgpo: remove duplicate parse_gpt_ini header.
Günther Deschner [Tue, 10 Dec 2013 09:10:22 +0000 (10:10 +0100)]
libgpo: remove duplicate parse_gpt_ini header.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agotevent: version 0.9.20 tevent-0.9.20
Stefan Metzmacher [Fri, 27 Sep 2013 02:06:00 +0000 (04:06 +0200)]
tevent: version 0.9.20

This adds the following new features:

- tevent_queue_wait_send/recv()
- tevent_num_signals()
- tevent_sa_info_queue_count()

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Thu Dec 12 00:39:35 CET 2013 on sn-devel-104

10 years agotevent: give the user the chance to ask for TEVENT_NUM_SIGNALS and TEVENT_SA_INFO_QUE...
Stefan Metzmacher [Mon, 9 Dec 2013 09:32:00 +0000 (10:32 +0100)]
tevent: give the user the chance to ask for TEVENT_NUM_SIGNALS and TEVENT_SA_INFO_QUEUE_COUNT

This way the caller can change use the supported limits without using hardcoded
values.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10214
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: change TEVENT_SA_INFO_QUEUE_COUNT from 64 to 256
Stefan Metzmacher [Mon, 9 Dec 2013 09:29:45 +0000 (10:29 +0100)]
tevent: change TEVENT_SA_INFO_QUEUE_COUNT from 64 to 256

There are some existing callers which assume the old
SA_INFO_QUEUE_COUNT 100 value.

256 should give room for the future.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10214
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: tevent_epoll_set_panic_fallback() can be a void function
Stefan Metzmacher [Wed, 11 Dec 2013 17:58:41 +0000 (18:58 +0100)]
tevent: tevent_epoll_set_panic_fallback() can be a void function

There's no case where this could return an error.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: make use of talloc_get_type_abort() in tevent_epoll.c
Stefan Metzmacher [Thu, 5 Dec 2013 07:47:27 +0000 (08:47 +0100)]
tevent: make use of talloc_get_type_abort() in tevent_epoll.c

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: make use of talloc_get_type_abort() in tevent_signal.c
Stefan Metzmacher [Thu, 5 Dec 2013 07:47:27 +0000 (08:47 +0100)]
tevent: make use of talloc_get_type_abort() in tevent_signal.c

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: make use of talloc_get_type_abort() in tevent_select.c
Stefan Metzmacher [Thu, 5 Dec 2013 07:47:27 +0000 (08:47 +0100)]
tevent: make use of talloc_get_type_abort() in tevent_select.c

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: make use of talloc_get_type_abort() in tevent_req.c
Stefan Metzmacher [Thu, 5 Dec 2013 07:47:27 +0000 (08:47 +0100)]
tevent: make use of talloc_get_type_abort() in tevent_req.c

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: make use of talloc_get_type_abort() in tevent_queue.c
Stefan Metzmacher [Thu, 5 Dec 2013 07:47:27 +0000 (08:47 +0100)]
tevent: make use of talloc_get_type_abort() in tevent_queue.c

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: use talloc_get_type_abort() in the documentation examples
Stefan Metzmacher [Thu, 5 Dec 2013 07:46:47 +0000 (08:46 +0100)]
tevent: use talloc_get_type_abort() in the documentation examples

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: add tevent_queue_wait_send/recv()
Gregor Beck [Thu, 19 Sep 2013 13:14:25 +0000 (15:14 +0200)]
tevent: add tevent_queue_wait_send/recv()

Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: tevent_req_create() already uses ZERO_STRUCT(req)
Stefan Metzmacher [Fri, 27 Sep 2013 01:02:24 +0000 (03:02 +0200)]
tevent: tevent_req_create() already uses ZERO_STRUCT(req)

There's no need to zero individual members.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: let tevent_req_received() clear the private_cancel function
Stefan Metzmacher [Fri, 27 Sep 2013 00:59:22 +0000 (02:59 +0200)]
tevent: let tevent_req_received() clear the private_cancel function

This makes sure it's not called when the private state is already gone.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agotevent: cancel the timeout timer when the request is finished
Stefan Metzmacher [Sat, 17 Sep 2011 17:53:55 +0000 (19:53 +0200)]
tevent: cancel the timeout timer when the request is finished

As we might defer the callback with tevent_req_defer_callback()
when calling tevent_req_done(), we should cancel the timeout directly.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
10 years agos3/rpc_server: don't unmarshall PDUs twice
David Disseldorp [Tue, 10 Dec 2013 12:59:06 +0000 (13:59 +0100)]
s3/rpc_server: don't unmarshall PDUs twice

DCE/RPC PDUs are currently unmarshalled firstly by the generic librpc
dcerpc_read_ncacn_packet_[send/recv] functions, and subsequently a
second time by the source3 rpc_server, which ignores the unmarshalled
packet and re-parses the receive buffer.

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Wed Dec 11 22:24:31 CET 2013 on sn-devel-104

10 years agoshadow_copy2: add a comment explaining why we don't talloc_zero_array().
Michael Adam [Wed, 11 Dec 2013 08:41:38 +0000 (09:41 +0100)]
shadow_copy2: add a comment explaining why we don't talloc_zero_array().

Since I stumbled over this slighly sublte point, I thought it is
worthwile to point it our in a comment.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Wed Dec 11 19:55:20 CET 2013 on sn-devel-104

10 years agoshadow_copy2: revert expensive and unnecessary zero-initialization
Michael Adam [Wed, 11 Dec 2013 08:34:47 +0000 (09:34 +0100)]
shadow_copy2: revert expensive and unnecessary zero-initialization

I was being overly cautious. This is initialization is not
necessary, since further down in the for-loop, the memory
always gets fully initialized because the insert string is
inserted at various slash positions.

So this talloc_zero_array can be skipped: this an expensive
thing to do in virtually every VFS call.

This essentially reverts commit 249e9b4a34d8959bd94735c1921ecfc24d6a2705.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agolib:util: fix a comment typo
Michael Adam [Wed, 11 Dec 2013 16:47:36 +0000 (17:47 +0100)]
lib:util: fix a comment typo

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agos3: use directory_create_or_exist_strict() to create corepath
Gregor Beck [Mon, 22 Apr 2013 11:33:00 +0000 (13:33 +0200)]
s3: use directory_create_or_exist_strict() to create corepath

This simplifies the code and even works in testenv where the chown call
fails.

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
10 years agoselftest: pass -l logdir to daemon processes.
Gregor Beck [Mon, 22 Apr 2013 10:35:01 +0000 (12:35 +0200)]
selftest: pass -l logdir to daemon processes.

The daemons try to set up the corefile path within logdir before the config
file was read.

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
10 years agoselftest: use MALLOC_CHECK_=3 to give a diagnostic on failure
Gregor Beck [Wed, 20 Mar 2013 09:58:22 +0000 (10:58 +0100)]
selftest: use MALLOC_CHECK_=3 to give a diagnostic on failure

With MALLOC_CHECK_ set to 2 in case of a failure abort() is called
silently which hopefully creates a core dump.
MALLOC_CHECK_=3 additionally gives an error message on stderr in case.

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
10 years agoselftest: set valgrind options
Gregor Beck [Wed, 20 Mar 2013 09:36:37 +0000 (10:36 +0100)]
selftest: set valgrind options

In particular '--db-attach' interferes badly with the io redirection of the
test environment and is superseded by the vgdb feature of valgrind.

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
10 years agoselftest: setup {NMBD,WINBINDD,SMBD}_VALGRIND
Stefan Metzmacher [Tue, 19 Mar 2013 14:44:02 +0000 (15:44 +0100)]
selftest: setup {NMBD,WINBINDD,SMBD}_VALGRIND

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
10 years agoselftest/Samba3: export ENVNAME
Stefan Metzmacher [Tue, 19 Mar 2013 14:43:12 +0000 (15:43 +0100)]
selftest/Samba3: export ENVNAME

This is used by selftest/in_screen.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
10 years agodocs: Fix typos in vfs_shadow_copy2.8.xml.
Karolin Seeger [Tue, 10 Dec 2013 14:24:31 +0000 (15:24 +0100)]
docs: Fix typos in vfs_shadow_copy2.8.xml.

Signed-off-by: Karolin Seeger <kseeger@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Tue Dec 10 18:49:21 CET 2013 on sn-devel-104

10 years agos3-lib: Fix %G substitution for domain users in smbd
Andreas Schneider [Wed, 27 Nov 2013 16:21:01 +0000 (17:21 +0100)]
s3-lib: Fix %G substitution for domain users in smbd

BUG: https://bugzilla.samba.org/show_bug.cgi?id=10286
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Christian Ambach <ambi@samba.org>
Autobuild-User(master): Christian Ambach <ambi@samba.org>
Autobuild-Date(master): Tue Dec 10 16:39:43 CET 2013 on sn-devel-104

10 years agos3:winbindd fix use of uninitialized variables
Christian Ambach [Mon, 16 Sep 2013 11:18:17 +0000 (13:18 +0200)]
s3:winbindd fix use of uninitialized variables

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10280

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agos3:lib/asys modify included headers
Christian Ambach [Fri, 22 Nov 2013 04:12:05 +0000 (05:12 +0100)]
s3:lib/asys modify included headers

use the headers from libreplace, not the system ones

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>