gd/samba-autobuild/.git
8 years agovfs_scannedonly: Remove vfs_scannedonly from samba source tree.
Robin Hack [Fri, 21 Aug 2015 01:54:03 +0000 (13:54 +1200)]
vfs_scannedonly: Remove vfs_scannedonly from samba source tree.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11459
Signed-off-by: Robin Hack <hack.robin@gmail.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Fri Aug 21 07:17:35 CEST 2015 on sn-devel-104

8 years agoscript/autobuild.py: make sure --nonshared-binary=smbtorture,smbd/smbd keeps working
Stefan Metzmacher [Thu, 13 Aug 2015 08:32:46 +0000 (10:32 +0200)]
script/autobuild.py: make sure --nonshared-binary=smbtorture,smbd/smbd keeps working

- It's very useful to have a static smbtorture binary that can be copied arround.
- It's sometimes also useful to have a static smbd binary in order avoid
  runtime overhead via do_lookup_x() (in ld*.so), note that

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Thu Aug 20 19:10:19 CEST 2015 on sn-devel-104

8 years agoscript/autobuild.py: test some --with-{static,shared}-modules combinations
Stefan Metzmacher [Thu, 13 Aug 2015 15:38:43 +0000 (17:38 +0200)]
script/autobuild.py: test some --with-{static,shared}-modules combinations

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agoscript/autobuild.py: use -Wmissing-prototypes and --picky-developer for samba-libs*
Stefan Metzmacher [Fri, 14 Aug 2015 06:40:37 +0000 (08:40 +0200)]
script/autobuild.py: use -Wmissing-prototypes and --picky-developer for samba-libs*

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agoscript/autobuild.py: split out a samba_libs_configure variable
Stefan Metzmacher [Thu, 13 Aug 2015 15:34:42 +0000 (17:34 +0200)]
script/autobuild.py: split out a samba_libs_configure variable

The avoids too long lines.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:wscript: make --with-{static,shared}-modules options more flexible
Stefan Metzmacher [Thu, 13 Aug 2015 12:22:45 +0000 (14:22 +0200)]
s3:wscript: make --with-{static,shared}-modules options more flexible

'!module' disables a non-required module for a static/shared build.
'!DEFAULT' disables all modules defaulting to a static/shared build.
'!FORCED' disables all (non-required) modules forced to a static/shared build.
'ALL' switches the default for all non forced modules from static to shared
or from shared to static.
The most specific specification wins
e.g.
--with-static-modules='!FORCED,!DEFAULT' --with-shared-modules='!FORCED,!DEFAULT' will only
build modules which are required for the compilation. Might be useful
if someone only wants to use client utils.

--with-static-modules=ALL will build all modules statically linked.

--with-static-modules='!DEFAULT,ALL' --with-shared-modules='!DEFAULT,ALL'
might be useful for testing, it reverses the default build for all modules
which can be build shared or static.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:wscript: simplify ABI matching for pdb_*_init()
Stefan Metzmacher [Thu, 13 Aug 2015 16:57:19 +0000 (18:57 +0200)]
s3:wscript: simplify ABI matching for pdb_*_init()

The init functions of all static modules should be ignored.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:winbindd/idmap_*: make function prototypes available via static_decl_idmap;
Stefan Metzmacher [Thu, 13 Aug 2015 16:16:20 +0000 (18:16 +0200)]
s3:winbindd/idmap_*: make function prototypes available via static_decl_idmap;

This allows the static build of the modules.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:modules/perfcount_*: make function prototypes available via static_decl_perfcount;
Stefan Metzmacher [Thu, 13 Aug 2015 16:16:20 +0000 (18:16 +0200)]
s3:modules/perfcount_*: make function prototypes available via static_decl_perfcount;

This allows the static build of the modules.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:modules/vfs_*: make function prototypes available via static_decl_vfs;
Stefan Metzmacher [Thu, 13 Aug 2015 16:16:20 +0000 (18:16 +0200)]
s3:modules/vfs_*: make function prototypes available via static_decl_vfs;

This allows the static build of the modules.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agoexamples/VFS: make function prototypes available via static_decl_vfs;
Stefan Metzmacher [Thu, 13 Aug 2015 16:16:20 +0000 (18:16 +0200)]
examples/VFS: make function prototypes available via static_decl_vfs;

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agoexamples/pdb: fix and validate pdb_test_init() prototype via static_decl_pdb;
Stefan Metzmacher [Thu, 13 Aug 2015 16:16:20 +0000 (18:16 +0200)]
examples/pdb: fix and validate pdb_test_init() prototype via static_decl_pdb;

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos4:ntvfs/posix: fix forward declaration of struct pvfs_state
Stefan Metzmacher [Thu, 13 Aug 2015 16:15:36 +0000 (18:15 +0200)]
s4:ntvfs/posix: fix forward declaration of struct pvfs_state

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:wscript: remove leftover from vfs_notify_fam
Stefan Metzmacher [Thu, 13 Aug 2015 16:15:03 +0000 (18:15 +0200)]
s3:wscript: remove leftover from vfs_notify_fam

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:idmap: we need to allow undefined symbols in idmap_tdb
Stefan Metzmacher [Thu, 13 Aug 2015 18:07:59 +0000 (20:07 +0200)]
s3:idmap: we need to allow undefined symbols in idmap_tdb

When idmap_tdb is build as shared module we need to allow undefined symbols
which callback into winbindd code.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:wscript: fix the build without any idmap module
Stefan Metzmacher [Thu, 13 Aug 2015 13:04:14 +0000 (15:04 +0200)]
s3:wscript: fix the build without any idmap module

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agosmbd: Remove an unnecessary else branch
Volker Lendecke [Wed, 12 Aug 2015 16:32:54 +0000 (18:32 +0200)]
smbd: Remove an unnecessary else branch

"goto out;" is sufficient before

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Thu Aug 20 15:52:20 CEST 2015 on sn-devel-104

8 years agovfs: Add some {}
Volker Lendecke [Wed, 12 Aug 2015 15:48:41 +0000 (17:48 +0200)]
vfs: Add some {}

The "mode = " from a very casual view looked as if it was part of the
if-condition

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
8 years agolib: Use dom_sid_equal where appropriate
Volker Lendecke [Fri, 14 Aug 2015 09:40:51 +0000 (11:40 +0200)]
lib: Use dom_sid_equal where appropriate

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
8 years agoctdb: Use talloc_report_str in ctdb
Volker Lendecke [Sun, 16 Aug 2015 11:19:15 +0000 (13:19 +0200)]
ctdb: Use talloc_report_str in ctdb

This fixes CID 1125620 Insecure temporary file

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
8 years agolib: Add the pointer itself to talloc_report_str
Volker Lendecke [Mon, 17 Aug 2015 09:55:26 +0000 (11:55 +0200)]
lib: Add the pointer itself to talloc_report_str

A ctdb test found this discrepancy to talloc_report_full :-)

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
8 years agogensec: Fix CID 242642 Unchecked return value
Volker Lendecke [Sun, 16 Aug 2015 11:03:13 +0000 (13:03 +0200)]
gensec: Fix CID 242642 Unchecked return value

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
8 years agoreplace: Fix bug 11455
Volker Lendecke [Tue, 18 Aug 2015 18:57:27 +0000 (20:57 +0200)]
replace: Fix bug 11455

Don't call rep_strtoull recursively

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

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Wed Aug 19 11:22:38 CEST 2015 on sn-devel-104

8 years agoctdb: Fix some clang uninitialized errors
Volker Lendecke [Wed, 19 Aug 2015 05:35:32 +0000 (07:35 +0200)]
ctdb: Fix some clang uninitialized errors

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agoctdb: Fix the build on FreeBSD 10.1
Volker Lendecke [Wed, 19 Aug 2015 05:33:48 +0000 (07:33 +0200)]
ctdb: Fix the build on FreeBSD 10.1

We get sockaddr_in directly in parse_ipv4

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos4:torture/rpc: fix ndr_security.h include in fsrvp.c
Stefan Metzmacher [Wed, 12 Aug 2015 07:24:42 +0000 (09:24 +0200)]
s4:torture/rpc: fix ndr_security.h include in fsrvp.c

We should not include ndr_security.c

This allows ./configure --nonshared-binary=smbtorture again.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Mon Aug 17 20:53:10 CEST 2015 on sn-devel-104

8 years agorelease-scripts/build-manpages-nogit: run make realdistclean at the end
Stefan Metzmacher [Sat, 15 Aug 2015 08:59:45 +0000 (10:59 +0200)]
release-scripts/build-manpages-nogit: run make realdistclean at the end

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos3:smb2_negprot: prefer AES128_CCM if the client supports it
Stefan Metzmacher [Mon, 17 Aug 2015 06:56:43 +0000 (08:56 +0200)]
s3:smb2_negprot: prefer AES128_CCM if the client supports it

Callgrind showed that we use 28,165,720,719 cpu cycles to send
a 100MB file to a client using aes-ccm.

With aes-gcm this is raises up to 723,094,413,831 cpu cycles.

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agolibcli/smb: prefer AES128_CCM
Stefan Metzmacher [Mon, 17 Aug 2015 06:56:43 +0000 (08:56 +0200)]
libcli/smb: prefer AES128_CCM

Callgrind showed that we use 28,165,720,719 cpu cycles to send
a 100MB file to a client using aes-ccm.

With aes-gcm this is raises up to 723,094,413,831 cpu cycles.

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agoRevert "ldb-samba: Implement transitive extended matching"
Andrew Bartlett [Mon, 17 Aug 2015 04:03:10 +0000 (16:03 +1200)]
Revert "ldb-samba: Implement transitive extended matching"

This reverts commit 2a22ba34cd6f28950246b54c6577c922c61f4fdb.

selftest/knownfail entries are added to ensure 'make test' continues to pass

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

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agoRevert "dsdb: Only parse SAMBA_LDAP_MATCH_RULE_TRANSITIVE_EVAL as a DN"
Andrew Bartlett [Mon, 17 Aug 2015 04:09:35 +0000 (16:09 +1200)]
Revert "dsdb: Only parse SAMBA_LDAP_MATCH_RULE_TRANSITIVE_EVAL as a DN"

This reverts commit 1a012d591bca727b5cabacf6455d2009afb16bd7.

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

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agos3:lib: fix some corner cases of open_socket_out_cleanup()
Stefan Metzmacher [Fri, 14 Aug 2015 10:54:00 +0000 (12:54 +0200)]
s3:lib: fix some corner cases of open_socket_out_cleanup()

In case of timeouts we retry the async_connect_send() and forgot
to remember it, this results in an abort() in async_connect_cleanup()
as the fd is already closed when calling fcntl(F_SETFL).

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

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
8 years agowaf: Check for Linux has 32-bit credential calls
Andreas Schneider [Fri, 14 Aug 2015 08:59:05 +0000 (10:59 +0200)]
waf: Check for Linux has 32-bit credential calls

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Fri Aug 14 18:04:53 CEST 2015 on sn-devel-104

8 years agolibcli: Use iov_buflen in smb2_signing.c
Volker Lendecke [Mon, 10 Aug 2015 10:02:34 +0000 (12:02 +0200)]
libcli: Use iov_buflen in smb2_signing.c

This gives us overflow protection.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Fri Aug 14 13:56:49 CEST 2015 on sn-devel-104

8 years agopython:samba/upgrade.py Fix format string syntax in error condition
Andrew Bartlett [Fri, 14 Aug 2015 04:43:41 +0000 (16:43 +1200)]
python:samba/upgrade.py Fix format string syntax in error condition

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11436
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Fri Aug 14 10:52:39 CEST 2015 on sn-devel-104

8 years agolib: Remove some unused code
Volker Lendecke [Wed, 12 Aug 2015 07:18:28 +0000 (09:18 +0200)]
lib: Remove some unused code

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agolib: Remove some unused code
Volker Lendecke [Wed, 12 Aug 2015 07:14:35 +0000 (09:14 +0200)]
lib: Remove some unused code

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agosmbd: Use a struct initializer
Volker Lendecke [Wed, 12 Aug 2015 06:58:31 +0000 (08:58 +0200)]
smbd: Use a struct initializer

Saves a few bytes of .text

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agosmbd: Remove a confusing comment
Volker Lendecke [Wed, 12 Aug 2015 06:55:56 +0000 (08:55 +0200)]
smbd: Remove a confusing comment

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agonfs4acls: Remove type_name param from smbacl4_get_vfs_params
Volker Lendecke [Tue, 11 Aug 2015 12:20:07 +0000 (14:20 +0200)]
nfs4acls: Remove type_name param from smbacl4_get_vfs_params

It is kindof unexpected that we get params for something else but
"nfs4:"

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Thu Aug 13 17:45:31 CEST 2015 on sn-devel-104

8 years agonfs4acls: Fix a small memleak
Volker Lendecke [Tue, 11 Aug 2015 12:16:04 +0000 (14:16 +0200)]
nfs4acls: Fix a small memleak

We don't need the nt_ace_list beyond this function, make_sec_acl makes
a copy and make_sec_desc makes another one

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Introduce a helper variable
Volker Lendecke [Tue, 11 Aug 2015 12:13:43 +0000 (14:13 +0200)]
nfs4acls: Introduce a helper variable

... triggered by removing a "==false" condition

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Remove a few unnecessary casts
Volker Lendecke [Tue, 11 Aug 2015 11:37:42 +0000 (13:37 +0200)]
nfs4acls: Remove a few unnecessary casts

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use talloc_realloc()
Volker Lendecke [Tue, 11 Aug 2015 11:36:45 +0000 (13:36 +0200)]
nfs4acls: Use talloc_realloc()

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use talloc_zero_array()
Volker Lendecke [Tue, 11 Aug 2015 11:34:35 +0000 (13:34 +0200)]
nfs4acls: Use talloc_zero_array()

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use talloc_zero()
Volker Lendecke [Tue, 11 Aug 2015 11:33:40 +0000 (13:33 +0200)]
nfs4acls: Use talloc_zero()

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use talloc_zero()
Volker Lendecke [Wed, 12 Aug 2015 05:31:01 +0000 (07:31 +0200)]
nfs4acls: Use talloc_zero()

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Remove get_validated_aceint
Volker Lendecke [Tue, 11 Aug 2015 11:12:46 +0000 (13:12 +0200)]
nfs4acls: Remove get_validated_aceint

With the anonymous struct SMB4ACE_T we can rely on the compiler
to warn us

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Remove get_validated_aclint
Volker Lendecke [Tue, 11 Aug 2015 11:12:46 +0000 (13:12 +0200)]
nfs4acls: Remove get_validated_aclint

With the anonymous struct SMB4ACL_T we can rely on the compiler
to warn us

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Remove the SMB_ACE4_INT_T typedef
Volker Lendecke [Tue, 11 Aug 2015 11:04:05 +0000 (13:04 +0200)]
nfs4acls: Remove the SMB_ACE4_INT_T typedef

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Remove the SMB_ACL4_INT_T typedef
Volker Lendecke [Tue, 11 Aug 2015 11:02:17 +0000 (13:02 +0200)]
nfs4acls: Remove the SMB_ACL4_INT_T typedef

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use SMB4ACE_T instead of _SMB_ACE4_INT_T
Volker Lendecke [Tue, 11 Aug 2015 11:00:59 +0000 (13:00 +0200)]
nfs4acls: Use SMB4ACE_T instead of _SMB_ACE4_INT_T

We can make the _INT_ structure now be the representation of the
published anonymous struct

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use SMB4ACL_T instead of _SMB_ACL4_INT_T
Volker Lendecke [Tue, 11 Aug 2015 10:59:05 +0000 (12:59 +0200)]
nfs4acls: Use SMB4ACL_T instead of _SMB_ACL4_INT_T

We can make the _INT_ structure now be the representation of the
published anonymous struct

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Remove an obsolete comment
Volker Lendecke [Tue, 11 Aug 2015 10:44:08 +0000 (12:44 +0200)]
nfs4acls: Remove an obsolete comment

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use an anon struct for SMB4ACE_T
Volker Lendecke [Tue, 11 Aug 2015 10:35:20 +0000 (12:35 +0200)]
nfs4acls: Use an anon struct for SMB4ACE_T

-typedef struct _SMB4ACE_T {char dontuse;} SMB4ACE_T;
+struct SMB4ACE_T;

Same as for ACL_T

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use an anon struct for SMB4ACL_T
Volker Lendecke [Tue, 11 Aug 2015 10:35:20 +0000 (12:35 +0200)]
nfs4acls: Use an anon struct for SMB4ACL_T

The relevant change:

-typedef struct _SMB4ACL_T {char dontuse;} SMB4ACL_T;
+struct SMB4ACL_T;

We can use anonymous structs to prevent direct use. This patch will
trigger a set of simplifications in the next patches

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agonfs4acls: Use ZERO_STRUCTP
Volker Lendecke [Tue, 11 Aug 2015 10:12:53 +0000 (12:12 +0200)]
nfs4acls: Use ZERO_STRUCTP

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agodns_server: Fix a small memleak
Volker Lendecke [Fri, 7 Aug 2015 06:29:17 +0000 (08:29 +0200)]
dns_server: Fix a small memleak

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Fri Aug  7 12:57:02 CEST 2015 on sn-devel-104

8 years agodns_server: Don't call tevent_req_finish twice
Volker Lendecke [Fri, 7 Aug 2015 05:58:20 +0000 (07:58 +0200)]
dns_server: Don't call tevent_req_finish twice

Both tevent_req_werror and tevent_req_done call tevent_req_finish on a request.
This should not be done. We should only call either of both.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
8 years agos4:torture:vfs_fruit: add a test for stream names
Ralph Boehme [Sun, 10 May 2015 09:58:32 +0000 (11:58 +0200)]
s4:torture:vfs_fruit: add a test for stream names

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

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agos4:torture:vfs_fruit: pass xattr name as arg to torture_setup_local_xattr()
Ralph Boehme [Thu, 6 Aug 2015 11:48:54 +0000 (13:48 +0200)]
s4:torture:vfs_fruit: pass xattr name as arg to torture_setup_local_xattr()

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

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agovfs_catia: run translation on stream names
Ralph Boehme [Sat, 9 May 2015 13:12:41 +0000 (15:12 +0200)]
vfs_catia: run translation on stream names

With vfs_fruit option "fruit:encoding = native" we're already converting
stream names that contain illegal NTFS characters from their on-the-wire
Unicode Private Range encoding to their native ASCII representation.

Unfortunately the reverse mapping for stream names was not perfomed.

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

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agovfs_streams_xattr: stream names may contain colons
Ralph Boehme [Sat, 9 May 2015 13:02:03 +0000 (15:02 +0200)]
vfs_streams_xattr: stream names may contain colons

With vfs_fruit option "fruit:encoding = native" we're already converting
stream names that contain illegal NTFS characters from their on-the-wire
Unicode Private Range encoding to their native ASCII representation.

As as result the name of xattrs storing the streams (via
vfs_streams_xattr) may contain a colon, so we have to use strrchr_m()
instead of strchr_m() for matching the stream type suffix.

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

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agoctdb-tests: Add a policy routing test with misconfiguration
Martin Schwenke [Tue, 4 Aug 2015 07:03:50 +0000 (17:03 +1000)]
ctdb-tests: Add a policy routing test with misconfiguration

To support this, extend the "ip route add" stub to detect duplicate
routes.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Fri Aug  7 08:37:38 CEST 2015 on sn-devel-104

8 years agoctdb-tests: Make fake gateway different to actual public IPs
Martin Schwenke [Tue, 4 Aug 2015 06:12:31 +0000 (16:12 +1000)]
ctdb-tests: Make fake gateway different to actual public IPs

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-scripts: Improve error handling for 50.samba testparm failure
Martin Schwenke [Thu, 30 Jul 2015 06:49:35 +0000 (16:49 +1000)]
ctdb-scripts: Improve error handling for 50.samba testparm failure

Also add tests.  Update testparm stub to fake error and timeout.  Add
timeout stub.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
8 years agoctdb-pmda: Add missing prototype declaration for non-static function
Amitay Isaacs [Mon, 3 Aug 2015 05:36:06 +0000 (15:36 +1000)]
ctdb-pmda: Add missing prototype declaration for non-static function

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

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agoctdb-daemon: Reset database statistics when resetting statistics
Amitay Isaacs [Thu, 2 Apr 2015 02:53:09 +0000 (13:53 +1100)]
ctdb-daemon: Reset database statistics when resetting statistics

When the ctdb statistics is reset, reset per database statistics to keep
it consistent with ctdb statistics.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agoctdb-system: Remove unused system specific calls
Amitay Isaacs [Mon, 3 Aug 2015 05:02:43 +0000 (15:02 +1000)]
ctdb-system: Remove unused system specific calls

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
8 years agosource3/rpc_client: Fix CID 1273041 Condition is redundant
Anoop C S [Mon, 3 Aug 2015 08:31:58 +0000 (14:01 +0530)]
source3/rpc_client: Fix CID 1273041 Condition is redundant

Signed-off-by: Anoop C S <anoopcs@redhat.com>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Fri Aug  7 01:31:23 CEST 2015 on sn-devel-104

8 years agolib/talloc: Fix CID 1291639 Missing unlock
Anoop C S [Mon, 3 Aug 2015 08:29:33 +0000 (13:59 +0530)]
lib/talloc: Fix CID 1291639 Missing unlock

Signed-off-by: Anoop C S <anoopcs@redhat.com>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agolib/talloc: Fix CID 1291640 Missing unlock
Anoop C S [Mon, 3 Aug 2015 08:27:19 +0000 (13:57 +0530)]
lib/talloc: Fix CID 1291640 Missing unlock

Signed-off-by: Anoop C S <anoopcs@redhat.com>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agosmbd: Log smb2 requests returning !OK with higher log level
Christof Schmitt [Wed, 5 Aug 2015 20:31:44 +0000 (13:31 -0700)]
smbd: Log smb2 requests returning !OK with higher log level

This can be useful for narrowing down problems without taking a full
level 10 trace.

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
8 years agos4:rpc_server/netlogon: Fix for NetApp
Arvid Requate [Thu, 6 Aug 2015 13:00:25 +0000 (15:00 +0200)]
s4:rpc_server/netlogon: Fix for NetApp

This patch fixes an issue where NetApp filers joined to a
Samba/ADDC cannot resolve SIDs. Without this patch the issue
can only be avoided by setting "allow nt4 crypto = yes" in smb.conf.

The issue is triggered by NetApp filers in three steps:

1. The client calls netr_ServerReqChallenge to set up challenge tokens

2. Next it calls netr_ServerAuthenticate2 with NETLOGON_NEG_STRONG_KEYS
   set to 0. Native AD and Samba respond to this with
   NT_STATUS_DOWNGRADE_DETECTED. At this point Samba throws away
   the challenge token negotiated in the first step.

3. Next the client calls netr_ServerAuthenticate2 again, this time with
   NETLOGON_NEG_STRONG_KEYS set to 1.
   Samba returns NT_STATUS_ACCESS_DENIED as it has lost track
   of the challenge and denies logon with the message

   No challenge requested by client [CLNT1/CLNT1$], cannot authenticate

Git commit 321ebc99b5a00f82265aee741a48aa84b214d6e8 introduced
a workaround for a different but related issue. This patch makes a minor
adjustment to that commit to delay flushing the cached challenge until
it's clear that we are not in a NT_STATUS_DOWNGRADE_DETECTED
situation.

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

Signed-off-by: Arvid Requate <requate@univention.de>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Thu Aug  6 20:29:04 CEST 2015 on sn-devel-104

8 years agodns: always add authority records
Kai Blin [Fri, 17 Jul 2015 13:27:51 +0000 (15:27 +0200)]
dns: always add authority records

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Kai Blin <kai@samba.org>
Autobuild-Date(master): Thu Aug  6 14:06:52 CEST 2015 on sn-devel-104

8 years agodns: Add a SOA record to error replies
Kai Blin [Wed, 29 Oct 2014 12:41:53 +0000 (13:41 +0100)]
dns: Add a SOA record to error replies

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
8 years agodns: Also pass nsrecs to handle_question()
Kai Blin [Wed, 29 Oct 2014 12:39:16 +0000 (13:39 +0100)]
dns: Also pass nsrecs to handle_question()

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
8 years agodns: Just pass the name to create_response_rr
Kai Blin [Wed, 29 Oct 2014 12:36:58 +0000 (13:36 +0100)]
dns: Just pass the name to create_response_rr

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
8 years agodns: Add dns_get_authoritative_zone helper function
Kai Blin [Wed, 29 Oct 2014 12:35:36 +0000 (13:35 +0100)]
dns: Add dns_get_authoritative_zone helper function

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
8 years agoscript/librelease.sh: this is replaced by script/release.sh now
Stefan Metzmacher [Wed, 5 Aug 2015 13:41:29 +0000 (15:41 +0200)]
script/librelease.sh: this is replaced by script/release.sh now

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu Aug  6 03:49:40 CEST 2015 on sn-devel-104

8 years agoscript/release.sh: This is a new script to do releases
Stefan Metzmacher [Tue, 4 Aug 2015 09:33:26 +0000 (11:33 +0200)]
script/release.sh: This is a new script to do releases

This will replace script/librelease.sh and is more flexible
and powerful.

  Usage: release.sh <PRODUCT> <COMMAND>

  PRODUCT: ldb, talloc, tevent, tdb, samba-rc
  COMMAND: fullrelease, create, push, upload, announce

GNUPGHOME=/path/to/private/gpg script/librelease.sh tdb
becomes
GNUPGHOME=/path/to/private/gpg script/release.sh tdb fullrelease

GNUPGHOME=/path/to/private/gpg script/librelease.sh samba
becomes
GNUPGHOME=/path/to/private/gpg script/release.sh samba-rc create
or later
GNUPGHOME=/path/to/private/gpg script/release.sh samba-stable create

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
8 years agowafsamba: don't add -DSTATIC_%s_MODULES* arguments for SAMBA_LIBRARY(pyembed=True)
Stefan Metzmacher [Mon, 3 Aug 2015 09:39:01 +0000 (11:39 +0200)]
wafsamba: don't add -DSTATIC_%s_MODULES* arguments for SAMBA_LIBRARY(pyembed=True)

Python helper libraries don't have any modules and having something like
'.cpython-34m' in the name, e.g. STATIC_pytalloc-util.cpython-34m_MODULES
breaks the build.

Another way to fix this would be removing PYTHON_SO_ABI_FLAG from the name.

This allows --extra-python=/usr/bin/python3 to work on Ubuntu 14.04.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
8 years agoselftest: Add test for GSSAPI with no authenticator checksum mode
Andrew Bartlett [Fri, 26 Jun 2015 07:15:31 +0000 (19:15 +1200)]
selftest: Add test for GSSAPI with no authenticator checksum mode

This was seen in the wild, with a Huawei Unified Storage System S5500 V3 against the AD DC

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

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Wed Aug  5 09:43:40 CEST 2015 on sn-devel-104

8 years agoheimdal/gssapi: Allow a NULL authenticator
Andrew Bartlett [Fri, 26 Jun 2015 07:14:56 +0000 (19:14 +1200)]
heimdal/gssapi: Allow a NULL authenticator

Some non-GSSAPI implementations that instead try to create compatible packets by wrapping krb5_mk_req()
can trigger a NULL authenticator here.  Assume this to be equvilent to specifying an all-zero
channel bindings and some reasonable (fixed) flags.

This was seen in the wild, with a Huawei Unified Storage System S5500 V3 against the AD DC

Original patch by Andrew Bartlett, restructured by Douglas Bagnall

Cherry-picked from upstream GIT 0a5de96d72cdea9e465412d7dba1e5d13e53dc09
which is the merge of https://github.com/heimdal/heimdal/pull/134

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11425
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agogensec: Add an option emulating another mode a client building GSSAPI/krb5 manually...
Andrew Bartlett [Fri, 26 Jun 2015 07:14:13 +0000 (19:14 +1200)]
gensec: Add an option emulating another mode a client building GSSAPI/krb5 manually uses

This was seen in the wild, with a Huawei Unified Storage System S5500 V3 against the AD DC

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11425
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
8 years agowaf: Add talloc as a dependency
Andreas Schneider [Tue, 4 Aug 2015 10:00:33 +0000 (12:00 +0200)]
waf: Add talloc as a dependency

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Wed Aug  5 04:08:30 CEST 2015 on sn-devel-104

8 years agosdb: Assert if the HDB flags will change
Andreas Schneider [Mon, 3 Aug 2015 11:10:28 +0000 (13:10 +0200)]
sdb: Assert if the HDB flags will change

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
8 years agohdb-samba: Translate SDB errors to HDB errors
Andreas Schneider [Tue, 4 Aug 2015 09:35:45 +0000 (11:35 +0200)]
hdb-samba: Translate SDB errors to HDB errors

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
8 years agos4-torture: add test for CLUSCTL_NODE_GET_ID in clusapi_NodeControl.
Günther Deschner [Tue, 21 Jul 2015 13:31:20 +0000 (15:31 +0200)]
s4-torture: add test for CLUSCTL_NODE_GET_ID in clusapi_NodeControl.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
Autobuild-User(master): José A. Rivera <jarrpa@samba.org>
Autobuild-Date(master): Tue Aug  4 22:14:33 CEST 2015 on sn-devel-104

8 years agos3-rpcclient: add client for create enum ex.
Günther Deschner [Fri, 17 Jul 2015 09:39:52 +0000 (11:39 +0200)]
s3-rpcclient: add client for create enum ex.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agos4-torture: add more ndr tests for property lists.
Günther Deschner [Thu, 16 Jul 2015 22:14:09 +0000 (00:14 +0200)]
s4-torture: add more ndr tests for property lists.

This data is derived from clusapi_NodeControl.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agos4-torture: add torture test for clusapi_NodeControl.
Günther Deschner [Thu, 16 Jul 2015 21:28:33 +0000 (23:28 +0200)]
s4-torture: add torture test for clusapi_NodeControl.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agoclusapi: add clusapi_NodeControlCode to IDL.
Günther Deschner [Thu, 16 Jul 2015 21:22:18 +0000 (23:22 +0200)]
clusapi: add clusapi_NodeControlCode to IDL.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agos4-torture: add tests for GroupControl.
Günther Deschner [Thu, 16 Jul 2015 15:40:37 +0000 (17:40 +0200)]
s4-torture: add tests for GroupControl.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agoclusapi: add clusapi_GroupControlCode enum to IDL.
Günther Deschner [Thu, 16 Jul 2015 15:03:59 +0000 (17:03 +0200)]
clusapi: add clusapi_GroupControlCode enum to IDL.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agos4-torture: also test ClusterControl with a large initial buffer size.
Günther Deschner [Thu, 16 Jul 2015 06:21:27 +0000 (08:21 +0200)]
s4-torture: also test ClusterControl with a large initial buffer size.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agoclusapi: use winreg_Type in clusapi registry IDL.
Günther Deschner [Thu, 16 Jul 2015 06:08:51 +0000 (08:08 +0200)]
clusapi: use winreg_Type in clusapi registry IDL.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agos4-torture: add ndr testsuite for complex clusapi_PROPERTY_LIST structs.
Günther Deschner [Tue, 14 Jul 2015 13:55:57 +0000 (15:55 +0200)]
s4-torture: add ndr testsuite for complex clusapi_PROPERTY_LIST structs.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agoclusapi: use ClusterEnumType in clusapi_CreateEnumEx.
Günther Deschner [Mon, 13 Jul 2015 19:09:16 +0000 (21:09 +0200)]
clusapi: use ClusterEnumType in clusapi_CreateEnumEx.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>
8 years agos4-torture: add test for clusapi_CreateEnumEx().
Günther Deschner [Mon, 13 Jul 2015 19:08:23 +0000 (21:08 +0200)]
s4-torture: add test for clusapi_CreateEnumEx().

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: José A. Rivera <jarrpa@samba.org>