ambi/samba.git
10 years agounlink2 test sharemodes
Christian Ambach [Wed, 5 Jun 2013 10:24:45 +0000 (12:24 +0200)]
unlink2 test

Signed-off-by: Christian Ambach <ambi@samba.org>
10 years agos4:torture add a specific share mode conflict test
Christian Ambach [Tue, 4 Jun 2013 16:18:44 +0000 (18:18 +0200)]
s4:torture add a specific share mode conflict test

this shows that the lack of ALLOW_DELETE in GPFS breaks saving with
Office 2007

10 years agos3:selftest execute base.createx* tests against s3 as well
Christian Ambach [Tue, 4 Jun 2013 14:15:43 +0000 (16:15 +0200)]
s3:selftest execute base.createx* tests against s3 as well

need to put two of them on the knownfail list

Signed-off-by: Christian Ambach <ambi@samba.org>
10 years agos4:torture extend createx_tests to also test with DELETE permission bit
Christian Ambach [Tue, 4 Jun 2013 13:14:30 +0000 (15:14 +0200)]
s4:torture extend createx_tests to also test with DELETE permission bit

this increases test coverage

Signed-off-by: Christian Ambach <ambi@samba.org>
10 years agosmbcquotas.c: fix a bug of -t
Peng Haitao [Mon, 27 May 2013 09:59:54 +0000 (17:59 +0800)]
smbcquotas.c: fix a bug of -t

'r' should be replaced with 't'.

Signed-off-by: Peng Haitao <penght@cn.fujitsu.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Tue Jun  4 13:06:52 CEST 2013 on sn-devel-104

10 years agos4:winbind: don't leak libnet_context into the main event context
Stefan Metzmacher [Fri, 31 May 2013 14:04:26 +0000 (16:04 +0200)]
s4:winbind: don't leak libnet_context into the main event context

This needs to be a talloc child of struct wbsrv_domain
otherwise the cleanup of a broken connection doesn't work.

The following command can trigger the leak on a domain controller.

root@dc:~/samba# ls -l /var/lib/samba/sysvol/samba.private/
total 16
drwxrwx---+ 5 root 3000000 4096 May 14 14:46 Policies
drwxrwx---+ 2 root 3000000 4096 May 14 11:45 scripts

gid 3000000 belongs to Builtin\Administrators.

The code triggers a ncacn_np: connection to the local smbd
and complains that domain BUILTIN is not available:

[2013/05/29 17:28:03,  2] ../source4/winbind/wb_init_domain.c:376(init_domain_recv_queryinfo)
  Expected domain name BUILTIN, DC dc.samba.private said SAMBA

In that case the connection was not closed, which is fixed by this commit.

Using ncalrpc: for all local SIDs and serving the BUILTIN domain is
a project for another day...

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): Tue Jun  4 11:05:09 CEST 2013 on sn-devel-104

10 years agos3:lib/ctdb_packet use sys_send in packet_fd_write
Christian Ambach [Mon, 3 Jun 2013 14:18:03 +0000 (16:18 +0200)]
s3:lib/ctdb_packet use sys_send in packet_fd_write

use the signal safe variant here to prevent spurious errors when running
with CTDB and a signal comes in

Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Christian Ambach <ambi@samba.org>
Autobuild-Date(master): Mon Jun  3 20:01:22 CEST 2013 on sn-devel-104

10 years agoBug 8997: change libreplace GPL source to LGPL
David Disseldorp [Mon, 3 Jun 2013 11:00:31 +0000 (13:00 +0200)]
Bug 8997: change libreplace GPL source to LGPL

libreplace currently includes socket.c and getifaddrs.c both of which
are GPL licensed.
Although not required, talloc and tdb build alongside this source,
leading to some ambiguity regarding their LGPL licences.

The following copyright holders have agreed to the GPL->LGPL change:
lib/replace/getifaddrs.c
   Copyright (C) Andrew Tridgell 1998
   Copyright (C) Jeremy Allison 2007
   Copyright (C) Jelmer Vernooij <jelmer@samba.org> 2007

lib/replace/test/getifaddrs.c
lib/replace/socket.c
 * Copyright (C) Michael Adam <obnox@samba.org> 2008

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon Jun  3 18:06:18 CEST 2013 on sn-devel-104

10 years agotorture: support printer publish pending responses
David Disseldorp [Wed, 29 May 2013 08:43:35 +0000 (10:43 +0200)]
torture: support printer publish pending responses

Windows (tested against 2k8r2) returns WERR_IO_PENDING and
DSPRINT_PENDING when a publish or unpublish is requested via
setprinter(level=7). Modify the AD printer publishing test to support
these responses.

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Mon Jun  3 16:06:15 CEST 2013 on sn-devel-104

10 years agotorture: add AD printer publishing test
David Disseldorp [Wed, 29 May 2013 08:43:34 +0000 (10:43 +0200)]
torture: add AD printer publishing test

This test publishes and unpublishes a printer using setprinter(level=7).
Printer info2.attributes and info7.action flags are check at each point
to ensure MS-RPRN conformance.

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agoFix bug 9900: is_printer_published GUID retrieval
David Disseldorp [Wed, 29 May 2013 08:43:33 +0000 (10:43 +0200)]
Fix bug 9900: is_printer_published GUID retrieval

Samba currently always responds to GetPrinter(level = 7) requests with
DSPRINT_UNPUBLISH, regardless of the AD publish status tracked via the
PRINTER_ATTRIBUTE_PUBLISHED flag. This is due to erroneous "objectGUID"
unmarshalling in is_printer_published().

This change splits "objectGUID" retrieval into a separate function, and
adds a pull_reg_sz() call to correctly unmarshall the GUID.

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agoprinting: explicitly clear PUBLISHED attribute
David Disseldorp [Wed, 29 May 2013 08:43:32 +0000 (10:43 +0200)]
printing: explicitly clear PUBLISHED attribute

Currently nt_printer_publish(DSPRINT_UNPUBLISH) flips (via xor) the
info2->attributes PRINTER_ATTRIBUTE_PUBLISHED flag, rather than
explicitly clearing it.

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
10 years agotdb: Add another overflow check to tdb_expand_adjust
Volker Lendecke [Thu, 30 May 2013 14:23:17 +0000 (16:23 +0200)]
tdb: Add another overflow check to tdb_expand_adjust

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Mon Jun  3 14:08:54 CEST 2013 on sn-devel-104

10 years agotdb: Make tdb_recovery_allocate overflow-safe
Volker Lendecke [Thu, 30 May 2013 13:54:58 +0000 (15:54 +0200)]
tdb: Make tdb_recovery_allocate overflow-safe

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
10 years agotdb: Make tdb_recovery_size overflow-safe
Volker Lendecke [Thu, 30 May 2013 13:24:27 +0000 (15:24 +0200)]
tdb: Make tdb_recovery_size overflow-safe

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
10 years agotdb: add proper OOM/ENOSPC handling to tdb_expand()
Stefan Metzmacher [Tue, 28 May 2013 11:04:29 +0000 (13:04 +0200)]
tdb: add proper OOM/ENOSPC handling to tdb_expand()

Failing to do so will result in corrupt tdbs: We will overwrite
the hash chain pointers with 0x42424242.

Pair-Programmed-With: Volker Lendecke <vl@samba.org>

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
10 years agotdb: add overflow detection to tdb_expand_adjust()
Stefan Metzmacher [Tue, 28 May 2013 11:01:27 +0000 (13:01 +0200)]
tdb: add overflow detection to tdb_expand_adjust()

We round up at maximun to a new size of 4GB,
but still return at least the given size.

The caller has to deal with ENOSPC itself.

Pair-Programmed-With: Volker Lendecke <vl@samba.org>

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
10 years agotdb: add overflow/ENOSPC handling to tdb_expand_file()
Stefan Metzmacher [Tue, 28 May 2013 10:59:32 +0000 (12:59 +0200)]
tdb: add overflow/ENOSPC handling to tdb_expand_file()

Pair-Programmed-With: Volker Lendecke <vl@samba.org>

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
10 years agotdb: add a 'new_size' helper variable to tdb_expand_file()
Stefan Metzmacher [Tue, 28 May 2013 10:56:57 +0000 (12:56 +0200)]
tdb: add a 'new_size' helper variable to tdb_expand_file()

Pair-Programmed-With: Volker Lendecke <vl@samba.org>

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
10 years agotdb: Add overflow-checking tdb_add_off_t
Volker Lendecke [Thu, 30 May 2013 12:52:59 +0000 (14:52 +0200)]
tdb: Add overflow-checking tdb_add_off_t

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
10 years agoparam_table: Remove misleading allow dns updates options.
Michael Wood [Sat, 1 Jun 2013 08:37:37 +0000 (10:37 +0200)]
param_table: Remove misleading allow dns updates options.

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Sat Jun  1 12:46:32 CEST 2013 on sn-devel-104

10 years agodocs: Avoid mentioning a possibly misleading option.
Michael Wood [Sat, 1 Jun 2013 08:35:56 +0000 (10:35 +0200)]
docs: Avoid mentioning a possibly misleading option.

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agoWHATSNEW: Fix 4.0 default for allow dns updates.
Michael Wood [Sat, 1 Jun 2013 08:34:20 +0000 (10:34 +0200)]
WHATSNEW: Fix 4.0 default for allow dns updates.

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agolibcli: Remove uneeded debug message
Kai Blin [Sat, 1 Jun 2013 08:24:12 +0000 (10:24 +0200)]
libcli: Remove uneeded debug message

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agodns: Delete dnsNode objects when they are empty
Kai Blin [Sat, 1 Jun 2013 08:24:11 +0000 (10:24 +0200)]
dns: Delete dnsNode objects when they are empty

If an update leaves the dnsNode without any entries, the dnsNode object
should be deleted. Thanks to Günter Kukkukk for his excellent debugging
work on this one.

This should fix bug #9559

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agos4-dns: set TTL value in the NS server part of the SOA record
Guenter Kukkukk [Thu, 30 May 2013 00:19:32 +0000 (02:19 +0200)]
s4-dns: set TTL value in the NS server part of the SOA record

noticed this when using samba-tool to create a new zone

Signed-off-by: Guenter Kukkukk <kukks@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu May 30 09:41:20 CEST 2013 on sn-devel-104

10 years agobuild-htmlman-nogit: Run build-htmlman-nogit with bash.
Karolin Seeger [Wed, 29 May 2013 08:25:25 +0000 (10:25 +0200)]
build-htmlman-nogit: Run build-htmlman-nogit with bash.

On debian/ubuntu, the "dash" which is sh, does not
provide pushd/popd...

Signed-off-by: Karolin Seeger <kseeger@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu May 30 04:48:06 CEST 2013 on sn-devel-104

10 years agobuild-htmlman-git: Run build-htmlman-git with bash.
Karolin Seeger [Wed, 29 May 2013 08:23:49 +0000 (10:23 +0200)]
build-htmlman-git: Run build-htmlman-git with bash.

    On debian/ubuntu, the "dash" which is sh, does not
    provide pushd/popd...

Signed-off-by: Karolin Seeger <kseeger@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agobuild-htmlman-nogit: manpages-3 has been moved to manpages.
Karolin Seeger [Wed, 29 May 2013 08:21:23 +0000 (10:21 +0200)]
build-htmlman-nogit: manpages-3 has been moved to manpages.

Signed-off-by: Karolin Seeger <kseeger@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agobuild-htmlman-git: manpages-3 has been moved to manpages.
Karolin Seeger [Wed, 29 May 2013 08:20:39 +0000 (10:20 +0200)]
build-htmlman-git: manpages-3 has been moved to manpages.

Signed-off-by: Karolin Seeger <kseeger@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agodocs-xml/.gitignore: manpages-3 has been moved to manpages.
Karolin Seeger [Wed, 29 May 2013 08:19:10 +0000 (10:19 +0200)]
docs-xml/.gitignore: manpages-3 has been moved to manpages.

Signed-off-by: Karolin Seeger <kseeger@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agovfs_glusterfs: Samba VFS module for glusterfs
Anand Avati [Wed, 29 May 2013 11:21:46 +0000 (07:21 -0400)]
vfs_glusterfs: Samba VFS module for glusterfs

Implement a Samba VFS plugin for glusterfs based on gluster's gfapi.
This is a "bottom" vfs plugin (not something to be stacked on top of
another module), and translates (most) calls into closest actions
on gfapi.

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Simo Sorce <idra@samba.org>
Signed-off-by: Anand Avati <avati@redhat.com>
10 years agosamba-tool/dns: Set secure zone update flag after creating new zone
Amitay Isaacs [Mon, 27 May 2013 02:37:20 +0000 (12:37 +1000)]
samba-tool/dns: Set secure zone update flag after creating new zone

Windows DC ignores the secure update flag while creating new zone.  Windows
performs another operation to set the secure update flag.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
10 years agosamba-tool/dns: Pass on additional flags when creating zones
Amitay Isaacs [Mon, 27 May 2013 02:26:36 +0000 (12:26 +1000)]
samba-tool/dns: Pass on additional flags when creating zones

Windows DCs require additional flags to be set when creating zones.

This fixes bug #9599.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
10 years agos4-dns: Support update of SOA records
Amitay Isaacs [Thu, 6 Dec 2012 05:11:18 +0000 (16:11 +1100)]
s4-dns: Support update of SOA records

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
10 years agos4-rpc: dnsserver: When updating SOA record, use the specified serial
Amitay Isaacs [Thu, 6 Dec 2012 05:06:35 +0000 (16:06 +1100)]
s4-rpc: dnsserver: When updating SOA record, use the specified serial

This makes sure that when updating SOA record, the serial is set to the value
sent by client.  For all other records, serial is incremented.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
10 years agos4-rpc: dnsserver: dns_name_equal() returns boolean
Amitay Isaacs [Thu, 6 Dec 2012 05:05:26 +0000 (16:05 +1100)]
s4-rpc: dnsserver: dns_name_equal() returns boolean

Remove the remaining check for return value after strcmp() was changed to
dns_name_equal().

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agos4-rpc: dnsserver: Fix removal of trailing '.' in soa mname
Amitay Isaacs [Thu, 6 Dec 2012 05:04:32 +0000 (16:04 +1100)]
s4-rpc: dnsserver: Fix removal of trailing '.' in soa mname

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agobuild: Add missing new line to replaced python shebang line. (Fix bug #9909)
Michael Adam [Tue, 28 May 2013 10:19:34 +0000 (12:19 +0200)]
build: Add missing new line to replaced python shebang line. (Fix bug #9909)

When configuring with a non-standard python specified in
the PYTHON environment variable, the shebang lines in various
python tools like samba-tool and samba_dnsupdate get replaced.

This replace line for the shebang was missing a newline
which joined the shebang line with the following line,
rendereing those scripts with a nonempty second line unusuable,
for example samba_dnsupdate.

This patch fixes this bug which is bug #9909 on bugzilla.

Pair-Programmed-With: Karolin Seeger <kseeger@samba.org>

Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Karolin Seeger <kseeger@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Wed May 29 13:21:51 CEST 2013 on sn-devel-104

10 years agos4-torture: Always compile backupkey ndr testsuite.
Günther Deschner [Mon, 27 May 2013 12:15:08 +0000 (14:15 +0200)]
s4-torture: Always compile backupkey ndr testsuite.

This removes another incorrect AD_DC_BUILD_IS_ENABLED check ifdef check. The ndr
test is not at all heimdal specific.

Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Autobuild-User(master): Alexander Bokovoy <ab@samba.org>
Autobuild-Date(master): Wed May 29 11:29:51 CEST 2013 on sn-devel-104

10 years agowaf: build PIEs if supported by the compiler
David Disseldorp [Tue, 28 May 2013 13:11:45 +0000 (15:11 +0200)]
waf: build PIEs if supported by the compiler

Currently waf performs a mandatory check for compiler PIE support,
unless --without-pie is specified.
This change makes Waf only perform the mandatory check if --with-pie is
specified. If neither --with-pie nor --without-pie are specified, then
PIEs are only built if compiler support is available.

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
10 years agoautobuild: remove remnants of removed samba3 targets
Michael Adam [Tue, 28 May 2013 20:24:26 +0000 (22:24 +0200)]
autobuild: remove remnants of removed samba3 targets

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Wed May 29 09:35:16 CEST 2013 on sn-devel-104

10 years agonet: use smbconf_create_set_share() in "net conf import"
Michael Adam [Tue, 21 May 2013 14:50:49 +0000 (16:50 +0200)]
net: use smbconf_create_set_share() in "net conf import"

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Tue May 28 20:01:12 CEST 2013 on sn-devel-104

10 years agolibsmbconf: add smbconf_create_set_share
David Disseldorp [Thu, 16 May 2013 09:55:04 +0000 (11:55 +0200)]
libsmbconf: add smbconf_create_set_share

This call creates a new share definition, using the parameters provided
with a smbconf_service structure.
Such an interface allows for simple cloning of services with:
smbconf_get_share(conf_ctx, mem_ctx, base_sharename, &base_service_def);
base_service_def->name = clone_sharename;
smbconf_create_set_share(conf_ctx, base_service_def);

Pair-Programmed-With: Michael Adam <obnox@samba.org>

Signed-off-by: David Disseldorp <ddiss@samba.org>
Signed-off-by: Michael Adam <obnox@samba.org>
10 years agolibsmbconf: fix documentation of transaction calls.
Michael Adam [Mon, 20 May 2013 21:30:14 +0000 (23:30 +0200)]
libsmbconf: fix documentation of transaction calls.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agodsdb-repl_meta_data: Move TODO comment about conflicts and missing parents
Andrew Bartlett [Thu, 16 May 2013 07:51:56 +0000 (17:51 +1000)]
dsdb-repl_meta_data: Move TODO comment about conflicts and missing parents

Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue May 28 18:11:00 CEST 2013 on sn-devel-104

10 years agotorture: Add tests of rename behaviour to replica_sync.py
Andrew Bartlett [Thu, 16 May 2013 05:24:25 +0000 (15:24 +1000)]
torture: Add tests of rename behaviour to replica_sync.py

Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agodsdb-repl_meta_data: Handle renames better, considering only the RDN as given, and...
Andrew Bartlett [Thu, 16 May 2013 05:19:20 +0000 (15:19 +1000)]
dsdb-repl_meta_data: Handle renames better, considering only the RDN as given, and then the parent as given

This ignores the full DN as given, because the parent compents might be out of date.

Andrew Bartlett

Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agodsdb-linked_attributes: Do not crash if the target GUID can not be found
Andrew Bartlett [Thu, 16 May 2013 03:52:51 +0000 (13:52 +1000)]
dsdb-linked_attributes: Do not crash if the target GUID can not be found

Note that we must not give an error when we cannot find the object
that should hold the backlink, there really isn't anything we can do
in this case.

Andrew Bartlett

Reviewed-by: Stefan Metzmacher <metze@samba.org>
10 years agotdb: fix logging of offets and lengths.
Rusty Russell [Tue, 28 May 2013 07:23:56 +0000 (16:53 +0930)]
tdb: fix logging of offets and lengths.

We can have offsets > 2G, so use unsigned values.  Fixes other prints to be
native types rather than casts, too.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue May 28 11:22:14 CEST 2013 on sn-devel-104

10 years agos4-dns: Print/Set minimumTTL value in SOA record
Amitay Isaacs [Thu, 6 Dec 2012 05:10:42 +0000 (16:10 +1100)]
s4-dns: Print/Set minimumTTL value in SOA record

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue May 28 08:47:56 CEST 2013 on sn-devel-104

10 years agobuild: Remove unused mkbuildoptions.awk
Andrew Bartlett [Wed, 22 May 2013 23:37:10 +0000 (09:37 +1000)]
build: Remove unused mkbuildoptions.awk

This is not used by the waf build.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused tool for config.h comparison
Andrew Bartlett [Wed, 22 May 2013 07:05:11 +0000 (17:05 +1000)]
build: Remove unused tool for config.h comparison

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove feature tests for variables now always provided
Andrew Bartlett [Wed, 22 May 2013 06:23:23 +0000 (16:23 +1000)]
build: Remove feature tests for variables now always provided

These #ifdef statements were added in replacement for #if (_SAMBA_BUILD_ >= 4)
in fbe7ed79b0f056a9a8f44a9b42e887441d2f00d5

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused credentials_samba3.c
Andrew Bartlett [Wed, 22 May 2013 06:16:31 +0000 (16:16 +1000)]
build: Remove unused credentials_samba3.c

This file was only used by the autoconf build system.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agoselftest: VFSLIBDIR is not needed, the waf build knows where to find modules automati...
Andrew Bartlett [Wed, 22 May 2013 06:13:21 +0000 (16:13 +1000)]
selftest: VFSLIBDIR is not needed, the waf build knows where to find modules automatically

This is why was relinks on install, because it is fixing these
internal variables up.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove autoconf build system from examples/VFS
Andrew Bartlett [Wed, 22 May 2013 04:22:36 +0000 (14:22 +1000)]
build: Remove autoconf build system from examples/VFS

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agopassdb-machine_account_secrets: Remove #if SAMBA_BUILD_ == 4 now we only have the...
Andrew Bartlett [Wed, 22 May 2013 03:48:35 +0000 (13:48 +1000)]
passdb-machine_account_secrets: Remove #if SAMBA_BUILD_ == 4 now we only have the waf build

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agonsswitch: Remove #if SAMBA_BUILD_ >= 4 now we only have the waf build
Andrew Bartlett [Wed, 22 May 2013 03:47:50 +0000 (13:47 +1000)]
nsswitch: Remove #if SAMBA_BUILD_ >= 4 now we only have the waf build

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agolib/util/modules.c: Remove #if SAMBA_BUILD_ == 3 now we only have the waf build
Andrew Bartlett [Wed, 22 May 2013 03:46:16 +0000 (13:46 +1000)]
lib/util/modules.c: Remove #if SAMBA_BUILD_ == 3 now we only have the waf build

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agoparam: Remove _SAMBA_BUILD_ checks from now the autoconf build is gone
Andrew Bartlett [Wed, 22 May 2013 03:44:59 +0000 (13:44 +1000)]
param: Remove _SAMBA_BUILD_ checks from now the autoconf build is gone

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agodocs: Document removal of the autoconf build system
Andrew Bartlett [Wed, 22 May 2013 02:47:59 +0000 (12:47 +1000)]
docs: Document removal of the autoconf build system

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused preproc-dummy.c
Andrew Bartlett [Wed, 22 May 2013 02:39:59 +0000 (12:39 +1000)]
build: Remove unused preproc-dummy.c

This was used by autogen.sh

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused linkmodules.sh script
Andrew Bartlett [Wed, 22 May 2013 02:37:54 +0000 (12:37 +1000)]
build: Remove unused linkmodules.sh script

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused revert.sh script
Andrew Bartlett [Wed, 22 May 2013 02:37:34 +0000 (12:37 +1000)]
build: Remove unused revert.sh script

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused uninstall*.sh scripts
Andrew Bartlett [Wed, 22 May 2013 02:37:14 +0000 (12:37 +1000)]
build: Remove unused uninstall*.sh scripts

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused install*.sh scripts
Andrew Bartlett [Wed, 22 May 2013 02:36:34 +0000 (12:36 +1000)]
build: Remove unused install*.sh scripts

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused build_idl.sh
Andrew Bartlett [Wed, 22 May 2013 02:35:15 +0000 (12:35 +1000)]
build: Remove unused build_idl.sh

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agoRemove lib/netapi autoconf build system, this is now build with waf
Andrew Bartlett [Wed, 22 May 2013 02:32:55 +0000 (12:32 +1000)]
Remove lib/netapi autoconf build system, this is now build with waf

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused build_idl.sh
Andrew Bartlett [Wed, 22 May 2013 02:30:10 +0000 (12:30 +1000)]
build: Remove unused build_idl.sh

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agoRemove now-unused s3-selftest.sh wrapper
Andrew Bartlett [Wed, 22 May 2013 02:27:33 +0000 (12:27 +1000)]
Remove now-unused s3-selftest.sh wrapper

This is now always invokes via waf.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agoRemove stub ldb_version.h and source3/include/autoconf as no longer needed
Andrew Bartlett [Wed, 22 May 2013 02:26:35 +0000 (12:26 +1000)]
Remove stub ldb_version.h and source3/include/autoconf as no longer needed

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove autoconf directory no longer needed
Andrew Bartlett [Wed, 22 May 2013 02:25:45 +0000 (12:25 +1000)]
build: Remove autoconf directory no longer needed

This was only needed to avoid autoconf and waf builds colliding.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused script/mkversion.sh
Andrew Bartlett [Wed, 22 May 2013 02:24:16 +0000 (12:24 +1000)]
build: Remove unused script/mkversion.sh

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove unused install-sh
Andrew Bartlett [Wed, 22 May 2013 02:23:56 +0000 (12:23 +1000)]
build: Remove unused install-sh

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: Remove autoconf build system
Andrew Bartlett [Wed, 22 May 2013 02:23:20 +0000 (12:23 +1000)]
build: Remove autoconf build system

We are now confident that that waf build system meets enough of our needs
that we will work to improve it, rather than maintain two build systems.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agobuild: No longer run autogen.sh during tarball creation
Andrew Bartlett [Wed, 22 May 2013 04:23:31 +0000 (14:23 +1000)]
build: No longer run autogen.sh during tarball creation

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agoautobuild: Remove samba3 and samba3-ctdb targets to allow autoconf removal for 4.1
Andrew Bartlett [Wed, 22 May 2013 04:35:08 +0000 (14:35 +1000)]
autobuild: Remove samba3 and samba3-ctdb targets to allow autoconf removal for 4.1

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
10 years agowaf: build position independent executables
David Disseldorp [Mon, 27 May 2013 15:57:01 +0000 (17:57 +0200)]
waf: build position independent executables

This patch re-instates support for building Position Independent
Executables using the '-fPIE' and '-pie' compiler and linker flags
respectively.

PIE builds are enabled by default, and can be explicitly disabled using
the '--without-pie' configure argument.

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue May 28 02:56:36 CEST 2013 on sn-devel-104

10 years agowaf: add --with[out]-pie configure arguments
David Disseldorp [Mon, 27 May 2013 15:57:00 +0000 (17:57 +0200)]
waf: add --with[out]-pie configure arguments

The arguments do not currently have any effect.

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
10 years agobuild: Install smbtar in waf build
Andrew Bartlett [Sun, 26 May 2013 11:05:12 +0000 (21:05 +1000)]
build: Install smbtar in waf build

Reviewed-by: Kai Blin <kai@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon May 27 12:55:05 CEST 2013 on sn-devel-104

10 years agodocs: Remove all references to testprns
Andrew Bartlett [Sun, 26 May 2013 10:29:19 +0000 (20:29 +1000)]
docs: Remove all references to testprns

Based on debian patch documentation2.patch by Christian Perrier <bubulle@debian.org>.

This tool no longer exists in Samba.

Andrew Bartlett

Reviewed-by: Kai Blin <kai@samba.org>
10 years agobuild: Remove duplicate call to bld.SYMBOL_CHECK()
Andrew Bartlett [Wed, 22 May 2013 21:34:15 +0000 (07:34 +1000)]
build: Remove duplicate call to bld.SYMBOL_CHECK()

This was missed when we merged the two waf systems.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon May 27 10:30:06 CEST 2013 on sn-devel-104

10 years agobuild: Remove mkinstalldirs
Andrew Bartlett [Wed, 22 May 2013 23:51:36 +0000 (09:51 +1000)]
build: Remove mkinstalldirs

This is not used in the waf build.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agolib/replace: Remove unused install-sh
Andrew Bartlett [Thu, 23 May 2013 03:17:19 +0000 (13:17 +1000)]
lib/replace: Remove unused install-sh

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon May 27 05:51:04 CEST 2013 on sn-devel-104

10 years agobuild: Remove unused expand-includes.pl
Andrew Bartlett [Wed, 22 May 2013 23:51:03 +0000 (09:51 +1000)]
build: Remove unused expand-includes.pl

We no longer have makefiles with includes.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agobuild: Remove old create-tarball release script
Andrew Bartlett [Wed, 22 May 2013 23:38:47 +0000 (09:38 +1000)]
build: Remove old create-tarball release script

Releases are now done via "waf dist" and script/librelease.sh.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agobuild: Do not always regenerate the version.h file
Andrew Bartlett [Wed, 22 May 2013 23:33:19 +0000 (09:33 +1000)]
build: Do not always regenerate the version.h file

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agosmbd: Fix build on platforms that will not support var = {} initialisation
Andrew Bartlett [Tue, 21 May 2013 21:37:33 +0000 (07:37 +1000)]
smbd: Fix build on platforms that will not support var = {} initialisation

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agoexamples: Remove browser and DC settings from example smb.conf
Andrew Bartlett [Tue, 21 May 2013 14:13:52 +0000 (00:13 +1000)]
examples: Remove browser and DC settings from example smb.conf

These examples just encourage folks to set browing values that are not needed.

The domain logons setting is already covered by the server role at the
top of the file and logon script is not special enough to be in the
default smb.conf.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agoexamples: Remove password server from example smb.conf
Andrew Bartlett [Tue, 21 May 2013 14:12:23 +0000 (00:12 +1000)]
examples: Remove password server from example smb.conf

This should discourage folks from setting it when they do not really need it.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agoexamples: Remove default printing form example smb.conf
Andrew Bartlett [Tue, 21 May 2013 14:11:32 +0000 (00:11 +1000)]
examples: Remove default printing form example smb.conf

These settings are all defaults, and just work for most systems.  Users on other platforms
can read man smb.conf, rather than cluttering up this file.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agoexamples: Move example smb.conf over to "server role"
Andrew Bartlett [Tue, 21 May 2013 14:10:39 +0000 (00:10 +1000)]
examples: Move example smb.conf over to "server role"

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agobuild: Rework BSD_STYLE_STATVFS check to match autoconf build
Andrew Bartlett [Tue, 21 May 2013 14:14:29 +0000 (00:14 +1000)]
build: Rework BSD_STYLE_STATVFS check to match autoconf build

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agobuild: Remove binaries and libraries build groups
Andrew Bartlett [Sun, 26 May 2013 13:11:03 +0000 (23:11 +1000)]
build: Remove binaries and libraries build groups

Build groups are used in Samba to ensure that even if the dependency
chain for a target is not perfect, that it builds reliably.  This
matters most in the early build stages, where we are building the asn1
compiler and autogenerating files.

Once we get to the main stage, dependencies between C files, libraries
and binaries are much clearer, because the C compiler and linker takes
these as inputs anyway.

Groups were added to our waf build for stability during early
development, as dependency information was first imported from the
previous autoconf/perl based build system.

I don't think we need this distinction in the main build of C files
into .o, and when linking these into binaries, because the invocation
of these tools is very well defined, and we will find any missing
inputs very quickly.

As such, I've removed the libraries and binaries targets,
consolidating them with 'main'

By making this change, a build of smbtorture only on a clean tree
drops from 3778 to 2489 targets, and much of the expensive linker
stage is skipped.  The time for a null build of smbtorture only also
drops from 4.673s to as low as 2.499s on my laptop.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agobuild: Build all of samba in autoconf make test
Andrew Bartlett [Sun, 26 May 2013 22:27:44 +0000 (08:27 +1000)]
build: Build all of samba in autoconf make test

The test system actually depends on far more than smbtorture these days
and this was masked by the build groups.  Rather than try and specify
everything that could be used, just build the lot (which is what was
essentially being done anyway).

This prepares for the removal of the libraries and binaries build
groups, to assist in improving waf performance for single-binary builds.

Andrew Bartlett

Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
10 years agos4:idmap: break account_type check lines for readability in idmap_sid_to_xid()
Michael Adam [Wed, 24 Apr 2013 13:49:46 +0000 (15:49 +0200)]
s4:idmap: break account_type check lines for readability in idmap_sid_to_xid()

Also makes code obey README.Coding, regarding line-length.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Mon May 27 00:05:19 CEST 2013 on sn-devel-104

10 years agoidl: Add DNS HINFO record support
Kai Blin [Sat, 25 May 2013 12:05:22 +0000 (14:05 +0200)]
idl: Add DNS HINFO record support

Not sure if we need this, bug samba.org specifies it, so this can cause ANY queries
against samba.org to fail.

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Sun May 26 20:05:38 CEST 2013 on sn-devel-104

10 years agoidl: Add DNS RP record support as per RFC 1183
Kai Blin [Sat, 25 May 2013 12:05:21 +0000 (14:05 +0200)]
idl: Add DNS RP record support as per RFC 1183

Not sure if we need this, but samba.org specifies it, so this could cause ANY
queries against samba.org to fail.

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
10 years agodns: Support larger queries when asking forwarder
Kai Blin [Sat, 25 May 2013 11:21:33 +0000 (13:21 +0200)]
dns: Support larger queries when asking forwarder

This should fix bug #9632

Signed-off-by: Kai Blin <kai@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>