summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* libcli: Use iov_buflen in smbXcli_iov_lenVolker Lendecke2015-02-242-7/+6
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Fix a typoVolker Lendecke2015-02-241-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smb2_server: Use iov_advanceVolker Lendecke2015-02-241-24/+4
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smb2_server: Add range checking to nbt_lengthVolker Lendecke2015-02-241-13/+48
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* tsocket: Use iov_advanceVolker Lendecke2015-02-242-51/+18
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* iov_buf: Add an explaining commentVolker Lendecke2015-02-241-0/+4
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* tsocket: Fix a typoVolker Lendecke2015-02-241-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* lib: Move "iov_buf.[ch]" to lib/utilVolker Lendecke2015-02-2411-12/+12
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* rpc: Use tevent_req_poll_ntstatusVolker Lendecke2015-02-241-2/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* ctdb-io: Do not use sys_write to write to client socketsAmitay Isaacs2015-02-241-3/+3
| | | | | | | | | | | | | | | | | | | | | | When sending messages to clients, ctdb checks for EAGAIN error code and schedules next write in the subsequent event loop. Using sys_write in these places causes ctdb to loop hard till a client is able to read from the socket. With real time scheduling, ctdb daemon spins consuming 100% of CPU trying to write to the client sockets. This can be quite harmful when running under VMs or machines with single CPU. This regression was introduced when all read/write calls were replaced to use sys_read/sys_write wrappers (c1558adeaa980fb4bd6177d36250ec8262e9b9fe). The existing code backs off in case of EAGAIN failures and waits for an event loop to process the write again. This should give ctdb clients a chance to get scheduled and to process the ctdb socket. Signed-off-by: Amitay Isaacs <amitay@gmail.com> Reviewed-by: Martin Schwenke <martin@meltin.net> Autobuild-User(master): Martin Schwenke <martins@samba.org> Autobuild-Date(master): Tue Feb 24 12:29:30 CET 2015 on sn-devel-104
* nmblookup: Warn user if netbios name is too long.Andreas Schneider2015-02-242-0/+22
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Tue Feb 24 01:01:10 CET 2015 on sn-devel-104
* nss-wins: Do not lookup invalid netbios namesAndreas Schneider2015-02-231-1/+13
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* libsmb: Do not lookup invalid netbios names.Andreas Schneider2015-02-231-3/+14
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* Revert "s3: smbd: signing. Ensure we respond correctly to an SMB2 negprot ↵Jeremy Allison2015-02-232-5/+2
| | | | | | | | | | | | with SMB2_NEGOTIATE_SIGNING_REQUIRED." Even though the MS-SMB2 spec says so, Windows doesn't behave like this. This reverts commit 1cea6e5b6f8c0e28d5ba2d296c831c4878fca304. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: "Stefan (metze) Metzmacher" <metze@samba.org>
* waf: Only build the wrappers if we enable selftestAndreas Schneider2015-02-232-8/+14
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Mon Feb 23 22:31:22 CET 2015 on sn-devel-104
* swrap: Bump version to 1.1.3Andreas Schneider2015-02-231-1/+1
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: If we remove the socket_info also unlink the unix socketAndreas Schneider2015-02-231-0/+3
| | | | | Signed-off-by: Andreas Schneider <asn@cryptomilk.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* swrap: Do not leak the socket_info we just removed.Andreas Schneider2015-02-231-0/+1
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* src: Add support for running with address sanitizer.Andreas Schneider2015-02-231-0/+8
| | | | | | | | If address sanitzer will complain about our hack with variable function attributes. This disables the checking of it. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* swrap: Fix the loop for older gcc versions.Andreas Schneider2015-02-231-2/+8
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* torture: Add netr_setPassword(2) schannel test.Andreas Schneider2015-02-235-1/+166
| | | | | | | | | | | | Thanks to Florian Weimer <fweimer@redhat.com> for the help to write this torture test. Pair-Programmed-With: Guenther Deschner <gd@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Guenther Deschner <gd@samba.org> Autobuild-User(master): Karolin Seeger <kseeger@samba.org> Autobuild-Date(master): Mon Feb 23 20:01:01 CET 2015 on sn-devel-104
* s3-netlogon: Make sure we do not deference a NULL pointer.Andreas Schneider2015-02-231-1/+6
| | | | | | | | | | | | This is an additional patch for CVE-2015-0240. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11077#c32 Pair-Programmed-With: Michael Adam <obnox@samba.org> Pair-Programmed-With: Andreas Schneider <asn@samba.org> Signed-off-by: Michael Adam <obnox@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>
* CVE-2015-0240: s3: netlogon: Ensure we don't call talloc_free on an ↵Jeremy Allison2015-02-231-1/+5
| | | | | | | | | uninitialized pointer. Bug: https://bugzilla.samba.org/show_bug.cgi?id=11077 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* s3: smbd: SMB2 close. If a file has delete on close, store the return info ↵Jeremy Allison2015-02-201-0/+20
| | | | | | | | | | | | | | | | | before deleting. If we delete the file on close, the stat after the close will fail so we fail to return the attributes requested. Bug 11104 - SMB2/SMB3 close response does not include attributes when requested. https://bugzilla.samba.org/show_bug.cgi?id=11104 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Steve French <sfrench@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Feb 20 20:54:18 CET 2015 on sn-devel-104
* s3: smbd: SMB2 close. Call utility function setup_close_full_information()Jeremy Allison2015-02-201-26/+11
| | | | | | | | | | | Replaces existing inline code. Bug 11104 - SMB2/SMB3 close response does not include attributes when requested. https://bugzilla.samba.org/show_bug.cgi?id=11104 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Steve French <sfrench@samba.org>
* s3: smbd: SMB2 close. Add utility function setup_close_full_information()Jeremy Allison2015-02-201-0/+42
| | | | | | | | | | | Not yet used. Bug 11104 - SMB2/SMB3 close response does not include attributes when requested. https://bugzilla.samba.org/show_bug.cgi?id=11104 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Steve French <sfrench@samba.org>
* doc:man:vfs_glusterfs: improve the configuration section.Michael Adam2015-02-201-2/+21
| | | | | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org> Autobuild-User(master): Günther Deschner <gd@samba.org> Autobuild-Date(master): Fri Feb 20 14:29:21 CET 2015 on sn-devel-104
* doc:man:vfs_glusterfs: improve and update description.Michael Adam2015-02-201-16/+17
| | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* doc:man:vfs_glusterfs: remove extra % signs.Michael Adam2015-02-201-3/+2
| | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* s4: smbtorture: leases - show stat opens grant leases and can be broken.Jeremy Allison2015-02-191-0/+79
| | | | | | | | | | https://bugzilla.samba.org/show_bug.cgi?id=11102 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Feb 19 23:10:43 CET 2015 on sn-devel-104
* s3: smbd: leases - losen paranoia check. Stat opens can grant leases.Jeremy Allison2015-02-191-1/+2
| | | | | | | https://bugzilla.samba.org/show_bug.cgi?id=11102 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* s3: smbd: leases - new torture test shows stat opens can get leases.Jeremy Allison2015-02-191-7/+4
| | | | | | | | | Can also issue breaks on these leases. https://bugzilla.samba.org/show_bug.cgi?id=11102 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* s3: smbd: signing. Ensure we respond correctly to an SMB2 negprot with ↵Jeremy Allison2015-02-192-2/+5
| | | | | | | | | | | SMB2_NEGOTIATE_SIGNING_REQUIRED. Bug 11103: - Samba does not set the required flags in the SMB2/SMB3 Negotiate Protocol Response when signing required by client https://bugzilla.samba.org/show_bug.cgi?id=11103 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Steve French <smfrench@gmail.com>
* regedit: Rename variable to fix compile warningChristof Schmitt2015-02-191-4/+4
| | | | | | | | | | | | | | | | | With --picky-developer this warning is turned into an error: cc1: warnings being treated as errors ../source3/utils/regedit_treeview.c: In function ‘tree_node_load_children’: ../source3/utils/regedit_treeview.c:256: error: declaration of ‘key_name’ shadows a global declaration /usr/include/ncurses.h:1419: error: shadowed declaration is here Fix this by renaming the local variable. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Feb 19 01:31:44 CET 2015 on sn-devel-104
* s3/vfs: bump interface version number to 33David Disseldorp2015-02-181-1/+2
| | | | | | | | | The SMB_VFS_DISK_FREE() small_query parameter removal cleanup will not be merged for Samba 4.2, so the master SMB_VFS_INTERFACE_VERSION number should be bumped above what's currently present in the 4.2 branch. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* spoolss: retrieve published printer GUID if not in registryAndreas Schneider2015-02-181-2/+22
| | | | | | | | | | | | | | | | | | | | | When a printer is published, the GUID for the published DN is retrieved from the domain controller and stored in the registry. When handling a spoolss GetPrinter(level=7) request, the same GUID is obtained from the registry and returned to the client. This change sees the spoolss server query the DC for the published printer GUID if it is not present in the registry when handling a spoolss GetPrinter(level=7) request. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11018 Pair-Programmed-With: David Disseldorp <ddiss@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org> Autobuild-User(master): Günther Deschner <gd@samba.org> Autobuild-Date(master): Wed Feb 18 12:43:44 CET 2015 on sn-devel-104
* printing: rework nt_printer_guid_store to return errorsAndreas Schneider2015-02-182-17/+35
| | | | | | | | | | | Callers can now choose whether or not to ignore errors. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11018 Pair-programmed-with: David Disseldorp <ddiss@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* printing: add nt_printer_guid_retrieve() helperDavid Disseldorp2015-02-182-0/+61
| | | | | | | | | | | | This function connects to the domain controller and retrieves the GUID for the corresponding printer DN. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11018 Pair-programmed-with: Andreas Schneider <asn@samba.org> Signed-off-by: David Disseldorp <ddiss@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* printing: split out printer DN and GUID retrievalDavid Disseldorp2015-02-181-72/+137
| | | | | | | | | | | This functions are used for printer publishing. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11018 Pair-programmed-with: Andreas Schneider <asn@samba.org> Signed-off-by: David Disseldorp <ddiss@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* ctdb-scripts: Improve messages about invalid tunables during "setup"Martin Schwenke2015-02-182-5/+12
| | | | | | | | 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): Wed Feb 18 08:03:33 CET 2015 on sn-devel-104
* ctdb-tool: Print a warning when setting an obsolete tunable variableMartin Schwenke2015-02-183-0/+7
| | | | | Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
* ctdb-client: Return a value of 1 when setting obsolete tunable variableMartin Schwenke2015-02-182-2/+3
| | | | | Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
* ctdb-tests: New tests for 00.ctdb "setup" event - set tunables from configMartin Schwenke2015-02-187-0/+109
| | | | | | | Unit test infrastructure tweaks to support. Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
* ctdb-scripts: Fix tunable setup code by making it shell-agnosticMartin Schwenke2015-02-181-3/+3
| | | | | | | | | | | | | | | | | | All tunables set in configuration are currently set to 0 on system where /bin/sh is dash (and perhaps other non-bash shells). dash puts single quotes around all values in the output of the "set" builtin command, whereas bash only puts them around values when something needs to be quoted. Tunables always have a simple integer value so dash will quote them and bash won't. The setup code currently passes the raw value, including any quotes to "ctdb setvar ...". This command does no error checking on the input, so "'1'" is converted to 0. Change the code so that the value is determined from the shell variable and is independent of the "set" output. Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
* ctdb: Change default debug level to NOTICE (2)Martin Schwenke2015-02-185-10/+8
| | | | | | | | | | | This was true for the daemon until commit b4589b954e1090a934fafd3f8e3c2cf1ed785c61. Defaulting to ERR in the ctdb CLI tool encourages logging notices at ERR level, so default to NOTICE instead. Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
* lib: texpect. Fix the build on Solaris.Tom Schulz2015-02-172-1/+6
| | | | | | | | | | | | | Bug 11092 - texpect requires routines err and errx https://bugzilla.samba.org/show_bug.cgi?id=11092 Signed-off-by: Tom Schulz <schulz@adi.com> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Tue Feb 17 18:09:52 CET 2015 on sn-devel-104
* group.py: Fix wrong example option, remove wrong comment lineMarc Muehlfeld2015-02-171-2/+1
| | | | | | | | | Replaced "--gid" with the correct "--gid-number" in Example 3. Additionally removed the first comment line in group.py, which was wrong in that file. Signed-off-by: Marc Muehlfeld <mmuehlfeld@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* buildtools: Use separate storage for each function in runoncePetr Viktorin2015-02-171-1/+1
| | | | | | | | | | | | | The runonce decorator used shared storage for all functions, and dispatched only on arguments, so a call would be eliminated if a different runonce function had already been called with the same arguments. Use separate storage for each decorated function. Signed-off-by: Petr Viktorin <pviktori@redhat.com> Reviewed-by: Simo Sorce <simo@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* Force rebuild of ldb if pyldb-util is not available.Jelmer Vernooij2015-02-171-4/+4
| | | | | | | | | This is necessary since pyldb-util uses ldb_private.h, so we want to build against the same source ldb. Change-Id: I802974b9eef7deb102fea15b67ec5f87e8e353bd Signed-off-by: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* wscript: Expand tabs.Jelmer Vernooij2015-02-171-1/+1
| | | | | | | Change-Id: I2746f775accceeb2eeb02679f2c91b02085560b6 Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>